TIP: Click on subject to list as thread! ANSI
echo: power_bas
to: THOMAS GOHEL
from: TIM HUTZLER
date: 1996-06-16 09:16:00
subject: Re: Passing a field

 -=> Quoting Thomas Gohel to Tim Hutzler <=-
 >     POUT x%, y$, t.str
 >
 > loop until y$ = "."
 >
 >
 > SUB pout (x%, x$, t$)
 >     PRINT x%, x$, t$
 >     t$ = "vxvxvxv."
 > END SUB
 >
 > ===================================
 > This tells me that PB thinks t.str is a non-string in a subroutine call.
TG> The difference is, 't.Str' is a 'Fixed lenght string' and not a
  > 'Dynamic String'. What I mean, for a 'Dynamic String' do you need
  > a string handle on the parameter stack, but not for a 'Fixed
  > lenght String'.
So, you are saying that PowerBASIC has *no* provisions to accomodate the
passing of records for modification defined in a TYPE???
What do I need do to to reference the element *and* make
modifications to it from within a SUB? QuickBASIC doesn't have this
problem, frankly I am suprised that PowerBASIC can't deal with
this.
The only way around this is to jocky the pointer as in the following:
x$ = t.str
SUB x$
t.str = x$
There's got to be a more elegant way.
Isn't there?
 
--- Maximus/2 3.01
---------------
* Origin: Madman BBS * Chico, California * 916-893-8079 * (1:119/88)

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™.