ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   TextBox6.Text = Application.??????????(TextBox6.Text) (https://www.excelbanter.com/excel-programming/326487-textbox6-text-%3D-application-textbox6-text.html)

Jim at Eagle

TextBox6.Text = Application.??????????(TextBox6.Text)
 
I need to properly display the state code in upper case.
Any suggestions?
--
Jim at Eagle

Dave Peterson[_5_]

TextBox6.Text = Application.??????????(TextBox6.Text)
 
with textbox6
.text = ucase(.text)
end with

VBA doesn't have a Proper function, so lots of people use:
application.proper(). But lcase() and ucase() both exist.

And you may want to look at strconv(), too.

It's another way to do string conversions.

Jim at Eagle wrote:

I need to properly display the state code in upper case.
Any suggestions?
--
Jim at Eagle


--

Dave Peterson

rcalvanese

TextBox6.Text = Application.??????????(TextBox6.Text)
 
StateCode = UCase(StateCode)

Bob Calvanese

"Jim at Eagle" wrote in message
...
I need to properly display the state code in upper case.
Any suggestions?
--
Jim at Eagle




keepITcool

TextBox6.Text = Application.??????????(TextBox6.Text)
 

Jim,

s'thing like following?

Private Sub TextBox1_BeforeUpdate(ByVal Cancel As MSForms.ReturnBoolean)
With TextBox1
If .Text < Trim(UCase$(.Text)) Then .Text = Trim(UCase$(.Text))
End With
End Sub

ucase, left right etc are function of the VBA object.

note that they come in 2 flavors... ucase and ucase$

the functions with a $ at the end always return a string variable
without the $ they return a variant. It you assign the result to a
string use the $ flavor, as it's faster to work with strings than
variants.



--
keepITcool
| www.XLsupport.com | keepITcool chello nl | amsterdam


Jim at Eagle wrote :

I need to properly display the state code in upper case.
Any suggestions?


Jim at Eagle

TextBox6.Text = Application.??????????(TextBox6.Text)
 
TextBox6.Text = UCase(TextBox6.Text)

Thanks Dave

"Dave Peterson" wrote:

with textbox6
.text = ucase(.text)
end with

VBA doesn't have a Proper function, so lots of people use:
application.proper(). But lcase() and ucase() both exist.

And you may want to look at strconv(), too.

It's another way to do string conversions.

Jim at Eagle wrote:

I need to properly display the state code in upper case.
Any suggestions?
--
Jim at Eagle


--

Dave Peterson



All times are GMT +1. The time now is 03:12 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com