TIP: Click on subject to list as thread! ANSI
echo: power_bas
to: TIM HUTZLER
from: THOMAS GOHEL
date: 1996-06-13 00:00:00
subject: Re: Can`t see array in subs

In article "Can't see array in subs" (on 10.06.96), Tim Hutzler@1:119/88 
ys:
Hello Tim !!
> DIM rec AS SHARED Crec
>
> In the body I can reference it okay, but when I reference it in a sub from
> within a sub - I get a 481 error.
That's correct.
> SUB mysub (x%)
>     ...
> ....Pfield "Street Name: ", rec.StName, 20
> Error points here---------------------^
>
>
> The argument count is correct,...
>
> SUB Pfield (x$, y$, l%)
Use the BYVAL statment, so try
SUB Pfield (x$, BYVAL y$, l%)
                ^^^^^
> Any advise or suggestions would be appreciated.
simple problems ... 
> tnx
Regards,
                             ----------------
                                /
                              /  h o m a s
email: author@pbsound.snafu.de
www  : http://www.snafu.de/~pbsound/ (PowerBASIC's Home in Germany)
       PBSOUND - The Sound Blaster Toolkit, PowerBASIC-FAQ, PowerBASIC-
       sources & toolboxes, PowerBASIC on Web, PowerBASIC News and much
       more or less important PowerBASIC stuff.
--- CrossPoint v3.1 R
---------------
* Origin: -= http://www.snafu.de/~pbsound/ =- (2:2410/301.12)

SOURCE: echomail via exec-pc

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.