473,320 Members | 2,088 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Difference between directcast and ctype.

Difference between directcast and ctype.
Aug 24 '06 #1
1 3781
krodman
12
Microsoft has a pretty good explanation on the MSDN website.

http://msdn.microsoft.com/library/de...DirectCast.asp
Aug 24 '06 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

4
by: Andreas Klemt | last post by:
Hello, what has the better performance and what are you using? Dim myObj As Object = 70 a) Dim myInt As Integer = DirectCast(myObj, Integer) b) Dim myInt As Integer = Convert.ToInt32(myObj) ...
3
by: Mark Kamoski | last post by:
Hi-- What is the difference between Convert.ToString(obj) and CType(obj, String)? (Assume obj is a variable of type Object.) Please advise. Thank you.
11
by: Tubs | last post by:
i am attempting to write something which can morph itself to whatever comes in and get the value property from it but i don't know what type it is until runtime. I am therefore trying to use...
5
by: Michael Ramey | last post by:
Hello, There are quite a few ways to convert one object, say an integer to a string. Dim myStr as string dim myInt as integer = 123 myStr = cstr(myInt) myStr = myInt.toString()
6
by: Mark Nethercott | last post by:
I get the following failure when trying to access the builtin properties; An unhandled exception of type 'System.InvalidCastException' occurred in resultsoutput.dll Additional information:...
1
by: iwdu15 | last post by:
can anyone explain the directcast code...ive tried using it and lookin it up but im lookin for an easy definition and how it works...ive tried using it before byut it throws errors saying it can...
4
by: Vagabond Software | last post by:
Here is the code: Dim amountDue As Double amountDue = Math.Round(DirectCast(strOrderTotal, Double), 2) This code produces an invalid cast exception. The String variable strOrderTotal...
5
by: c_shah | last post by:
Very beginner question.. What's difference between cstr vs .ToString vs Ctype for converting to String?
3
by: =?Utf-8?B?TWlrZQ==?= | last post by:
If Visual Studio knows the type, why does the system-generated property use CType instead of DirectCast? DirectCast is more efficient right? For example - Here's what we have for a setting...
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.