Mid & Val

  • Thread starter Thread starter André Almeida Maldonado
  • Start date Start date
A

André Almeida Maldonado

Hy Guys, what is the methods that works like the Mid and Val VB6
Functions???

Thank's
 
André Almeida Maldonado said:
Hy Guys, what is the methods that works like the Mid and Val VB6
Functions???

They are the same in VB.NET.

See also my link in your other thread.
 
Mid and Val are available in the Microsoft.VisualBasic namespace.

Regards - OHM


André Almeida Maldonado said:
Hy Guys, what is the methods that works like the Mid and Val VB6
Functions???

Thank's

Regards - OHM# (e-mail address removed)
 
André Almeida Maldonado said:
is the methods that works like the Mid and Val VB6 Functions???

Mid() <= String.SubString()

Beware: CLR String's index from zero, not one, so

Mid( sText, 2 ) becomes sText.SubString( 1 )

Val() <= Integer.Parse( ) (or similar for the other types)

The VB String functions are still there (in Microsoft.VisualBasic)
but, IIRC, are just wrappers for the underlying CLR String methods.

HTH,
Phill W.
 
Hi Andre

There are no methods for that there is only the Mid and Val functions in
VB.net.

But because you want to use only the C# compatible subset it seems, I think
that you can use for simulating the Mid function the stringbuilder and for
the Val the regulair expression.

Success

Cor
 
Andre'

If you want the framework near equivalents...

For Mid use StringVariable.Substring()

For Val there isn't an exact equivalent, but Double.Parse is close.

Kathleen
 
Hi Kathleen,
If you want the framework near equivalents...

Do you have information I have not?

My information is that the MID and VAL are full part of the framework.

Can you send me a link or something, I am curious for that?

Cor
 
* "Cor said:
Do you have information I have not?

My information is that the MID and VAL are full part of the framework.

They are part of the framework, but not part of the framework class
library. They are part of the Microsoft Visual Basic .NET Runtime
library which is part of the .NET Framework.
 
* "One Handed Man said:
Mid and Val are available in the Microsoft.VisualBasic namespace.

ACK. They are members of 'Microsoft.VisualBasic.Strings' ('Mid') and
'Microsoft.VisualBasic.Conversion' ('Val').
 
Hi Herfried,
They are part of the framework, but not part of the framework class
library. They are part of the Microsoft Visual Basic .NET Runtime
library which is part of the .NET Framework.
I try this translate it on a way I can understand with a metaphor

Wien is in Europe but not as a country, it is a part of Austria, which is a
part of Europe.

(And Bruxelles is a part of Europe).

Is that what you mean?

Cor
 
Yes, of course. They are modules in that namspace which contain the
aforesaid functions.

Regards - OHM
* "One Handed Man [ OHM# ]"
Mid and Val are available in the Microsoft.VisualBasic namespace.

ACK. They are members of 'Microsoft.VisualBasic.Strings' ('Mid') and
'Microsoft.VisualBasic.Conversion' ('Val').

Regards - OHM# (e-mail address removed)
 
Hi Crirus,

Dont you see it, Armin has pity those long threads are gone and now he
starting one himself

:-))))))))))))))

Cor
 
EOT, From a telecoms background by any chance ?

Regards - OHM


Armin said:
I don't say what he also was.

EOT for me

Regards - OHM# (e-mail address removed)
 
* "Cor said:
I try this translate it on a way I can understand with a metaphor

Wien is in Europe but not as a country, it is a part of Austria, which is a
part of Europe.

(And Bruxelles is a part of Europe).

Is that what you mean?

IMO wrong "translation".

..NET Framework = Europe
Visual Basic .NET Runtime Library = Austria
Framework Class Libary = all other countries in Europe

;-)
 
Back
Top