I have a Table that is a Menu and several of the options will be opening an html file.
Menu is in the view vHome and the html viewer is in the viewHTML.
I tried creating a property in mtFile as Text in viewHTML then the load url is: HTMLAbout.LoadURL(mtFile).
Then tried the other way around creating the property in vHome and the the load url is: HTMLAbout.LoadURL(vHome.mtFile)
Both cases the compile says it doesn’t exist. Doesn’t this work the same as Desktop?
Looking at the Notes example I tried the following:
Made mtFile a computed property.
It created a private Propety mmtFile
Get: return mmtFile
Set: mmtFile = value
Then HTMLAbout.LoadURL(mtFile) in open event.
I set break point and mtFile is “”
Figured out the the Open event is called before the the mtFile assignment.
Put it in the Activate and then it worked.
If I have a view that requires some parameters, as is the case with your example, I find it simple to create a Constructor method and pass the parameters in that way, e.g.:
dim hv as new HTMLView(htmlFile)
If I need something back from the view, I also pass in a pointer to a call-back method along with the parameter(s) and deal with it in the parent (calling) view.