Project Base Point at Startup Location?

Hi all,

For a few months i have done a lot of reading on this forum, and already learned a lot.
So thanks to all contributors, for sharing their valuable time.
But now i a have a question, of witch i can’t seem to find the answer on this forum.
Is it possible to find out if the Project Base Point is at the Startup Location (or is moved)?

Thanks in advance,
Mark

hello @MJB-online!

That can actually be done with one node!

Hi Einar Raknes,

Thank you very much!
I’m going to play with this node one on some sample files.
If i receive a Third party file, i’d like to know in advance if someone messed with the basepoint :wink:.

Mark

Hi Einar Raknes,

The above method works perfectly on the current projectfile :slight_smile:.

I know it’s a lot to ask, but could it also be done by a Python node on a directory of files.
I’m thinking of a workflow like the picture below. Instead of the Revit version the Python script should get the same info as the Coordinates.BasePoint node above.


Also many thanks to @T_Pover for providing the above python script, witch can be found here:
https://forum.dynamobim.com/t/get-revit-version-while-loading-family/10211/3?u=mjb-online

I hope someone can help me with this.

Mark

So you’d want something like John Pierson’s Document.BackgroundOpen node from Rhythm package:

The Coordinates.BasePoint node only works on the current (active) document, but you could make a Python (or C#?) node to extract the coordinates from the project base point in a given document. This is the C# code for the built-in node:


Looks complex, but the work happens in just a few lines in GetBaseOrSurveyPoint.

1 Like

Hi David,

Thanks for your suggestion.
The Coordinates.BasePoint node does indeed only works on the current document, and that is why i would prefer a Python script that checks a list/directory of files.
Converting C# code to Python is beyond my knowledge :disappointed:, so i hope someone else can help me.

Mark

Hi Erik,

Thank you very much.
I can’t test the above code at this moment, but i am very sure it is the solution for my problem.

With kind regards,
Mark

Hi MJB,

This is possibly a silly question but are ‘Application.OpenDocumentFile’ and ‘Document.BackgroundOpen’ functionally the same?

Seems ‘Document.BackgroundOpen’ has been replaced by ‘Application.OpenDocumentFile’?

Thanks

Hi @jaclyn.s,

I think you’re right.
Document.BackgroundOpen and Document.Close are the old versions (Python code).
And Application.OpenDocumentFile and Application.CloseDocument are new versions (C# code for better performance). But to be sure maybe @john_pierson can shed a light on this :grinning:.

Kind regards,
Mark

2 Likes

Yep, those are the new ones! :slight_smile: