|
-
Sep 28th, 2004, 01:03 AM
#1
Thread Starter
Lively Member
Object reference not set to an instance of an object
Hi:
i get this message quite often. below is part of the code which gives the error. can u find anything wrong?
Dim ac, desc As String
ac = e.Item.Cells(0).Text
desc = e.Item.Cells(1).Text
Dim sqlselect As String
Dim conn1 As New OleDb.OleDbConnection("Provider=MSDAORA.1;Password=eas;User ID=eas;Data Source=WETST920.world")
sqlselect = "select * from subarea where upper (code) ='" & UCase(ac) & "' "
Dim del As New OleDb.OleDbCommand(sqlselect, conn1)
conn1.Open()
del.ExecuteNonQuery()
conn1.Close()
dscmd.SelectCommand.CommandText = sqlselect
dscmd.Fill(ds, sqlselect)
the error comes at
dscmd.SelectCommand.CommandText = sqlselect
why??
thanks
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|