By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
446,320 Members | 2,218 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 446,320 IT Pros & Developers. It's quick & easy.

Beginner Question

P: n/a
Hi everyone. I tried to convert this line of code last night from vb.net to
C# and i had problems. Could anyone tell me you how you would convert this
line of code to C#:
Private Vector() As Byte = {&H12, &H44, &H16, &HEE, &H88, &H15, &HDD,
&H41}Of course the problem is with defining the hex values. I have no idea
how to do that in C# and when i searched on google how to do it i didn't
find any good examples.thanks
--
----------------------------------------------------
This mailbox protected from junk email by MailFrontier Desktop
from MailFrontier, Inc. http://info.mailfrontier.com
Nov 17 '05 #1
Share this Question
Share on Google+
2 Replies


P: n/a
Brent <br*****@remove.hotmail.com> wrote:
Hi everyone. I tried to convert this line of code last night from vb.net to
C# and i had problems. Could anyone tell me you how you would convert this
line of code to C#:
Private Vector() As Byte = {&H12, &H44, &H16, &HEE, &H88, &H15, &HDD,
&H41}Of course the problem is with defining the hex values. I have no idea
how to do that in C# and when i searched on google how to do it i didn't
find any good examples.thanks


byte[] Vector = new byte[] {0x12, 0x44, 0x16, 0xee, 0x88, 0x15, 0xdd,
0x41};

--
Jon Skeet - <sk***@pobox.com>
http://www.pobox.com/~skeet
If replying to the group, please do not mail me too
Nov 17 '05 #2

P: n/a
thanks jon

--
----------------------------------------------------
This mailbox protected from junk email by MailFrontier Desktop
from MailFrontier, Inc. http://info.mailfrontier.com

"Jon Skeet [C# MVP]" <sk***@pobox.com> wrote in message
news:MP************************@msnews.microsoft.c om...
Brent <br*****@remove.hotmail.com> wrote:
Hi everyone. I tried to convert this line of code last night from vb.net
to
C# and i had problems. Could anyone tell me you how you would convert
this
line of code to C#:
Private Vector() As Byte = {&H12, &H44, &H16, &HEE, &H88, &H15, &HDD,
&H41}Of course the problem is with defining the hex values. I have no
idea
how to do that in C# and when i searched on google how to do it i didn't
find any good examples.thanks


byte[] Vector = new byte[] {0x12, 0x44, 0x16, 0xee, 0x88, 0x15, 0xdd,
0x41};

--
Jon Skeet - <sk***@pobox.com>
http://www.pobox.com/~skeet
If replying to the group, please do not mail me too

Nov 17 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.