GDL
About building parametric objects with GDL.
SOLVED!

Show Parameter function

jc4d
Expert

Hello,

We have a hideparameter function, but is there a showparameter somewhere hidden in the deeps of gdl code?

 

I want to show a parameter only when couple of conditions are met among the many I have.

 

 

IF door_opening <> 1 AND multi_door <> 1 THEN
	HIDEPARAMETER "second_door_opening"
ENDIF

 


The idea behind it is, if the door_opening and multi_door are both different than 1, then hide the parameter. For some reason is not working for me.

For example, if door_opening = 2 and multi_door = 1, the parameter is showing still, which is not what I want. Only if door_opening = 1 and multi_door = 1 the parameter should show, otherwise keep it hidden.

 

Hope all  this makes sense.

 

Juan.

1 ACCEPTED SOLUTION

Accepted Solutions
Solution
AllanP
Advocate

Hi,

 

what you said in the first half of you description was

"if the door_opening and multi_door are both different than 1, then hide the parameter"

IF door_opening # 1 AND multi_door # 1 THEN
	HIDEPARAMETER "second_door_opening"
ENDIF

***Not the outcome you describe in the second part of your description

 

what you said in the second half of your your description was

"Only if door_opening = 1 and multi_door = 1 the parameter should show, otherwise keep it hidden"

 

IF door_opening = 1 AND multi_door = 1 THEN
       !!!Show the parameter
ELSE
	HIDEPARAMETER "second_door_opening"
ENDIF

 

 

there is no "SHOWPARAMETER" command.

 

another way to write that in English would be:

"if the door_opening is different than 1 or multi_door is different than 1, then hide the parameter,

so only if door_opening = 1 and multi_door = 1 the parameter should show, otherwise keep it hidden."

IF door_opening # 1 OR multi_door # 1 THEN
	HIDEPARAMETER "second_door_opening"
ENDIF

 

The AND/OR for exclusion combinations are sometimes confusing.

the # "not equal to" is on the Shift+3 key on the keyboard.

 

I hope this helps.

I have been using ArchiCAD continually since ArchiCAD 4.5, 4.5.5, 5, 5.1, 6, 6.5, 7, 8, 8.1, 9, 10, 11, 12, 13, 15, 18, 21, 22, 25, now testing 27
Member of Architalk since 2003, but missed the migration to Graphisoft.
(where have all my original posts gone?)

View solution in original post

2 REPLIES 2
jc4d
Expert

It seems like using OR instead of AND it does the trick, but not sure if it is the right way.

IF door_opening <> 1 OR multi_door <> 1 THEN
	HIDEPARAMETER "second_door_opening"
ENDIF

 

Juan

Solution
AllanP
Advocate

Hi,

 

what you said in the first half of you description was

"if the door_opening and multi_door are both different than 1, then hide the parameter"

IF door_opening # 1 AND multi_door # 1 THEN
	HIDEPARAMETER "second_door_opening"
ENDIF

***Not the outcome you describe in the second part of your description

 

what you said in the second half of your your description was

"Only if door_opening = 1 and multi_door = 1 the parameter should show, otherwise keep it hidden"

 

IF door_opening = 1 AND multi_door = 1 THEN
       !!!Show the parameter
ELSE
	HIDEPARAMETER "second_door_opening"
ENDIF

 

 

there is no "SHOWPARAMETER" command.

 

another way to write that in English would be:

"if the door_opening is different than 1 or multi_door is different than 1, then hide the parameter,

so only if door_opening = 1 and multi_door = 1 the parameter should show, otherwise keep it hidden."

IF door_opening # 1 OR multi_door # 1 THEN
	HIDEPARAMETER "second_door_opening"
ENDIF

 

The AND/OR for exclusion combinations are sometimes confusing.

the # "not equal to" is on the Shift+3 key on the keyboard.

 

I hope this helps.

I have been using ArchiCAD continually since ArchiCAD 4.5, 4.5.5, 5, 5.1, 6, 6.5, 7, 8, 8.1, 9, 10, 11, 12, 13, 15, 18, 21, 22, 25, now testing 27
Member of Architalk since 2003, but missed the migration to Graphisoft.
(where have all my original posts gone?)