Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. COM
  4. Accessing ActiveX Ambient properties?

Accessing ActiveX Ambient properties?

Scheduled Pinned Locked Moved COM
comcsharpgraphicsdockerhelp
3 Posts 2 Posters 19 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • D Offline
    D Offline
    dequadin
    wrote on last edited by
    #1

    Sorry for the double post, but I didn't get any love on the C# forum, thought I'd try my luck here. Please could someone point me in the right direction. I've written an ActiveX control in C# and it's working well except for one "small" problem. I'm trying to access the ambient properties of the ActiveX container and am drawing blank. I'm trying to replicate the following VB 6.0 functionality in C#: Ambient Properties:

    ActiveXAmbientMode = UserControl.Ambient.UserMode

    Ambient Properties changed event:

    Private Sub UserControl_AmbientChanged(PropertyName As String)
    If PropertyName = "UserMode" Then
    ' Do Stuff Here
    End If
    End Sub

    From what I can find out so far is that this "might" have something do to with implimenting the IOLEControl COM interface? But I can find NO examples of this ever being done? Anyone ever managed to get this working because I can't find any useful info on this anywhere?

    D 1 Reply Last reply
    0
    • D dequadin

      Sorry for the double post, but I didn't get any love on the C# forum, thought I'd try my luck here. Please could someone point me in the right direction. I've written an ActiveX control in C# and it's working well except for one "small" problem. I'm trying to access the ambient properties of the ActiveX container and am drawing blank. I'm trying to replicate the following VB 6.0 functionality in C#: Ambient Properties:

      ActiveXAmbientMode = UserControl.Ambient.UserMode

      Ambient Properties changed event:

      Private Sub UserControl_AmbientChanged(PropertyName As String)
      If PropertyName = "UserMode" Then
      ' Do Stuff Here
      End If
      End Sub

      From what I can find out so far is that this "might" have something do to with implimenting the IOLEControl COM interface? But I can find NO examples of this ever being done? Anyone ever managed to get this working because I can't find any useful info on this anywhere?

      D Offline
      D Offline
      dequadin
      wrote on last edited by
      #2

      BUMP for any feedback? Does anyone know if this is even possible? This has nothing to do with UserControl.Site.DesignMode, because that doesn't get exposed to COM. So will always return FALSE when the ActiveX is used in an application. I'm looking for the COM interface implimentation of how a VB 6.0 ActiveX interacts with it's container....

      R 1 Reply Last reply
      0
      • D dequadin

        BUMP for any feedback? Does anyone know if this is even possible? This has nothing to do with UserControl.Site.DesignMode, because that doesn't get exposed to COM. So will always return FALSE when the ActiveX is used in an application. I'm looking for the COM interface implimentation of how a VB 6.0 ActiveX interacts with it's container....

        R Offline
        R Offline
        rdunnill
        wrote on last edited by
        #3

        Did you ever get an answer on this?

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups