Announcements
Attention for Customers without Multi-Factor Authentication or Single Sign-On - OTP Verification rolls out April 2025. Read all about it here.

CoordinationModelDB.pdb not loaded

Anonymous

CoordinationModelDB.pdb not loaded

Anonymous
Not applicable

Hey !
A'm new in Revit API and in C#.

 

I'm trying to  open Revit Model from MS Visual Studio :

 

UIApplication uiapp = commandData.Application;
UIDocument uidoc = uiapp.OpenAndActivateDocument(@"C:\Users\PSPOD\Desktop\models\PM1.rvt");
Autodesk.Revit.ApplicationServices.Application app = uiapp.Application;
Document doc = uidoc.Document;

 When i launch it , i got an Exception:

System.NullReferenceException" in CoordinationModelDB.dll

 How to fix it ?

0 Likes
Reply
637 Views
3 Replies
Replies (3)

jeremytammik
Autodesk
Autodesk

Welcome to the Revit API!

  

I have never heard of this problem.

  

You may be doing something fundamentally wrong.

  

To get started with the Revit API, I suggest that you first of all take a look at the getting started material and work through the step-by-step instructions provided by the DevTV and My First Revit Plugin video tutorials:

  

http://thebuildingcoder.typepad.com/blog/about-the-author.html#2

  

That will explain all you need, including the answer to your question.

  

For a quick start, you can also check out the hello world examples in the developer guide:

  

http://help.autodesk.com/view/RVT/2018/ENU/?guid=Revit_API_Revit_API_Developers_Guide_Introduction_G...

  



Jeremy Tammik
Developer Technical Services
Autodesk Developer Network, ADN Open
The Building Coder

Anonymous
Not applicable

Great thak you !

0 Likes

Anonymous
Not applicable

Hello @Anonymous  ,

 

I just had the same error. For a unknown reason, Visual Studio didn't load all modules.

 

If you are a curious being like myself, you can learn more the problem about this here :

https://stackoverflow.com/questions/24761938/breakpoints-not-hit-no-symbols-loaded

and then here :

https://stackoverflow.com/questions/12891167/visual-studio-is-not-loading-modules-when-attaching-to-process

 

If you just want to fix it - that's pretty fine too - you need to follow the steps to reload them :

 

"Finally I found the answer in this post. I took a look into the loaded modules (Debug->Windows->Modules while having assembly attached to process) and noticed that my actual assembly wasn´t in the list. The code I wanted to debug is built with .NET 3.5 but modules have only been loaded for .NET 4.0. Usually this might be detected automatically as far as I am concerned but however this time automatic detection did not work for some weird reason so I changed selected code type from managed (v4.0) to managed (v2.0) and now it works. Hope this won´t occur when I have to debug on .NET 4.0 later again..." by HimBromBeere 

 

Or in detail :

https://stackoverflow.com/questions/2155930/how-do-i-remedy-the-breakpoint-will-not-currently-be-hit-no-symbols-have-been?rq=1


I hope that this will be helpful,

Have a great day !

0 Likes