2021-12-08 06:25 PM
Archicad appears to be using XML for a number of exportables. My current interest is the Project Info file which also doubles as a handy store for Autotexts. What is the recommended way to edit / format these files outside of AC? I would like to open the file and add a number of Autotext values that can then be imported back into AC. Is this an acceptable exercise or is editing the file a no-go area?
Solved! Go to Solution.
2021-12-09 09:39 AM
I used to heavily modify android framework xml files to alter look and feel on my phone, I bet you can use notepad or equivalent, or anything that opens and resaves xml files.
2021-12-09 09:50 AM
Thanks, I can open with text edit, but the bit that troubles me is the lines of code that contain unique ID references, which I assume have to be generated by AC...
2021-12-09 01:25 PM
The project info XML has two big ubernodes:
<FixKeys> and <CustomKeys>. Both have an attribute called "val" set to a number.
Don't touch the <FixKeys> node and its contents. In the <CustomKeys> you can add as many new nodes as you like, but keep them ordered, as their names have a counter in it. Don't forget to set the "val" attribute in the end to the right number.
One custom node looks like:
<Custom1> <UIKey> <![CDATA[Eigentümer]]> </UIKey> <DBKey> <![CDATA[autotext-SITE-0A3DEF04-F614-574B-A59F-847C7B4393D9]]> </DBKey> <value> <![CDATA[<####>]]> </value> </Custom1>
XML is sometimes a bit allergic to empty nodes (some software would truncate it to a selfclosing tag, eg.g. <mynode />), thats why empty nodes do have some text in them. In the example above its "<####>".
Interesting here is the <DBKey>, which is the reference to the actual content used inside of Archicad. Also that's exactly what you can put in a GDL object. You would write
text2 0, 0, "<autotext-SITE-63A43EA8-A776-455F-9DB1-746EE27D085D>"
If you want to manually create new items:
The preamble of "autotext" seems to be needed, as well as the category of the block of the project info, here "SITE", always allcaps.
The last part is just a plain GUID. You can totally make up one!
Either you copy it from a webservice out there, or you use the function inside your favorite editor.
2021-12-09 05:14 PM
@runxel Thanks the GUID worried me, now I understand them a lot better.