Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations GregLocock on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

RSView-hosted VBA app error

Status
Not open for further replies.

johnhines2

Computer
Jan 18, 2011
1
I recently "inherited" support for a VBA application hosted within RSView. We have a test-stand that is used to various tests on industrial pumps. The VBA application having the issue runs a priming test but when you access the screen to start, a VB-type error message is presented saying "Object library invalid or contains references to Object definitions that could not be found."

Being a long time VB, VB.NET, C, C# programmer I know the things that normally cause this error but I have not been able to track this down in the VBA code in this case. When the error occurs, the line highlighted in the VBA editor is a declaration using the TAG UDT (Dim TAG_PLC(100) as TAG). If you get past this, declarations using the TagGroup UDT also trigger the error. Normal VB datatypes (integer, string, etc.) do not.

I've tried some suggested resolutions such as deleting EXD files so they can be dynamically re-created/registered but that also had no impact on the error. I've checked library references and spent a lot of time trying different versions of certain libraries (especially ActiveX since this application uses a lot of ActiveX controls) but again no impact on the error. I saw a forum post once about single-element array declarations being a problem, so I tried that recommendation of setting up a variable with the value of the array elements and using that instead of a literal to specify the size of the array, but again no impact on the error.

It appears there must be something more specific to this flavor of VBA hosted under RSView that I'm not seeing. Unfortunately, I am not very familiar with RSView or VBA elements that are more specific to it in VBA applications written for it and I think that is where my "disconnect" is.

As this error seems to implicate RSView UDT's (User-defined Datatypes) like TAG and TagGroup, I'm wondering if anyone has run across this kind of error? What library reference in the VBA code is most likely associated with this error, keeping in mind that when the error is thrown it stops on the first line of code that declares something using the TAG UDT?

See attachment. This is the error thrown immediately when the Priming test is selected.

J. Hines
Programmer/Analyst,
Gorman Rupp Company
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor