Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Data Size Error with VB/MySQL

Status
Not open for further replies.

L0stAngel

Programmer
May 5, 2005
58
US
Hello, I have a Visual Basic program that connects to a MySQL database. For sake of simplicity, I have a textbox, and a command button. When I click the Command Button, the folloing happens.

Code:
rs.fields("Information") = txtInfo.text & ""

When I hit the command button, it saves the data to the database. But, if I have more than 12 characters in the textbox, it gives me a 'Multi-Step Operation' error. In MySQL, I have the table set to Text, and set to 255 for the max characters. When I manually add data more than 12 characters to the DB, it works fine..but through my VB program, it doesnt work. Has anyone got a solution?
 
Try this:

rs.fields("Information") = Trim(txtInfo.Text) & ""

I used to rock and roll every night and party every day. Then it was every other day. Now I'm lucky if I can find 30 minutes a week in which to get funky. - Homer Simpson
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top