﻿<?xml version="1.0" encoding="utf-8"?><rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:sy="http://purl.org/rss/1.0/modules/syndication/" xmlns:media="http://search.yahoo.com/mrss/" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0"><channel><title>Intersoft Community - ClientUI - Strange issue with register form</title><link>http://www.intersoftsolutions.com/Community/ClientUI/Strange-issue-with-register-form/</link><description /><generator>http://www.intersoftsolutions.com</generator><language>en</language><copyright>Copyright 2002 - 2015 Intersoft Solutions Corp. All rights reserved.</copyright><ttl>60</ttl><item><title>Strange issue with register form</title><link>http://www.intersoftsolutions.com/Community/ClientUI/Strange-issue-with-register-form/</link><pubDate>Thu, 11 Jul 2013 08:20:07 GMT</pubDate><dc:creator>yudi</dc:creator><description>&lt;p&gt;&lt;span style="color: rgb(31, 73, 125);"&gt;Following is the original code in RegisterForm.xaml.cs.&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;// Executes when the user navigates to this page.
protected override void OnNavigatedTo(NavigationEventArgs e)
{
    RegisterFormViewModel viewModel = this.DataContext as RegisterFormViewModel;
    // For security purpose, the Password value is passed directly from the UI controls
    // to the view model. This is done through accessor function.
    viewModel.RegistrationData.PasswordAccessor = () =&amp;gt; Password_Input.Password;
    viewModel.RegistrationData.PasswordConfirmationAccessor = () =&amp;gt; PasswordConfirmation_Input.Password;
}&lt;/pre&gt;
&lt;p&gt;&lt;span style="color: rgb(31, 73, 125);"&gt;After modify the RegisterForm to be a UXDialogBox, then change the above code into the following.&lt;/span&gt;&lt;/p&gt;&lt;pre&gt;protected override void OnActivated()
{
    base.OnActivated();
    RegisterFormViewModel viewModel = this.DataContext as RegisterFormViewModel;
    //    // For security purpose, the Password value is passed directly from the UI controls
    //    // to the view model. This is done through accessor function.
    if (viewModel != null)
    {
        viewModel.RegistrationData.PasswordAccessor = () =&amp;gt; Password_Input.Password;
        viewModel.RegistrationData.PasswordConfirmationAccessor = () =&amp;gt; PasswordConfirmation_Input.Password;
    }
}&lt;/pre&gt;
&lt;p&gt;&lt;span style="color: rgb(31, 73, 125);"&gt;I have tested the solution in my local end and it works without any issues. Please feel free to let us know if you have different result.&lt;/span&gt;&lt;/p&gt;</description></item><item><title>Strange issue with register form</title><link>http://www.intersoftsolutions.com/Community/ClientUI/Strange-issue-with-register-form/</link><pubDate>Tue, 09 Jul 2013 12:08:53 GMT</pubDate><dc:creator>zen8019</dc:creator><description>&lt;p&gt;Hi&lt;/p&gt;&lt;p&gt;[I am using Metro template]&lt;/p&gt;
&lt;p&gt;I have cloned the RegisterForm and RegisterFormViewModel and changed the Registerform to be a DialogBox (I need to pop up this form from a page to register users).&lt;/p&gt;
&lt;p&gt;When completing this new form and clicking 'Create User' the password/confirmation controls display the 'This is a required field' as if the don't have a value - when they do. See attachment.&lt;/p&gt;
&lt;p&gt;I think the issue lies with these lines which  aren't fired when the form changes from UXPage to UXDialogPage&lt;/p&gt;&lt;pre&gt; // Executes when the user navigates to this page.
        protected override void OnNavigatedTo(NavigationEventArgs e)
        {
            RegisterFormViewModel viewModel = this.DataContext as RegisterFormViewModel;
            // For security purpose, the Password value is passed directly from the UI controls
            // to the view model. This is done through accessor function.
            viewModel.RegistrationData.PasswordAccessor = () =&amp;gt; Password_Input.Password;
            viewModel.RegistrationData.PasswordConfirmationAccessor = () =&amp;gt; PasswordConfirmation_Input.Password;
        }&lt;/pre&gt;
&lt;p&gt;I think these lines &lt;/p&gt;&lt;pre&gt;            viewModel.RegistrationData.PasswordAccessor = () =&amp;gt; Password_Input.Password;
            viewModel.RegistrationData.PasswordConfirmationAccessor = () =&amp;gt; PasswordConfirma&lt;/pre&gt;
&lt;p&gt;aren't running.&lt;/p&gt;
&lt;p&gt;I don't know how to make these lines run using UXDialogBox and MVVM - so I am looking to your advice - maybe there is a better way to pop up a Register User window.  I have attached image of the issue.&lt;/p&gt;</description></item></channel></rss>