Announcements
Welcome to the Revit Ideas Board! Before posting, please read the helpful tips here. Thank you for your Ideas!
Announcements
We are currently migrating data within this board to improve the community. During this process, posting, replying, editing and other features are temporarily disabled. We sincerely apologize for any inconvenience caused and appreciate your understanding. Thank you for your patience and support.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

ShowElements, additional parameters, return value

ShowElements, additional parameters, return value

Please improve the ShowElements methods.

 

As you can see, we just can handle over some element IDs...

 

Overloads.png

If the elements are not visible in any view, we get this dialog which needs user interaction to be closed:

 

NoGoodView.png

 

Why not giving that as (boolean) return value of ShowElements?

Also, there may be several views suitable for displaying the elements.

Why not providing a parameter for desired view ID?

If we want to display an element in a view plan but Revit decides to use a 3D view, that's not optimal.

Also, it may be the case that if you want to show a chair inside the building, in the chosen 3D view you only see the outer side of a wall, hiding the chair.

Revit decides which view to use, but its decisions are not always the best ones.

 

I suggest something like this:

 

bool ShowElements(ICollection<ElementId> ids, ElementId desiredViewId)

 

Returns "true" if elements could be displayed properly, otherwise "false".

As default, the "No good view" dialog is suppressed.

Depending on the result value, we can inform the user ourselves that there is no good view.

A "false" result could be used to try the method using another view ID.

The list of candidate view IDs needs to be priorized by the programmer, using view names, parameters, scales as criteria, whatever he (or she) wants.

 

Revitalizer

Can't find what you're looking for? Ask the community or share your knowledge.

Submit Idea  

Autodesk Design & Make Report