[Frage] Layout name in Custom Title Block [Gelöst]


Hello Everyone,

I'm having troubles creating a Label Style, used in a custom Title Block.
The label style should work based on a formula, which combines different values.
For example:

"123_"+[Layout name]+"_abc"

which, in the formula definition window, translates to:

"123_"+@445@+"_abc"

After saving it, I have placed the Title Block in a Layout.
You can see the resulting text in the Title Block as shown in Capture 03.

I just can not understand why the software puts a bunch of spaces into the [Layout name]-@445@ field.
As if it tries to fill in the available length of the attribute, all the 70 placeholders.

I have checked the name of the Layout (in the Properties window as well), there are no spaced at the end.

Has anyone bumped into this problem?
Is there any solution?

P.S.
Do the following Excel functions work in the formula definition window:
Search - finds a character within a string
Mid - extracts a part of a string, based on the starting position and number of characters.

Anhänge (3)

Typ: image/png
60-mal heruntergeladen
Größe: 152,68 KiB
Typ: image/png
51-mal heruntergeladen
Größe: 149,22 KiB
Typ: image/png
42-mal heruntergeladen
Größe: 10,35 KiB

Lösung anzeigen Lösung verbergen

Hello,

I don't know if this function is available, but maybe you can try TRIM().
This removes the space characters before and after the text.


Hi Lukacsicsaba,

Look like you're fully right! i just try on a version 2022 and also get the same result. You can't concatenate different value with the Layoutname. It always display the full length even with a vbs script, we got len(layname)=70.

As you mention MID() can work if you know where to stop, maybe a special characters could help to have a stop for the search.

On the other hand, it's working well with the drawing file name (@425@), it's only an issue in the layout module.

I don't think we have a solution for that. Will try to send an information to the development.

Bye

Mr Judy GURAVADU
Responsable Technique Préfabrication & Ingénierie
Precast Sales & Support

Allplan France & Allplan Software Engineering

Depuis 2006

Thanks for the quick answer.

I had the idea with the special character at the end of the layout name, for using the MID() function.
The only issue is that i don't know (yet) how to find the place of this special character within the layout's name.
In Excel you can use the Search function for this, but i did not find the corresponding function in Allplan.
Is there such a funtion?

Thank you in advance.

Csaba

Hello,

I don't know if this function is available, but maybe you can try TRIM().
This removes the space characters before and after the text.


Hello Bertrand,

Thank you for the suggestion, it works like a charm.
It was exTRIM()ly usefull (pun intended).

Have a great one.

Csaba


Thank you for the feedback.
Have a good day.