dbTalk Databases Forums  

How to define an Array in VBA behind the Access Forms

comp.databases.ms-access comp.databases.ms-access


Discuss How to define an Array in VBA behind the Access Forms in the comp.databases.ms-access forum.



Reply
 
Thread Tools Display Modes
  #11  
Old   
Dominic Vella
 
Posts: n/a

Default Re: How to define an Array in VBA behind the Access Forms - 01-22-2008 , 02:13 AM






Ahhhh, notice I mentioned the 'Char' and suggested using a string in VBA.
Yes, I did notice, didn't think it needed any further comment.

Cheers

Dominic

"SueB" <slbrick (AT) verizon (DOT) net> wrote

Quote:
So no one caught my error in the C Language explanation of what I am
looking to do? Hmmmm

struct recdata classinfo[8] =
{{ 0x01, "A" },
{ 0x01, "B" },
{ 0x01, "C" },
{ 0x02, "A" },
{ 0x02, "B" },
{ 0x02, "C" },
{ 0x03, "A" },
{ 0x03, "B" }};

is INCORRECT and it SHOULD BE ...

struct recdata classinfo[8] =
{{ 0x01, 'A' },
{ 0x01, 'B' },
{ 0x01, 'C' },
{ 0x02, 'A' },
{ 0x02, 'B' },
{ 0x02, 'C' },
{ 0x03, 'A' },
{ 0x03, 'B' }};

notice the single quotes (') instead of the double quotes (") because
the second field in the structure is defined as a single CHAR (1 byte)
and not an array of CHARs (aka STRING).

That'll teach me to type these posts way after midnight here on the
EastCoast of USA.

Thanks, again to all those who responded.

Regards,
SueB

*** Sent via Developersdex http://www.developersdex.com ***



Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.