|
-
Jul 31st, 2010, 10:57 AM
#1
Thread Starter
PowerPoster
[RESOLVED] Converting Data to UpperCase?
I have a SQL Server Table that contains country names. I have this table bound to a ComboBox control on one of my forms. The data itself witin the talbe is in lower case.
My question is, how can I convert the data to upper case either in the table or the ComboBox?
Thanks,
-
Jul 31st, 2010, 11:27 AM
#2
Re: Converting Data to UpperCase?
If you don't need the original text in your app then just include the conversion to upper case in your query. I would assume that T-SQL includes a function that converts text to upper case so you should be able to find it in Books Online simply enough.
-
Jul 31st, 2010, 12:21 PM
#3
Thread Starter
PowerPoster
Re: Converting Data to UpperCase?
Well, the dataset is "typed" and bound to the ComboBox. I did this in design mode so I'm not sure how I would do that.
-
Jul 31st, 2010, 08:35 PM
#4
Re: Converting Data to UpperCase?
How do you usually modify things in the designer? You select them with the mouse and then you either edit them in-situ (which might involve drag'n'drop or a right-click) or else you make changes in the Properties window.
-
Jul 31st, 2010, 10:22 PM
#5
Thread Starter
PowerPoster
Re: Converting Data to UpperCase?
I used the Properties window to assign the Datasource to the combobox and then selected a field for the DisplayMember. I don't know what to do in order to convert the Country Name to uppercase.
-
Aug 1st, 2010, 02:53 AM
#6
Re: Converting Data to UpperCase?
I'm not talking about the ComboBox. I'm talking about changing your SQL code. Open your DataSet in the designer, select your TableAdapter and open the Properties window.
-
Aug 1st, 2010, 10:18 AM
#7
Thread Starter
PowerPoster
Re: Converting Data to UpperCase?
jmc,
I see what your talking about. I got into the designer of the BindingSource and modified the SQL using the function "ucase" and that worked.
Thanks for your help!
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|