Design forum
cancel
Showing results for 
Search instead for 
Did you mean: 

String's

wilson83
Newcomer
Can anyone give me some insight into Strings? I cant seem to grasp what the underlying concept in using them.

For example, the following code is for a title marker I am TRYING to make. The marker detects the drawings scale and determines what scale bar to show.

n = SPLIT (AC_DrawingScale, "%n:%n", num1,notUsed, num2)
IF num2=100 THEN
MUL2 100,100
GOSUB 100:
ENDIF
IF num2=200 THEN
GOSUB 200:
ENDIF
IF num2=500 THEN
GOSUB 500:
ENDIF


The GOSUBS refer to the various scale bars that I have drawn. I can’t claim credit for the SPLIT command- I pulled that out of another title marker (which is probably part of my problem). Can someone explain to me what I need to make this work and/or why this won’t work? The way I understand it is that num1 and num2 are return the values of scale (1:100 into num1:num2). If num2 =100 then the 1:100 scale is displayed and so on.

Cheers

AC14 on windows 7
Michael Wilson

ArchiCAD 9 - 22 (6021 AUS Full)
Win7 | 64 bit | 8Gb RAM | Intel i7 3.40 Ghz
1 REPLY 1

wilson83:

The code works for me, but you need to add the parameter AC_DrawingScale to your object for this value to be available. Also, this will not work in the library editing window 2D Full View, you need to place a view in a layout and assign this title to it for testing.

HTH,

David
David Maudlin / Architect
www.davidmaudlin.com
Digital Architecture
AC24 USA • iMac 27" 4.0GHz Quad-core i7 | 24 gb ram • MacBook Pro 2.8GHz | 16 gb ram • OSX10.14.6

Didn't find the answer? Start a new discussion

Labels

Still looking?

Browse more topics

Back to forum

See latest solutions

Accepted solutions

Start a new discussion!