0 Members and 1 Guest are viewing this topic.
RenderMan, looks like your running into the same problem I had with the property sets and AutoCAD API causing exceptions instead of returning results.
Why not use the .NET API System.IO.Directory or System.IO.File classes?
Quote from: MexicanCustard on September 25, 2012, 12:48:49 PMRenderMan, looks like your running into the same problem I had with the property sets and AutoCAD API causing exceptions instead of returning results.As it happens, I wrote much of the OP in my last response to you in that thread, then felt that it would detract from your original topic (while loosely related), so I started a separate thread, given the Method specificity.Quote from: MexicanCustard on September 25, 2012, 12:48:49 PMWhy not use the .NET API System.IO.Directory or System.IO.File classes?I'm searching the Support File Search Paths (SFSP) for a given Document.Does System.IO offer such functionality for AutoCAD's SFSP, or would I have to parse, then iterate each path in SFSP + Application.GetSystemVariable("DWGPREFIX"), etc.?
I'm searching the Support File Search Paths (SFSP) for a given Document.Does System.IO offer such functionality for AutoCAD's SFSP, or would I have to parse, then iterate each path in SFSP + Application.GetSystemVariable("DWGPREFIX"), etc.?
QuoteI'm searching the Support File Search Paths (SFSP) for a given Document.Does System.IO offer such functionality for AutoCAD's SFSP, or would I have to parse, then iterate each path in SFSP + Application.GetSystemVariable("DWGPREFIX"), etc.?No, you would have to get the paths from AutoCAD and then retrieve all the filenames with System.IO.Directory. It would add a couple of extra steps but it would avoid exception trapping if that bothers you.