3
Answers

Text Box Methid

George Laing

George Laing

16y
3.6k
1

Hi ,
   I have a screen with a text box, . I want to be able to edit a number to show as currency before the screen is loaded and when someone enters a number I want it to show as currency. I cannot figure out which method I would use to put my code in. The text box is txt_Final_Sale. I tried
 txt_Final_Sale_Enter((object sender, EventArgs e)
{
}

But it did not activate. Can anyone tell me which property or method I need to use to execute code for the text box?

Thanks,

Answers (3)
0
Jignesh Trivedi
NA 61k 14.2m 12y
hi,

mostly this error comes when your size of input is exceed.
Example I have one table and it has one column say name and size of name column is varchar(20), now i am trying to insert name in this table with length 25. at that time sql server throw this error.

So recommended that chat your input and database size.

hope this help.
Accepted
0
Senthilkumar
NA 15.2k 2.4m 12y
Hi,

The reason for this error is clear.

When you set the size to your column in the sql server table, then you need to do insert/update with the required size of the data.

Support, you have a table called register

CREATE TABLE Register
(
   ID INT IDENTITY(1,1)
  ,Name VARCHAR(10)
)

INSERT INTO Register(Name) VALUES('AAAAABBBBBBCCCCCC')

Here the actual size of the Name column is 10 and you are trying to insert 15 chars, then you will get string binary truncated.




0
Shesh Mishra
NA 22 28.1k 12y
thank you sir I will try it.