Intersoft ClientUI Documentation
Source Property
See Also  Send Feedback
Intersoft.Client.UI.DocumentViewers Namespace > FlowDocumentViewerBase Class : Source Property






Gets or sets the flow document source. Gets or sets the flow document source.

Syntax

Visual Basic (Declaration) 
<CategoryAttribute("Common Properties")>
Public Property Source As Uri
Visual Basic (Usage)Copy Code
Dim instance As FlowDocumentViewerBase
Dim value As Uri
 
instance.Source = value
 
value = instance.Source
C# 
[CategoryAttribute("Common Properties")]
public Uri Source {get; set;}
Delphi 
public read-write property Source: Uri; 
JScript 
CategoryAttribute("Common Properties")
public function get,set Source : Uri
Managed Extensions for C++ 
[CategoryAttribute("Common Properties")]
public: __property Uri* get_Source();
public: __property void set_Source( 
   Uri* value
);
C++/CLI 
[CategoryAttribute("Common Properties")]
public:
property Uri^ Source {
   Uri^ get();
   void set (    Uri^ value);
}

Remarks

There are a number of ways to load a FlowDocument in a viewer. You can set the Source property of the control to the URI of the document, or set the Document property to a FlowDocument object. You can bind the Source property for dynamic loading of a FlowDocument. If you have document that is not FlowDocument format, you can specify a converter using DocumentConverter. For example, you can load HTML file and convert it to FlowDocument format.

XAML Copy Code
<Intersoft:UXPage 
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" 
        xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
        xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
        mc:Ignorable="d"
        xmlns:Intersoft="http://intersoft.clientui.com/schemas"
    xmlns:Converters="clr-namespace:TestProject.Converters"
        x:Class="TestProject.TestFlowDoc" 
        Title="TestFlowDoc Page"
        d:DesignWidth="640" d:DesignHeight="480">

    <Intersoft:UXPage.Resources>
        <Converters:HtmlConverter x:Key="HtmlConverter"/>
    </Intersoft:UXPage.Resources>

    <Grid x:Name="LayoutRoot">
        <Intersoft:UXFlowDocumentViewer Background="White" Source="{Binding SelectedEmail.BodySource}" 
                                              DocumentConverter="{StaticResource HtmlConverter}"/>
    </Grid>
</Intersoft:UXPage>

Requirements

Target Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, Windows Vista, Windows Server 2008 family

See Also

© 2012 All Rights Reserved.