String Methods

S

S Shulman

Hi
Is there any casting methods in VB.NET to e.g. cast 'ThE' to 'The' etc.

Thank you
Shmuel Shulman,
SBS Technologies LTD
 
N

news.microsoft.com

Dim mystring As String = "tHe"

mystring = StrConv(mystring, vbProperCase)

MsgBox(mystring)
 
J

JohnFol

Casting occurs when you change 1 type to another. In your example both input
and output are strings.

Have a look at StrConv, ie

Dim x As String = "ThE tEsT"

MsgBox(StrConv(x, VbStrConv.ProperCase))
 
H

Herfried K. Wagner [MVP]

S Shulman said:
Is there any casting methods in VB.NET to e.g. cast 'ThE' to 'The' etc.

\\\
s = StrConv("hello world", VbStrConv.ProperCase)
///
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

[email protected] 1
bitwise operations 1
NumericUpDown Control 2
Menu Question 3
Status Bar 2
MenuItem35.PerformClick() 2
FontFamily.GetFamilies Method Question 1
Get the system colours 2

Top