Hi,
what should i use to make the data inserted is in all capital letter?
here is insert statement:

string query = "INSERT into Categories  values (' " + textbox5_value + " ', ' " + textbox6_value + " ', ' " + textbox7_value + " ' )";

strToUpper() is used to make it convert to all capital letter but i don't know where should i put it? can i use this?

Recommended Answers

All 2 Replies

Hi,
what should i use to make the data inserted is in all capital letter?
here is insert statement:

string query = "INSERT into Categories  values (' " + textbox5_value + " ', ' " + textbox6_value + " ', ' " + textbox7_value + " ' )";

strToUpper() is used to make it convert to all capital letter but i don't know where should i put it? can i use this?

You can do it in the following way assuming that your values are already in string form:

string query = "INSERT into Categories  values (' " + textbox5_value.ToUpper() + " ', ' " + textbox6_value.ToUpper() + " ', ' " + textbox7_value.ToUpper() + " ' )";

However, if the input is not in string form then you will need to convert to string prior to appending the .ToUpper().

TQ2..

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.