Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

array of structures and 3rd party procedure (VB Newbie)

Status
Not open for further replies.

bloke

Programmer
Apr 23, 2001
9
AU
Hi There,

I have a 3rd party procedure that has a structure and
an integer as a row_count.

If I pass say 3 to the row_count, I am meant to get back
an array of structures up to 3 rows.

If I pass 1 and simply pass a structure, I get
back 1 row. If I pass 2, my VB app dies.

How do I set up my call to the proc so that this works.

The following may help explain...

procedure has a prototype of get_rec(my_struct, rows)

my code has

Dim datastruct as my_struct

iRet = get_rec(datastruct, 3)

The above does not work and if I do

Dim datastruct() as my_struct

iRet = get_rec(datastruct(), 3)

this does not work either

How do I set it up so that my_struct can be referenced
as an array when it wants to return more than one row.

Many Thanks

Chris P

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top