Petr Minarik
Petr Minarik

Reputation: 37

View in frame XAML innitialization

I have XAML code to create program output in frame. I can change content of frame in case I used "MyFrame.Navigate(typeof(Setup))". Is there any way to initialize content of frame in XAML code?

XAML code fragment:

        </SplitView.Pane>
        <SplitView.Content>
            <Frame Name="MyFrame" ?any reference to view to first time intiilaization? />
        </SplitView.Content>

Thanks for help

Upvotes: 1

Views: 169

Answers (1)

lindexi
lindexi

Reputation: 4357

You can use SourcePageType

It can set in xaml ,the code is

    <Frame Name="MyFrame" SourcePageType="Setup"></Frame>

The frame will navigate to Setup

I think you can use the control above in the Frame when you enter the page ,you can set it Visibility and you can set is hidden when load complete.

Upvotes: 1

Related Questions