[futurebasic] RE: [FB] code resources

Message: < previous - next > : Reply : Subscribe : Cleanse
Home   : June 1999 : Group Archive : Group : All Groups

From: Chris.Young@...
Date: Wed, 2 Jun 1999 13:59:59 -0500
Don't know for sure. The DCOD is in the compiled app's resource fork, I 
presume?

One other comment:

Are you sure you don't have your parameters reversed?

CALL "DCOD", 1935,(@Val&,@arrayval&(0))

looks like @Val& is a pointer to a long, followed by a pointer to an 
array (@arrayval&(0)).

whereas your main is 

void main(long *arrayAddress,long *valAddress),

where the first pointer appears to be that to an array. I would think 
you need to reverse either your call or the main.

Chris Young


On Wednesday, June 02, 1999 1:33 PM, support 
[SMTP:support@...] wrote:
> Hello futurebasic people,
> 
> I have a c-code resource that I pass the address of a variable and an
> array like this:
> 
> CALL "DCOD", 1935,(@Val&,@arrayval&(0))
> 
> In the c-code I have set up the main like this:
> 
> void main(long *arrayAddress,long *valAddress)
> 
> Then I use a for loop to store the array variables locally:
> 
> for(x=0;x<=30;x++)
> {
>     mylocalarray[x] = arrayAddress[x];
> }
> 
> This works fine while running from the development environment, but as
> soon as I compile it, it causes a Type 1 error as soon as the first
> iteration of the for loop assigns the array value. Does anyone have
> any ideas or thoughts that might keep me in hair for a little while
> longer???
> 
> 
> Best wishes,
> Robert Price
> Programmer/Technical Support
> support@...
> 
> 
> 
> 
> --
> To unsubscribe, send ANY message to 
<futurebasic-unsubscribe@...>
>  << File: [FB] code resources.TXT >>