cancel
Showing results for 
Search instead for 
Did you mean: 

Menu Event - can't access object

Former Member
0 Kudos

Hi,

I can't access the object for the menu event using SBO 6.5.

If I try to read a property, e.g. MenuUID, I get the error message "Invalid Variant Operation".

I'm using Delphi and the parameter "pval" is defined as OleVariant.

On the other side, I can access the object for the ItemEvent without any problems.

Does anyone have an idea how to solve the problem?

Obviously it seems to work fine with VB.

Thanks,

Gerold

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi Gerold,

I had the same problems, Delphi works fine with the DI SDK, but it doesn't work well with the UI SDK - not well at all! As you already know, you can't access the pVal parameter object in item events, and you will also find that there are lots of properties which are read-only in Delphi - properties you need to set if using the UI.

I switched to C#, as it handles both the UI and DI and only use Delphi for DI requirements like data integration. This is probably not very comforting news for you.

Former Member
0 Kudos

Hi Lita,

Thanks for your reply.

I CAN access the pval parameter object in Item Events but CANNOT the parameter in Menu Events.

I suppose the problem with the pval object in the menu event is caused by name collisions with the Delphi VCL.

So far I had no problems with read-only properties in Delphi. Maybe because I started only a few weeks ago.

Using two languages means two applications (add-ons) that you have to register. That's no fun at all.

Regards,

Gerold