Intersoft WebDesktop Documentation
Using IFrame as ContentMode
See Also Send Feedback
Intersoft WebDesktop > WebPaneManager > Tutorials > Using IFrame as ContentMode

Glossary Item Box

Objectives

You can use IFrame as a content in a WebPane. This property is only available for a WebPane object and not available in WebGroupPane.
The value of the property is an enumeration of type ContentMode which values are

C# Copy Code
/// <summary>
/// Enumerations for the content mode used by a container.
/// </summary>
public enum ContentMode
{
/// <summary>
/// The default content mode.
/// </summary>
Default = 0,
/// <summary>
/// The content is specified in Template.
/// </summary>
UseInlineContent = 1,
/// <summary>
/// The content is specified in another page which displayed in an IFrame.
/// </summary>
UseIFrame = 2
}

  1. You can access that property during DesignTime either by right clicking the WebPaneManager and choosing WebPane Designer or WebPane Advanced Designer.
  2. When you choose the value of that property as UseIFrame, you can specify the ContentURL property as that property will only be used when the value of Content mode is set to UseIFrame. For example you can put ~/About.aspx as the value of ContentURL.
  3. In the snap shot below inside WebPaneManager Advanced Designer, the middle Pane is configured using IFrame Content mode.


  4. Once you return to the VisualStudio Design Surface, you will get something like below:



  5. If you notice, there is a button in the middle Pane with a Text "Edit About.aspx", when the button is clicked you will be automatically redirected to About.aspx page and it will appear in the Design Surface.

 

If you still insist on using the InlineContent because you want to have other implementations in that WebPane, that is also possible.

To do that you can simply click on the Source Button in the VisualStudio Design Surface and write the <iframe> HTML Tag inside the Content Template tag. Below is one implementation how a WebPane with ContentMode = UseInlineContent can contain an iframe.
Script Copy Code
<iswebdesktop:webpane>                   
<contenttemplate>
<b>This is my iframe in a template</b>
<iframe id="left" src="About.aspx" height="100%" width="100%">
</iframe>
</contenttemplate>
</iswebdesktop:webpane>

See Also

Related Tutorials
{Creating Simple Layout}

© 2012 Intersoft Solutions Corp. All Rights Reserved.