First of all please post code not an image of code. This forum supports code formatting very well.
Here’s how:
To get the basic file info you actually have to extract it from a file. There is a static method for that where you feed the file path of the document that you need the info about. In this case its your current open document since you are in Dynamo. To do that just call doc.PathName and then you are good to go.
you were also missing references to things like Revit API and Revit Services which are wrapper classes for Document object for working with Revit docuements in Dynamo.
Here’s a full code:
# Import RevitAPI
import clr
clr.AddReference("RevitAPI")
import Autodesk
from Autodesk.Revit.DB import *
# Import DocumentManager and TransactionManager
clr.AddReference("RevitServices")
import RevitServices
from RevitServices.Persistence import DocumentManager
doc = DocumentManager.Instance.CurrentDBDocument
#The inputs to this node will be stored as a list in the IN variables.
dataEnteringNode = IN
#Assign your output to the OUT variable.
OUT = BasicFileInfo.Extract(doc.PathName).CentralPath
Curious if I can pick your brain for a technique to query the central file locations of linked models in our Revit base file. I am not interested in the saved file location under the manage links tab, but rather the deep seated central location the files looks to sync to.
Just a bit of background, improperly linked files (files that are copy pasted, and not e transmitted) cause performance issues that are tricky to troubleshoot. In a model with 40 links, it can be difficult to identify which ones have been disassociated from a consultants server.
You probably want to start a new thread. This is a pretty old question and it’s hard to expect someone to answer a new question while this one already has an answer.