I created my form with a listview box as you can see to the right, however I came across a problem when trying to access the Application within the code.
So far I have used the following to reference the application:
Public Function Execute(ByVal commandData As ExternalCommandData............
Dim uiapp As UIApplication = commandData.Application
However in the form code there is no commandData, so I had to change the definition of the uiapp to a Shared item.
Public Class AdskCommand
Implements IExternalCommand
Public Shared uiapp As UIApplication
Public Function
Execute(ByVal commandData As ExternalCommandData,........
uiapp
= commandData.ApplicationThis allows me to reference the uiapp in the Execute function when the command starts and also with this code:
Private Sub lstWorkSets_Click(sender As Object, e As System.EventArgs) Handles lstWorkSets.Click
Dim uidoc As UIDocument = AdskCommand.uiapp.ActiveUIDocument
Thank you Sir, you're iDeas are excellent. i am learning Revit API, being a beginner your tutorials are Excellent.
ReplyDeleteIs this Application .ddl is available for download.
ReplyDeleteNot at present, sorry
ReplyDeleteHi, Nice description about Revit API vb.Net.Thanks, its really helped me......
ReplyDelete-Aparna
Theosoft
me too i really like it... and going through step by step.... i hope you keep posting on your blog :)
ReplyDelete-Moustafa
GAJ