Click here to Skip to main content
15,900,366 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: Easy VBScript question about the file pointer Pin
NetPointerIN11-Sep-03 9:42
NetPointerIN11-Sep-03 9:42 
GeneralBasic DataGrid Navigation. Pin
Steverty10-Sep-03 10:32
Steverty10-Sep-03 10:32 
Generalconverting vb double to vc double Pin
Member 57284910-Sep-03 8:04
Member 57284910-Sep-03 8:04 
GeneralRe: converting vb double to vc double Pin
Nic Rowan10-Sep-03 23:44
Nic Rowan10-Sep-03 23:44 
GeneralRe: converting vb double to vc double Pin
Member 57284911-Sep-03 4:07
Member 57284911-Sep-03 4:07 
GeneralRe: converting vb double to vc double Pin
Nic Rowan11-Sep-03 8:06
Nic Rowan11-Sep-03 8:06 
GeneralConvert from VS.Net 2003 to VS.Net Pin
Orcrist10-Sep-03 6:12
Orcrist10-Sep-03 6:12 
GeneralDeleteCommand problem.. Pin
GJul10-Sep-03 4:48
GJul10-Sep-03 4:48 
Hello,

I've problem with the sqlDataAdapter.DeleteCommand. When I Insert or Update data there are no problem.. but when I delete data, there is no error but nothing happend in the database..

Here is the code..

'select no problem Big Grin | :-D
cmdSelect = Database.CreateCommand("cContact_SelectAllByVehicle")
cmdSelect.CommandType = CommandType.StoredProcedure
cmdSelect.Parameters.Add("@ID_Vehicle", 1)
sqlDaClient.SelectCommand = cmdSelect

'delete dosent'work Cry | :((
cmdDelete = Database.CreateCommand("delete from cContact WHERE ID_Contact = @ID_Contact and ID_Vehicle = @ID_Vehicle")
cmdDelete.CommandType = CommandType.Text
cmdDelete.Parameters.Add(New SqlParameter("@ID_Contact", SqlDbType.Decimal, 0, "ID_Contact"))
cmdDelete.Parameters.Add(New SqlParameter("@ID_Vehicle", 1))
sqlDaClient.DeleteCommand = cmdDelete

'insert no problem Big Grin | :-D
cmdInsert = Database.CreateCommand("insert into cContact(ID_Vehicle, ID_Contact, Rate) values(@ID_Vehicle, @ID_Contact, @Rate)")
cmdInsert.CommandType = CommandType.Text
cmdInsert.Parameters.Add(New SqlParameter("@ID_Vehicle", 1))
cmdInsert.Parameters.Add(New SqlParameter("@ID_Contact", SqlDbType.Decimal, 0, "ID_Contact"))
cmdInsert.Parameters.Add(New SqlParameter("@Rate", SqlDbType.Float, 0, "Rate"))
sqlDaClient.InsertCommand = cmdInsert

'update no problem Big Grin | :-D
cmdUpdate = Database.CreateCommand("UPDATE cContact SET Rate = @Rate WHERE ID_Contact = @ID_Contact and ID_Vehicle = @ID_Vehicle")
cmdUpdate.CommandType = CommandType.Text
cmdUpdate.Parameters.Add(New SqlParameter("@ID_Contact", SqlDbType.Decimal, 0, "ID_Contact"))
cmdUpdate.Parameters.Add(New SqlParameter("@ID_Vehicle", 1))
cmdUpdate.Parameters.Add(New SqlParameter("@Rate", SqlDbType.Decimal, 0, "Rate"))
sqlDaClient.UpdateCommand = cmdUpdate

sqlDaClient.Fill(dtClient)

dtClient.Rows.RemoveAt(0)

sqlDaClient.Update(dtClient)



I really need some help.. thanks..

Julien
Generalall about exceptions Pin
fume9-Sep-03 22:09
fume9-Sep-03 22:09 
GeneralRe: all about exceptions Pin
SimonS9-Sep-03 22:11
SimonS9-Sep-03 22:11 
GeneralRe: all about exceptions Pin
fume10-Sep-03 14:08
fume10-Sep-03 14:08 
GeneralRe: all about exceptions Pin
fume10-Sep-03 14:17
fume10-Sep-03 14:17 
Generalerror bad dll calling convention Pin
Member 5728499-Sep-03 12:15
Member 5728499-Sep-03 12:15 
GeneralRe: error bad dll calling convention Pin
Hesham Amin9-Sep-03 21:43
Hesham Amin9-Sep-03 21:43 
GeneralRe: error bad dll calling convention Pin
Member 57284910-Sep-03 4:22
Member 57284910-Sep-03 4:22 
GeneralRe: error bad dll calling convention Pin
Member 57284910-Sep-03 7:22
Member 57284910-Sep-03 7:22 
GeneralNewbie to VB need some advice please Pin
Flack9-Sep-03 7:04
Flack9-Sep-03 7:04 
GeneralRe: Newbie to VB need some advice please Pin
Ray Cassick9-Sep-03 7:45
Ray Cassick9-Sep-03 7:45 
GeneralRe: Newbie to VB need some advice please Pin
NetPointerIN11-Sep-03 9:51
NetPointerIN11-Sep-03 9:51 
GeneralRe: Newbie to VB need some advice please Pin
Ray Cassick11-Sep-03 9:56
Ray Cassick11-Sep-03 9:56 
GeneralDeploy .Net Application using Access Database Pin
zengfu9-Sep-03 4:54
zengfu9-Sep-03 4:54 
GeneralRe: Deploy .Net Application using Access Database Pin
SimonS9-Sep-03 22:09
SimonS9-Sep-03 22:09 
GeneralAccessing a VC++ DLL in VB Pin
Member 5728498-Sep-03 12:18
Member 5728498-Sep-03 12:18 
GeneralRe: Accessing a VC++ DLL in VB Pin
Steve S9-Sep-03 6:22
Steve S9-Sep-03 6:22 
GeneralRe: Accessing a VC++ DLL in VB Pin
Member 5728499-Sep-03 7:02
Member 5728499-Sep-03 7:02 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.