cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 
2024 Technology Preview Program

2024 Technology Preview Program:
Master powerful new features and shape the latest BIM-enabled innovations

Libraries & objects
About Archicad and BIMcloud libraries, their management and migration, objects and other library parts, etc.

how to hide my parameters programmatically.

Anonymous
Not applicable
something like this

if marker="Section"
hide parameter
else
visible parameter
endif

any suggestion?

tnx
3 REPLIES 3
__archiben
Booster
mackyboy wrote:
any suggestion?
close . . .

!!   if these are the parameters you want to hide...

myParameter1 = 1
myParameter2 = 2
myParameter3 = 3

!!   ...this is the code

if marker = "Section" then
     hideparameter   myParameter1, myParameter2, myParameter3
endif

!!   you don't need a "showparameter" control because
!!   it will always be visible unless you hide it.
!!   i.e. if 'marker' is NOT "Section" it will be visible.



!!   you may also want to lock them at the same time...

if marker = "Section" then
     hideparameter   myParameter1, myParameter2, myParameter3
     lock   myParameter1, myParameter2, myParameter3
endif

!!   ...or you can simply lock them without the hiding so that
!!   the user knows that they exist. may be an option?
be sure to put this kind of code in the parameter script. you may also want to check out page 185 of the GDL reference guide ( Help>AC11 GDL Reference Guide ).

~/archiben
b e n f r o s t
b f [a t ] p l a n b a r c h i t e c t u r e [d o t] n z
archicad | sketchup! | coffeecup
Anonymous
Not applicable
Hello,

The parameter names should be in quotes if you hide or lock;

if mySetting= "Hide them" then
hideparameter "myParam1", "myParam2"
endif

if mySetting= "Lock them" then
lock "myParam1", "myParam2"
endif

if mySetting= "Change them" then
parameters myParam1="No quotes here", myParam2="Or here"
endif
Anonymous
Not applicable
many thanks