okay i have a problem with my programm...i am using OleDb for my database .And updating the database is throwing an exception ...
that states "no value given for one or more specific parameter"
the code is
cmd.CommandText = @"UPDATE "+ client.GetKey(clientComboBox.SelectedIndex).ToString().Replace(' ','_').Replace(',','_') + @" SET Cno = Cno, [Date] = date,Origin = origin, Destination = destination, SenderAddress = senderAdd, ConAddress = conAdd, Dox = ""dox"", NonDox = nonDox, Express = express, AirCargo = airCargo, Surface = road, Kgms = kgms, Amount = amount WHERE Cno = str" ;
amount = cno = kgms are int
the rest are strings
What does your statement look like, after your put it together ? Print the finished statement out to see what's wrong.
Actually, i got it..This was the problem
I was only giving a huge string ..it should had been done this way
NonDox ='" + nonDox + "', Express='" + express + "' " ... etc.