Note that there are some explanatory texts on larger screens.

plurals
  1. POMVVM Windows 8 appBar mvvm event
    primarykey
    data
    text
    <p>My problem is with event. In AppBar all events, which I to inventend, they didn't to worked. (MessageDialog or other event ), when AppBar to showed, I can't hiding, and In AppBar didn't to worked click in button.</p> <pre><code>&lt;Page.BottomAppBar&gt; &lt;AppBar x:Name="AppBar" Background="#FF1DB05F"&gt; &lt;StackPanel Orientation="Horizontal" HorizontalAlignment="Right"&gt; &lt;Button x:Name="SaveButton" Style="{StaticResource AppBarButtonStyle}" Content="&amp;#xE105;" AutomationProperties.Name="Save" &gt; &lt;WinRtBehaviors:Interaction.Behaviors&gt; &lt;Win8nl_Behavior:EventToCommandBehavior Event="Tapped" Command="NewFileXml" /&gt; &lt;/WinRtBehaviors:Interaction.Behaviors&gt; &lt;/Button&gt; </code></pre> <p>In MainViewModel.cs</p> <pre><code>public async void NewFileXml() { XmlDocument dom = new XmlDocument(); XmlComment comment = dom.CreateComment("This is Goal a Year"); XmlElement x; dom.AppendChild(comment); x = dom.CreateElement("Goal of a Year"); dom.AppendChild(x); XmlElement stepXml = dom.CreateElement("Goalyear"); XmlElement goalYearXml = dom.CreateElement("GoalStep"); stepXml.InnerText = GoalYear; goalYearXml.AppendChild(stepXml); Windows.Storage.StorageFolder sf = await Windows.ApplicationModel.Package.Current.InstalledLocation.CreateFolderAsync("GoalPlan"); StorageFile st = await sf.CreateFileAsync("GoalYear.xml"); await dom.SaveToFileAsync(st); } public ICommand NewFile { get { return new RelayCommand(() =&gt; { NewFileXml(); }); } } </code></pre> <p>I did with help from Polish Microsoft. Maybe Someone that to add.</p> <pre><code> private RelayCommand exampleContent; public RelayCommand ItIsBind { get { return exampleContent ?? (exampleContent = new RelayCommand(ContentLoad)); } } **Method example** public void ContentLoad() { } </code></pre>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload