Welcome! Log In Create A New Profile

Advanced

Send array to a local procedure

Posted by emirhan 
emirhan
Send array to a local procedure
March 11, 2009 01:24PM
hi

I try to send an array to a procedure but it gives error "Error:'array' is a WLanguage keyword: improper use"
my code:

PROCEDURE TextRead(Name is string,FileContent is array of 1 string)

how can I send and array to a local procedure?
Michele Moscioni.pcs.crosspost
Re: Send array to a local procedure
March 11, 2009 02:49PM
emirhan ha scritto:
> hi
> I try to send an array to a procedure but it gives error "Error:'array' is a WLanguage keyword: improper use"
> my code:
> PROCEDURE TextRead(Name is string,FileContent is array of 1 string)
> how can I send and array to a local procedure?
>

I think you can obmit the FileContent declaration in the procedure
signature:
Eg.
PROCEDURE TextRead(Name,FileContent)

You can declare the procedure parameters in the calling code.

Hope this help

Ciao
Michele
Message forwarded from pcsoft.us.windev
Michele Moscioni.pcs.crosspost
Re: Send array to a local procedure
March 11, 2009 02:50PM
emirhan ha scritto:
> hi
> I try to send an array to a procedure but it gives error "Error:'array' is a WLanguage keyword: improper use"
> my code:
> PROCEDURE TextRead(Name is string,FileContent is array of 1 string)
> how can I send and array to a local procedure?
>
I think you can obmit the FileContent declaration in the procedure
signature:
Eg.
PROCEDURE TextRead(Name,FileContent)

You can declare the procedure parameters in the calling code.

Hope this help

Ciao
Michele
Message forwarded from pcsoft.us.windev
emirhan
Re: Send array to a local procedure
March 11, 2009 03:51PM
"You can declare the procedure parameters in the calling code" what does it mean?
Paulo Oliveira
Re: Send array to a local procedure
March 11, 2009 05:19PM
by default the procedure parameters are passed by reference (by address).
search the help for "Procedure, Local parameters" and you can find what you are looking for.
Array and class instances have some restrictions.
Author:

Your Email:


Subject:


Spam prevention:
Please, enter the code that you see below in the input field. This is for blocking bots that try to post this form automatically. If the code is hard to read, then just try to guess it right. If you enter the wrong code, a new image is created and you get another chance to enter it right.
Message: