i am faced once again with the excel-dynamo import phase problem. I keep getting the error which states: The object reference has not been set to an object istance. Please does anyone have an idea of how to solve this issue without using the file Path node which always crashing revit/dynamo entirely when used. Thanks
Hi Vijay, thanks alot for the swift response. The Problem is that the node file path does not work with me because it crashes my revit and respectively dynamo when i connect it or even click search. that was why the openxml was the only option that has succesfully worked while i did the export. So the thing is that i need a work around to get the file from the saved location without using the file path node. thanks lot
import clr
import System
from System.IO import FileInfo
import DSOffice
# Take path string from Dynamo input
path = IN[0]
# Convert to FileInfo object
fileInfo = FileInfo(path)
# Import Excel
data = DSOffice.Data.ImportExcel(fileInfo, "Sheet1", False, True)
# Output to Dynamo
OUT = data
Thank you so much @Mike.Buttery by just escaping the back-slashes solved the problem so fast. This forum is simply the best so far. Thanks you Sir for the support.
Hello hayet, i believe this solution was directed to me however, i had solved it using the suggestion from Mike.butterfly. Thanks for your help as well.