Support Forums
how to use ActiveX(300, 150, 400, 200, "Shell.Explorer") for loading a webpage with transparent background

With the sample in the helppage(file:///C:/VTScada/VTSHelp/Content/Pro_Functions/ActiveX.htm?Highlight=Shell.Explorer), I can loading my webpage(test1.html) into the vtscada page as below code.

Now I want my webpage(test1.html) background is transparent so that I can use vtscada page background picture as my webpage background.

Maybe this is related to my webpage(test1.html) and ActiveX("Shell.Explorer" ). How can I do that? Thanks.

[
  Title = "OverviewLabel";
  Color = "<FFFFFFFF>";
  #ZeroMRBSize(0) = "-1,1138,1122,39";

  Loaded = 0;    
  BrowserObj;
]

Main [
  Return(Self); 

  BrowserObj = ActiveX(50, 50, 300, 400, "Shell.Explorer");
  If Timeout(Valid(BrowserObj) && !Loaded, 1);
  [
    BrowserObj\Navigate("http://192.168.1.118:9002/test1.html");
    Loaded = 1;
  ]

]
With the sample in the helppage(file:///C:/VTScada/VTSHelp/Content/Pro_Functions/ActiveX.htm?Highlight=Shell.Explorer), I can loading my webpage(test1.html) into the vtscada page as below code. Now I want my webpage(test1.html) background is transparent so that I can use vtscada page background picture as my webpage background. Maybe this is related to my webpage(test1.html) and ActiveX(&quot;Shell.Explorer&quot; ). How can I do that? Thanks. ```` [ Title = &quot;OverviewLabel&quot;; Color = &quot;&lt;FFFFFFFF&gt;&quot;; #ZeroMRBSize(0) = &quot;-1,1138,1122,39&quot;; Loaded = 0; BrowserObj; ] Main [ Return(Self); BrowserObj = ActiveX(50, 50, 300, 400, &quot;Shell.Explorer&quot;); If Timeout(Valid(BrowserObj) &amp;&amp; !Loaded, 1); [ BrowserObj\Navigate(&quot;http://192.168.1.118:9002/test1.html&quot;); Loaded = 1; ] ] ````

The best option here will really depend on the desired output. You can set a window transparency bit that will use the defined background color as transparent (More on this here ) however this will apply a color key mask to the rendered page. While this is perfect for many cases, it can leave some rough edges around soft transitions such as transparent PNG's or text with shadows.

The other approach is to work with your webpage and the VTScada page it is located to create a suitable frame or color matching to give the impression that the webpage is seamlessly part of the screen and not sitting on top of it.

The best option here will really depend on the desired output. You can set a window transparency bit that will use the defined background color as transparent (More on this [here](https://www.vtscada.com/help/Content/Pro_Functions/Window.htm) ) however this will apply a color key mask to the rendered page. While this is perfect for many cases, it can leave some rough edges around soft transitions such as transparent PNG&#039;s or text with shadows. The other approach is to work with your webpage and the VTScada page it is located to create a suitable frame or color matching to give the impression that the webpage is seamlessly part of the screen and not sitting on top of it.

Trihedral Engineering Ltd.

70
2
2
live preview
enter atleast 10 characters
WARNING: You mentioned %MENTIONS%, but they cannot see this message and will not be notified
Saving...
Saved
With selected deselect posts show selected posts
All posts under this topic will be deleted ?
Pending draft ... Click to resume editing
Discard draft