Results 1 to 4 of 4

Thread: How to handle Unresolved References dialog

  1. #1
    Member
    Join Date
    2016-06
    Posts
    5
    Login to Give a bone
    0

    Default How to handle Unresolved References dialog

    Hello!

    How can I automatically ignore unresolved references when opening a project file?
    I tried using the DialogBoxShowing event which triggered but I wasn't able to close this dialog.
    e.OverrideResult(result) does not work with any result.

    Unresolved references.png

  2. #2
    100 Club
    Join Date
    2004-09
    Posts
    104
    Login to Give a bone
    0

    Default Re: How to handle Unresolved References dialog

    Here is how I do this one:

    Code:
    		public void Project_DialogBoxShowing(Object sender, DialogBoxShowingEventArgs args)
    		{
    			TaskDialogShowingEventArgs args2 = args as TaskDialogShowingEventArgs;
    			if (null != args2)
    			{
    				string s = args2.DialogId;
    				//MessageBox.Show("Dialog ID is:  " + s);
    				if (args2.DialogId == "TaskDialog_Audit_Warning")
    				{
    					args.OverrideResult((int)TaskDialogResult.Yes);
    				}
    				if (args2.DialogId == "TaskDialog_Unresolved_References")
    				{
    					// Buttons with custom text have custom IDs with incremental values
    					// starting at 1001 for the left-most or top-most button in a task dialog. 
    					// "Open Manage Links to correct the problem", "1001"
    					//args2.OverrideResult(1001);
    					// "Ignore and continue opening the project", "1002"
    					args2.OverrideResult(1002);
    				}
    
    
    			}
    		}

  3. #3
    Member
    Join Date
    2016-06
    Posts
    5
    Login to Give a bone
    0

    Default Re: How to handle Unresolved References dialog

    It worked perfectly, I didn't use TaskDialogShowingArgs.
    Thank you for the quick reply.

  4. #4
    Woo! Hoo! my 1st post
    Join Date
    2012-01
    Posts
    1
    Login to Give a bone
    0

    Default Re: How to handle Unresolved References dialog

    peterjegan, I tried this code but received this error in Visual Studio: 'DialogBoxShowingEventsArgs' is inaccessible due to its protection level

    Any help is greatly appreciated!

    Thanks.

Similar Threads

  1. File keeps throwing up Unresolved References error
    By patricks in forum Revit Architecture - General
    Replies: 2
    Last Post: 2010-09-02, 05:51 PM
  2. Unresolved Xref
    By asmckee in forum AutoCAD General
    Replies: 3
    Last Post: 2010-03-19, 06:52 AM
  3. xref unresolved
    By crbickel in forum ACA General
    Replies: 5
    Last Post: 2007-03-28, 12:12 AM
  4. Unresolved References.
    By amey in forum Inventor - General
    Replies: 2
    Last Post: 2006-03-16, 11:35 AM
  5. Unresolved Xref
    By Shizzjr in forum AutoCAD General
    Replies: 7
    Last Post: 2005-12-19, 05:17 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •