OpenSTAAD Objects for VBA (Do Not Seem To Work)?

Hi there,

I'm just learning how to use the OpenSTAAD and I just encountered something that seems not working. I tried adding the OpenSTAAD Library to Object Browser and it displays Output. It seems to me that some of the objects therein are not working. I tried using "Output.ObjectName" and "Geometry.ObjectName" but they don't seem to work. I am puzzled because they are all found under "Output" but I cannot use them this way. I also tried "Property.ObjectName".

Or I might be doing it incorrectly? Here's an example: "objSTAADMembForces.Output.GetNumberOfEntitiesInGROUP"

The error (debug) message I am getting is: "Object does not support property or method".

I'm attaching the screenshot of my Objects Browser.

Please help. Thank you.




  • This particular function is not available in the application object function library. So program is unable to identify the function and there is an error message. Can you mention which version of STAAD.Pro you are using?

    You can check the available OpenSTAAD functions in the following document --
    Help > Contents > OpenSTAAD Documentation > OpenSTAAD Functions

    Also you can mention about your requirement (what value you want to extract using this function) so that I can help you to find an equivalent function for this.



  • Thank you Suro. In the output it says: "Version 2007 Build 04". STAAD.Pro v8i Release 20.07.04.12

    If function is not available, why is it displayed? It is really confusing. I am trying to get the number of beams/nodes in certain groups that I created in the model.
  • Further, I noticed that the functions found in the screenshot above are different from those that are found in the OpenSTAAD Documentation...

    Here...

  • You are using a very old version of STAAD.Pro. Results object functions are used in this version which are now obsolete. All the results object functions has been replaced with the application object functions. Also the Help manual has been updated and misinformation related to the latest functions are available. We recommend to use the latest version of the software (STAAD.Pro SS6, build 20.07.11.50) and check the issue in this version.



  • Hi Suro,

    It's been a year... I am just studying this on my spare time and just recently, I had the opportunity to get back to this.

    Your answer helped in understanding this - that I am using an old version and so those functions are unavailable. However, when I reverted to using Results Object Function, it also doesn't seem to work. For example, if I use "Output.GetMaxBendingMoment", I'm getting a "Runtime Error 438 - Object doesn't support this property or method" Which I think means that the version I'm using does not support such a function.

    Correct me if I'm wrong but my understanding is, whatever version I am using, I should be able to use whatever function is available to that version.

    Another thing which I find odd is, most of the functions I see in the objects browser are not recognised whenever I run them. But some of the functions from the documentation works for me even if I don't see them on the objects browser (I find these functions in the documentation under the Application Object Function. Your statement above seems to imply that my version is affected by such replacement you mentioned).

    I don't know what am I missing here. Please help. It's really frustrating to work alone on this. :(

    Thank you