66

I've got a new question after answer on this question Pass parameter from page to ActiveX

How to add property to property map without class explorer?

Need to add the property for object and class explorer doesn't work because Nemerle doesn't support it yet.

Code:

<object id="DBTableRepX"
 classid="CLSID:CA8B72B3-3B15-40D7-9364-478E25AF5B41"
 codebase="DBTableRepX.cab"
    style="
    Z-INDEX: 102; LEFT: 20px; WIDTH: 1200px; 
    POSITION: absolute; TOP: 80px; HEIGHT: 600px">
    <param name="ax_Command" value='<%=GetText()%>'/>
</object>
Community
  • 1
  • 1
cnd
  • 29,085
  • 60
  • 169
  • 294
  • Is your GetText() method marked as public? – CheckRaise Oct 05 '11 at 16:07
  • @CheckRaise I can't be sure it was on May 2010, but I hope so. – cnd Oct 05 '11 at 19:01
  • 8
    I didn't even check the date of the post but I find it interesting that it's the top question on the unanswered tab. Assumed it was a recent post :p – CheckRaise Oct 10 '11 at 20:04
  • 1
    So I still remember there was some ActiveX and I need to transfer property there but it's more Nemerle and property map related question. – cnd Oct 11 '11 at 04:18

1 Answers1

5

Why not derive you own ActiveX class from the one you are using and add the property to the derived class?

Or make a wrapper class and use that.

PhilW
  • 400
  • 3
  • 11
  • I'm not sure that I can have a sources of the ActiveX... Can I still do it? – cnd Jan 23 '12 at 11:31
  • yes, you can. Souce code is not needed for a wrapper class nor deriving from it. Your own class will need to be an ActiveX control in it own right. Not elegant and a bit clunky, though possible. – PhilW Jan 23 '12 at 16:24
  • But I still not fully understand the idea. You say "add the property to the derived class" but there is the same trouble, no class explorer there. – cnd Jan 24 '12 at 04:51
  • Add the property to source code for the derived class, as you would do for any class that you define. – PhilW Jan 24 '12 at 09:46
  • @nCdy Where are you defining GetText? – PhilW Jan 24 '12 at 09:47
  • I don't remember about GetText, it was two years ago after all. I'm not sure if it is possible to add property to property map in source, I remember I still can't find solution for it. – cnd Jan 24 '12 at 10:29
  • 1
    What I am suggesting is to create your own ActiveX control as a new project and implement the functionality using the Bacs_DBTableRepX class as base or a class member. – PhilW Jan 25 '12 at 09:12