How to set default value for char

  • Thread starter Thread starter tshad
  • Start date Start date
T

tshad

I can't seem to find anywhere how to set a null value (default) to a char
variable.

I know you typically set a char as:

Dim temp as Char = "a"

But how do you set it to binary 0 (null).

In C# it would be:

char temp = '\0'

Thanks,

Tom
 
I can't seem to find anywhere how to set a null value (default) to a char
variable.

I know you typically set a char as:

Dim temp as Char = "a"

But how do you set it to binary 0 (null).

In C# it would be:

char temp = '\0'

Thanks,

Tom

dim temp as char = chr(0)
 
Tom Shelton said:
Other then that won't compile with Option Strict On? You do have
Option Strict On don't you?

I didn't and it didn't compile as you said.

Thanks,

Tom
 
Back
Top