Click here to Skip to main content
15,900,108 members
Home / Discussions / C#
   

C#

 
GeneralRe: forums to NNTP Pin
Mridang Agarwalla14-Aug-05 3:36
Mridang Agarwalla14-Aug-05 3:36 
GeneralRe: forums to NNTP Pin
Dan Neely12-Aug-05 5:54
Dan Neely12-Aug-05 5:54 
GeneralWhere to get Hwnd from MS-Word Pin
fracalifa12-Aug-05 2:40
fracalifa12-Aug-05 2:40 
GeneralRe: Where to get Hwnd from MS-Word Pin
Igor_gratt12-Aug-05 4:36
Igor_gratt12-Aug-05 4:36 
GeneralRe: Where to get Hwnd from MS-Word Pin
Alomgir Miah12-Aug-05 6:34
Alomgir Miah12-Aug-05 6:34 
GeneralInserting Table into Data Set in Compact frame work Pin
praveenpavan12-Aug-05 2:03
praveenpavan12-Aug-05 2:03 
GeneralActiveMdiChild Problem Pin
Sheel Gohe12-Aug-05 1:56
Sheel Gohe12-Aug-05 1:56 
GeneralDataAdapter.Update Method Exception: "Concurrency Voilation: the update command affected 0 records..." Pin
signbit12-Aug-05 1:14
signbit12-Aug-05 1:14 
I am using MySqlConnector for .NET (version 1.0.4), I am using the following code for dataAdapter's update command:

this.codeListAdapter = new MySqlDataAdapter(
			"SELECT * FROM CodeList", this.myConnection);
			
MySqlCommand codeListUpdateCmd = new MySqlCommand(
				"UPDATE CodeList SET ProviderID=?ProviderID WHERE DestCode='?DestCode'", myConnection);
codeListUpdateCmd.Parameters.Add("?DestCode", MySqlDbType.VarChar, 10, "DestCode");
codeListUpdateCmd.Parameters.Add("?ProviderID", MySqlDbType.Int16,
				0, "ProviderID");
codeListAdapter.UpdateCommand = codeListUpdateCmd;

codeList = new DataTable("CodeList");
this.codeListAdapter.Fill(codeList);


and then I am using the following code, (after changing some rows of 'codeList' ofcourse):

codeListAdapter.Update(codeList);
codeList.AcceptChanges();


but it throws the Exception mentioned above, what might be the problem?

The structure of the 'CodeList' table is like this:

+-------------+-------------+------+-----+---------+-------+
| Field       | Type        | Null | Key | Default | Extra |
+-------------+-------------+------+-----+---------+-------+
| DestCode    | varchar(10) |      | PRI |         |       |
| Destination | varchar(50) | YES  |     | NULL    |       |
| ProviderID  | int(11)     |      | MUL | 0       |       |
+-------------+-------------+------+-----+---------+-------+


Thanks in advance...

- A programmer's national anthem; "AAAAAHHHHH!!!!"
QuestionHow to change the Color of Tittle bar in a Windows Form? Pin
pubududilena12-Aug-05 1:07
pubududilena12-Aug-05 1:07 
QuestionHow to Color Tool Bars using C#? Pin
pubududilena12-Aug-05 1:04
pubududilena12-Aug-05 1:04 
GeneralPrinting in C#.net Pin
Ming Luo12-Aug-05 1:02
Ming Luo12-Aug-05 1:02 
GeneralRe: Printing in C#.net Pin
Guffa12-Aug-05 2:00
Guffa12-Aug-05 2:00 
GeneralRe: Printing in C#.net Pin
Marshall12-Aug-05 2:06
Marshall12-Aug-05 2:06 
GeneralRe: Printing in C#.net Pin
Ming Luo12-Aug-05 2:20
Ming Luo12-Aug-05 2:20 
GeneralRe: Printing in C#.net Pin
Marshall12-Aug-05 2:41
Marshall12-Aug-05 2:41 
GeneralRe: Printing in C#.net Pin
| Muhammad Waqas Butt |14-Aug-05 2:41
professional| Muhammad Waqas Butt |14-Aug-05 2:41 
QuestionWhich child has been brought to front? Pin
bouli12-Aug-05 0:31
bouli12-Aug-05 0:31 
AnswerRe: Which child has been brought to front? Pin
mav.northwind12-Aug-05 0:52
mav.northwind12-Aug-05 0:52 
GeneralRe: Which child has been brought to front? Pin
bouli12-Aug-05 0:54
bouli12-Aug-05 0:54 
Generaltry catch and return value Pin
Os Sutrisno12-Aug-05 0:00
Os Sutrisno12-Aug-05 0:00 
GeneralRe: try catch and return value Pin
Colin Angus Mackay12-Aug-05 0:19
Colin Angus Mackay12-Aug-05 0:19 
GeneralRe: try catch and return value Pin
Os Sutrisno12-Aug-05 0:34
Os Sutrisno12-Aug-05 0:34 
GeneralRe: try catch and return value Pin
Colin Angus Mackay12-Aug-05 0:38
Colin Angus Mackay12-Aug-05 0:38 
GeneralRe: try catch and return value Pin
Os Sutrisno12-Aug-05 0:40
Os Sutrisno12-Aug-05 0:40 
QuestionRow colors in DataGrids? Pin
kbalias11-Aug-05 23:56
kbalias11-Aug-05 23:56 

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.