TIP: Click on subject to list as thread! ANSI
echo: power_bas
to: BOB SEWELL
from: JAMES GOLDBLOOM
date: 1996-06-13 14:00:00
subject: Re: DAT files

 BS>   MQ>  TYPE test
 BS>   MQ>     a as STRING * 10
 BS>   MQ>  END TYPE
 BS>      In this case, Quintin is correct, and you are not.A
 BS>   fixed-length string variable, whether DIMmed or TYPEd, will
 BS>   always be that length and padded on the right with nulls.
 BS>   Therefore, while rtrim$ will strip the nulls out ofa
Yes, this has been discussed.  What you (and everyone else in this echo,
from what I've seen so far) keep forgetting is the original user in
the original message was defining one structure, then mapping it
to another variable.  And, the structure was reading data which earlier
was mapped as nulls by the program which created that data.
In other words, we really are all right (you, me, others) except for
the original user who misunderstood how the original data was created.
We ALL learned something here.  Maybe a few things...
* It's a waste to define a variable in a structure then copy it to another
  variable.
* Null data exists in most (if not nearly all) other data structures
  dynamically created by programs compiled in formats other than basic,
  as the padding character.  Local variables, and copied dimensioned
  ones mapping to the original, can be allocated with spaces.
So, I don't disagree with ya.  I just answered according to a *specific*
problem, and you guys are supplying excellent facts in a general sense.
-James
--- QuickBBS 2.80 GoldBase (Zeta-1.9A)
---------------
* Origin: [Team QuickBBS] [Team OmegaSoft] [PB Fanatic!] (FIDONET 1:109/611)

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