I am trying to use the following command for dynamically control the properties by using Femap 10.0.2
App.feEntityVisibility (FVIS_PROP, p2set.ID, False, True)
Observing the following error in Femap
Basic Error (Line 32, Offset 0): (10091) ActiveX Automation: no such property or method
is this Activex supported in Femap 10.0.2, any alternative to use this
Solved! Go to Solution.
It appears that method was added in FEMAP 10.1.0, next version after 10.0.2.
You could use Groups instead. Ex:
Sub Main Dim App As femap.model Set App = feFemap() Dim p2set As Set Dim g As Group Dim v As View, viewID As Long Set p2set = App.feSet Set g = App.feGroup Set v = App.feView App.feAppGetActiveView(viewID) v.Get(viewID) p2set.AddRange(1,2,1) gID = g.NextEmptyID() g.SetAdd(FT_PROP,p2set.ID) g.title = "Properties_API" g.Put(gID) g.Active = gID v.Group = gID v.Put(viewID) End Sub
Open the API pane within FEMAP, then paste or type the lines of the program above. When you click the green "Play" button the program will run.
Additionally, you can copy the lines above, paste into a text file, then change the extension to ".bas". Now, you can place the file in your Custom Tools folder or User Tools folder and run the program with one click from the icons within FEMAP!