Help with WebContainer array not showing

Hello all.

I created a web container that has a WebImageView, a WebLabel and a Separator.
I created a Property in a form RemStat() As cntRemoteStatus

In the open event of a page I added this code:
RemStat.Append(New cntRemoteStatus)

RemStat(0).Left = 500
RemStat(0).top = 50
RemStat(0).Visible = True

The problem is, the container never appears on the form.

Can anyone please suggest what I did wrong and how to fix?


Hi Michel,

Thank you for your response! I see your name a lot in this forum - much appreciate your help.

Two stupid general questions:

  1. How did you know to do this?
  2. Why is this even necessary? Is it simply due to the WebContainer object restraints itself?

I had seen a similar response in an earlier post, but did not see the need when all of the properties already exist in the WbContainer object.

Again, thank you for your help, and helping others in this really cool forum!

I learned a lot from others, and also from carefully reading the LR.

As for the reason why you need embedwithin, it is because as long as you do not actually instanciate the webcontainer on the page, it remains just as a virtual blueprint.

The same is necessary for webPages when they don’t have implicit instance. I can do for instance

dim w as new WebPage

That won’t display it.
You need to use Show to actually display it.

When Implicit Instance is on (which is the default), you simply go show, and the previous step is taken care of.

WebContainers don’t have that.

Thanks again Michel