Revit API Forum
Welcome to Autodesk’s Revit API Forums. Share your knowledge, ask questions, and explore popular Revit API topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Approach for implementing TableView with multiple sections

2 REPLIES 2
SOLVED
Reply
Message 1 of 3
rickSFEYK
220 Views, 2 Replies

Approach for implementing TableView with multiple sections

I'd like to create a view in Revit that displays a table of custom data with multiple sections. Some data in the table will be taken from Revit elements or external databases and some data will be calculated via formula. The user will be able to edit cells in the table to update the values in Revit elements or external databases. Revit provides the base TableView class, but it appears creating a new TableView is inaccessible from the Revit API. A ViewSchedule (which is derived from TableView) can be created, but it only supports a single section (e.g. header & body). A PanelScheduleView can also be created, but it is specialized for electrical panels.

 

So it seems there is no way to display generic tabular data with multiple sections in a Revit view. Is this true? Have I missed something in the API?

 

As an alternative, I could implement all this functionality and display generic tabular data in .NET's DataGridView, which could then be embedded in a WinForm or a Revit panel. However, then the data would not be displayed in a Revit View. I would like to display the data in a View to inherit all the other nice functionality Revit Views have (panelization, printing, etc.).

Have folks implemented something like this in the past? What has been the approach?

2 REPLIES 2
Message 2 of 3
jeremy_tammik
in reply to: rickSFEYK

The Revit API is basically a wrapper around the manual end-user functionality. Therefore, when asking how to achieve a certain functionality, it is mostly more efficient to begin by researching the optimal UI approach and best practices. I suggest you do so before even starting to think about an API approach.

    

That said, I do know that some people have implemented their own pseudo-tables by simulating a table using just text and line elements, cf.:

  

https://forums.autodesk.com/t5/revit-api-forum/what-is-the-best-way-to-create-a-custom-schedule-tabl...

  

This fact would seem to indicate that some requirements are not easy (or possible) to fulfil using the native Revit tables.

  

Jeremy Tammik Developer Advocacy and Support + The Building Coder + Autodesk Developer Network + ADN Open
Message 3 of 3
rickSFEYK
in reply to: jeremy_tammik

Hello Jeremy,

Thank you for your quick reply and the link regarding pseudo-tables, which I had not come across before in my searching. The conclusion I draw is any sort of reasonably complex table / spreadsheet functionality will need to be implemented external to the Revit API as the ViewSchedule class is limited in features and manually creating pseudo-tables appears best for simple tabular data and burdensome for complex data display and user interaction.

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

Post to forums  

Rail Community


Autodesk Design & Make Report