View Single Post
  #2 (permalink)  
Old June 3rd, 2011, 05:43 AM
om_prakash om_prakash is offline
Friend of Wrox
Points: 2,473, Level: 20
Points: 2,473, Level: 20 Points: 2,473, Level: 20 Points: 2,473, Level: 20
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: May 2004
Location: India
Posts: 642
Thanks: 0
Thanked 43 Times in 42 Posts
Default

Try this:
Code:
If objReader2.HasRows Then
    Do While objReader2.Read()
 strSQL3 = "UPDATE tbl_civil_works SET codeno = " & record_counter
 ExecuteStatement(strSQL3) 
 record_counter = record_counter + 1
    Loop
Else
    Console.WriteLine("No rows found.")
End If
__________________
Om Prakash Pant
Click the "Thanks" button if this post helped you.
Reply With Quote