473,382 Members | 1,424 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,382 software developers and data experts.

Problem with assignment

I am having trouble with the following:

Dim Key As Byte() = {0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08, 0x09,
0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16}
Dim IV As Byte() = {0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08, 0x09,
0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16}

The IDE shows a build error with the message:

'}' expected

with the little blue wavy line underlining the first item in the list
(0x01). The interesting thing? I copied this from the help file in Visual
Studio. See the topic:

..NET Framework Developer's Guide
Encrypting Data [Visual Basic]

Thanx for any advice,
--
Anil Gupte
www.keeninc.net
www.icinema.com
Dec 15 '06 #1
1 1626
Great! That worked, although I have no idea why. Is the 0x01 the hex
format for C#? And the equivalent is &H01 in VB? Is there any other way to
represent Hex numbers?

Thanx,
--
Anil Gupte
www.keeninc.net
www.icinema.com

"Kerry Moorman" <Ke**********@discussions.microsoft.comwrote in message
news:C2**********************************@microsof t.com...
Anil,

You might try replacing 0x01 with &H01, etc.

Kerry Moorman
"Anil Gupte" wrote:
>I am having trouble with the following:

Dim Key As Byte() = {0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08,
0x09,
0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16}
Dim IV As Byte() = {0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08, 0x09,
0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16}

The IDE shows a build error with the message:

'}' expected

with the little blue wavy line underlining the first item in the list
(0x01). The interesting thing? I copied this from the help file in
Visual
Studio. See the topic:

..NET Framework Developer's Guide
Encrypting Data [Visual Basic]

Thanx for any advice,
--
Anil Gupte
www.keeninc.net
www.icinema.com

Dec 15 '06 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: August1 | last post by:
I've written an interface and implementation file along with a client source file that allows the use of an overloaded subtraction operator. However, when using the program, I'm running into a...
7
by: Jef Driesen | last post by:
Suppose I have an abstract base class that looks like this: template <typename T> class base { public: // Typedefs typedef double value_type; typedef std::size_t size_type; public: //...
14
by: Fredda | last post by:
Hello! I have problem with the following: >From the class 'Transaktion': ------------------------------------------------------------------------------------------------------ .. .. ..
78
by: Josiah Manson | last post by:
I found that I was repeating the same couple of lines over and over in a function and decided to split those lines into a nested function after copying one too many minor changes all over. The only...
10
by: toton | last post by:
Hi I have a class called Session, which stores a vector of Page, like vector<PageAlso each Page need's to know the Session to which it is attached. Thus I have, (the classes has many other...
2
by: toton | last post by:
Hi, I am trying to use boost::range with one of my own container class, and having some problem. I am missing some usage of range. Can anyone suggest a proper way for it ? To show the problem...
7
by: dragoncoder | last post by:
Hello experts, I have the following code me. =cat mystring.h #include<iostream> using namespace std; class mystring {
7
by: pallav | last post by:
I'm having some trouble with my copy constructor. I've tried using gdb to find the bug, but it seg faults in the destructor. I'm not able to see what I'm doing wrong. Since I'm using pointers, I...
15
by: vivekian | last post by:
Hi, I have this following class class nodeInfo ; class childInfo { public: int relativeMeshId ;
1
by: yccheok | last post by:
Hello all, I am confused on the correct assignment operator that should be implemented on the derived class. I refer to the document found at :- ...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
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...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

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.