Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
CType() in VB.NET
Message
General information
Forum:
ASP.NET
Category:
Other
Title:
CType() in VB.NET
Miscellaneous
Thread ID:
01013227
Message ID:
01013227
Views:
65
Is the following VB.NET code:
Dim MyNumber As Long
Dim MyNewType As Single
MyNumber = 1000
MyNewType = CType(MyNumber,Single)   ' MyNewType is set to 1000.0.
the same as te following C# code?
Int64 myNumber;
Single myNewType;
myNumber = 1000;
myNewType = (Single)myNumber;
The reason I am asking is because I am trying to find the equivalent of VB.NET's CType() in C#

Thanks,
Einar
Semper ubi sub ubi.
Next
Reply
Map
View

Click here to load this message in the networking platform