View Single Post
  #2 (permalink)  
Old November 5th, 2003, 12:21 AM
life_s Ng life_s Ng is offline
Friend of Wrox
 
Join Date: Aug 2003
Location: , , .
Posts: 108
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via ICQ to life_s Ng Send a message via MSN to life_s Ng
Default

hi, i suggest u to use parameters for ur sql statement,

dim MySQL2 as string= "INSERT INTO Visitors (Name, TimeIn) Values (@Name, @TimeIn)"
               dim objCmd2 as New OleDbCommand(MySQL2, Conn)

                with objCmd2.Parameters:
                                  .Add(New OleDbParameter("@Name", Request.Cookies("VisName").Value ))
                                  .Add(New OleDbParameter("@TimeIn", Request.Cookies("TimeIn").Value))

               end with

some thing like this. check this out for more infomation.
http://aspnet101.com/aspnet101/tutorials.aspx?id=1

Regards
life's Ng