SitePoint Sponsor

User Tag List

Results 1 to 2 of 2

Thread: Silly error

  1. #1
    SitePoint Evangelist
    Join Date
    Jun 2004
    Location
    ny
    Posts
    560
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Silly error

    I need help with this error. I am new to .net..Thanks all.

    Compiler Error Message: CS1002: ; expected

    Source Error:



    Line 4:
    Line 5: <script runat="server">
    Line 6: sub Page_Load
    Line 7: dim dbconn,sql,dbcomm;
    Line 8: dbconn=new OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;data source=" & server.mappath("s.mdb"))

  2. #2
    SitePoint Author silver trophybronze trophy
    wwb_99's Avatar
    Join Date
    May 2003
    Location
    Washington, DC
    Posts
    10,633
    Mentioned
    4 Post(s)
    Tagged
    0 Thread(s)
    The problem is your project is setup as a C# project, and you are trying to use VB.NET to code in. C#, unlike VB does not end lines of code on hard returns, but rather ends lines of code using ;.


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •