Home > Net >  Using a listBox binding database and display the field data, selected a row and delete, suggest ther
Using a listBox binding database and display the field data, selected a row and delete, suggest ther

Time:10-10

CodePudding user response:

Judge code???????

CodePudding user response:

reference 1st floor ManBOyyy response:
judge code???????

CodePudding user response:

refer to the second floor levi_wuhui520 response:
Quote: refer to 1st floor ManBOyyy response:

Judge code???????

Obvious errors, you that is listBox1 selectItems. Count, this is the number of rows selected, and you put the rows as the table name???

CodePudding user response:

reference ManBOyyy reply: 3/f
Quote: refer to the second floor levi_wuhui520 response:

Quote: refer to 1st floor ManBOyyy response:

Judge code???????

Obvious errors, you that is listBox1 selectItems. Count, this is the number of rows selected, and you put the rows as the table name???
then I will delete the selected row data in the database of operating table name how to say

CodePudding user response:

reference 4 floor levi_wuhui520 response:
Quote: reference ManBOyyy reply: 3/f

Quote: refer to the second floor levi_wuhui520 response:

Quote: refer to 1st floor ManBOyyy response:

Judge code???????

Obvious errors, you that is listBox1 selectItems. Count, this is the number of rows selected, and you put the rows as the table name???
then I will delete the selected row data of the database table name how to say

The only ID should be access to database, and then you watch only constraint is that the Name, then you're listbox selected value, rather than the number of rows

CodePudding user response:

Out of the Error, so the table does not exist

CodePudding user response:

reference 5 floor ManBOyyy reply:
Quote: refer to 4th floor levi_wuhui520 response:

Quote: refer to the third floor ManBOyyy response:

Quote: refer to the second floor levi_wuhui520 response:

Quote: refer to 1st floor ManBOyyy response:

Judge code???????

Obvious errors, you that is listBox1 selectItems. Count, this is the number of rows selected, and you put the rows as the table name???
then I will delete the selected row data of the database table name how to say

The only ID should be access to database, and then you watch only constraint is that the Name, then you're listbox selected value, rather than the number of rows
well, specific how to write? (just contact, don't know much about)

CodePudding user response:

refer to 7th floor levi_wuhui520 response:
Quote: refer to fifth floor ManBOyyy response:

Quote: refer to 4th floor levi_wuhui520 response:

Quote: refer to the third floor ManBOyyy response:

Quote: refer to the second floor levi_wuhui520 response:

Quote: refer to 1st floor ManBOyyy response:

Judge code???????

Obvious errors, you that is listBox1 selectItems. Count, this is the number of rows selected, and you put the rows as the table name???
then I will delete the selected row data of the database table name how to say

The only ID should be access to database, and then you watch only constraint is that the Name, then you're listbox selected value, rather than the number of rows
well, specific how to write? (just contact, don't know much about)

Check first to learn how to add or delete database change
  •  Tags:  
  • C#
  • Related