Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

AddOn constructor question

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    AddOn constructor question

    I tried putting a do-nothing constructor in my AddOn, and it appears to prevent the AddOn from running. What's up with that?
    Code:
            VsaMenu() : base()
            {
            }
    Other questions, related to multiple cooperating AddOns:
    • Is there any way to control the order AddOns are created?
    • Is it guaranteed that all AddOns will be constructed before any other calls are made to any AddOn?
    • I have an AddOn that needs to set a static pointer to itself so that related AddOns can call it. The pointer needs to be set before any of the related AddOns has its OnWindowCreated() method called. When should it set that pointer?
    • Is there a better way for cooperating AddOns to find the first AddOn's instance so they can call it?
    • Do separate AddOns run in separate threads? If I have AddOns calling each other, does the code need to be threadsafe?

    The basic question is how multiple AddOns can cooperate. In my case I presently have two AddOns that depend on a third AddOn. They need it to be operational before they make calls on it. I'd rather stay with whatever NT support there is, but if there is no adequate support I can work around that. I just need to know.

    --EV
    Last edited by ETFVoyageur; 08-16-2015, 07:58 PM.

    #2
    Hello ETFVoyageur,

    Thank you for your patience.

    We will review these items and follow up with information.

    Comment


      #3
      Hello PatrickH,

      something new ? It will be very instructive to read the answers.

      Thanks.

      Comment


        #4
        Addons do not have a dependable start sequence. However to solve your scenario I would suggest you look into the 'Singleton' c# pattern.

        This will allow you to make sure that any 'critical' resources are created on the first call to that resource. This way the start order does not matter.

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by bortz, 11-06-2023, 08:04 AM
        47 responses
        1,610 views
        0 likes
        Last Post aligator  
        Started by jaybedreamin, Today, 05:56 PM
        0 responses
        9 views
        0 likes
        Last Post jaybedreamin  
        Started by DJ888, 04-16-2024, 06:09 PM
        6 responses
        19 views
        0 likes
        Last Post DJ888
        by DJ888
         
        Started by Jon17, Today, 04:33 PM
        0 responses
        6 views
        0 likes
        Last Post Jon17
        by Jon17
         
        Started by Javierw.ok, Today, 04:12 PM
        0 responses
        22 views
        0 likes
        Last Post Javierw.ok  
        Working...
        X