Call a WebPage Public Method fromA Container

  1. 2 months ago

    Hi,
    could someone please clarify how to reference to page which has implicit instance off?

    For example from mainwebpage I declare

    Dim instancePage as New MyWebPage
    InstancePage.Show
    InstancePage.APublicMethodOnMyWebPage

    Then lets suppose that within APublicMethodOnMyWebPage I try to call a container
    self.myContainer.visible= True

    Which is ok...

    But, if there is a button to the container that tries to call a method APublicMethodOnMyWebPage in the instance of MyWebPage (InstancePage) how to call it ? The self.Page.APublicMethodOnMyWebPage fails..
    Trying
    Dim w as InstancePAge = InstancePage(self.page)
    w.APublicMethodOnMyWebPage
    also fails...
    AnyHelp

    Until now, in my app all pages are loaded at once when the app starts.
    I try to make it lighter but this way, that is,to put implicit instance OO tomost webpages and then to created them when I need them.

    Thanks in advance

  2. Thanks, I think I made it.

    In the container I set again

    dim anotheInstance as new myWebPage
    anotheInstance.MyMethodCalledFromAContainer

or Sign Up to reply!