PC SOFT

FORUMS PROFESSIONNELS
WINDEVWEBDEV et WINDEV Mobile

Accueil → WINDEV 2024 → [WD7.5] Structure data type
[WD7.5] Structure data type
Débuté par Raimund Schuldhaus, 30 juil. 2003 11:11 - 1 réponse
Posté le 30 juillet 2003 - 11:11
Hi,
Is there a way to pass different variables of type STRUCTURE to a procedure and then access them in a generic manner?
Eg.
strucTest1 is structure
nTest1 is int
sTest2 is string
END
strucTest2 is structure
sTest1 is string
sTest2 is string
sTest3 is string
sTest4 is string
END
s1 is strucTest1
s2 is strucTest2
DoIt(s1)
DoIt(s2)
And in "DoIt" I want now enumerate the number of passed elements and have access to them. Passing a variable of type STRUCTURE isn't the problem, the problem is the generic access.
Thanks
Raimund

http://www.invitec.com
Posté le 01 août 2003 - 14:06
Hi Raimund,
Is there a way to pass different variables of type STRUCTURE to a procedure and then access them in a generic manner?
Eg.
strucTest1 is structure
nTest1 is int
sTest2 is string
END
strucTest2 is structure
sTest1 is string
sTest2 is string
sTest3 is string
sTest4 is string
END
s1 is strucTest1
s2 is strucTest2
DoIt(s1)
DoIt(s2)
And in "DoIt" I want now enumerate the number of passed elements and have
access to them. Passing a variable of type STRUCTURE isn't the problem, the
problem is the generic access.

--
Don't think it is possible to find the members of a structure in a generic way.
Peter


http://www.xs4all.nl/~petervu