Hi,
I tried to use the XamWebHtmlViewer control to replace an open-source alternative but it wouldn't work as I expect it to.
I use the HtmlViewer to display Google maps and PDF reports.
To emulate popup windows and display a Silverlight module on top of the rest of the application (a Silverlight module and the NTML viewer) I create a new DIV with a higher z-index where I put the new Silverlight plugin.
The issue I came accross is that the XamWebHtmlViewer appears on top of the new Silverlight popup although the DIV of the Sivlleright plugin has a higher z-index.
It seems that the XamWebHtmlViewer does something to the DOM that makes it come up on top. If I use the DeveloperTools from IE and touch the z-index of the Silverlight popup plugin, then it comes on top as it should.
I attached a sample showing the behaviour.
Click on the "Show popup" button. The popup plugin shows behind the XamWebHtmlViewer. Open the DeveloperTools from IE and set the z-index of the plugin DIV to 1000 and the popup gets to the front.
Hi R4cOOn,
I spent some time trying to figer out what the problem with your "strange" application is :-)
Finally, I find out that you just have to change "z-index" to "zIndex".
Cheers,
Doychin Dochev
Sorry for the delay. I can't work out how to receive emails on replies :(
Thanks for your help. Replacing z-index (as described in the W3C standards http://www.w3schools.com/css/pr_pos_z-index.asp) by zIndex (which is the Javascript equivalent) does work. It really shouldn't.
Do you recon that could be a bug in Silverlight? When I use the developper tools to check what gets in the DIV in both cases, I get exactly the same result (z-index: 10000). That's really odd.
I'll see if I can use the XamWebHtmlViewer in my app now.
Cheer.