How can use it in my project?

Dec 20, 2011 at 5:21 AM

sorry,I have read the document about the YLAD,but I don't know how to use it in my project?

I do something like this:

- Download the package from CodePlex, reference the included assembly in my project.

- Creat folder and file like this :Content/About/Data.XML.

- Creat a new page "About.xaml".

Then what should I do?

I try to use the navigation service of a page to go to the about page:

 

NavigationService.Navigate(new Uri("/YourLastAboutDialog;component/AboutPage.xaml", UriKind.Relative));

But it is blank. Please help me,thanks a lot!

 

Dec 20, 2011 at 9:34 PM

Hello Yan,

The best way is to get YLAD through NuGet!

That way it will create the About.xaml and ../Data.xml for you! If you then use the NavigationService.Navigate, you will see a working page.

Dec 21, 2011 at 2:32 AM

Thanks! I try to use  the NuGet, it created the  ../Data.xml and added the reference, but it did not create the About.xaml, why?

I have uninstalled  the YLAD and reinstall it several times,but I can't find the About.xaml. Should I create a new solution for it? 

Thanks you very much! 8-)

Dec 21, 2011 at 2:45 AM

I create a new solution and install the YLAD through NuGet. But I can't find the About.xaml. Should I creat the About.xaml myself or by the YLAD? 

Thanks !

Coordinator
Dec 21, 2011 at 7:54 AM

Hallo Yan. You don't need to create the About.xaml, and no About.xaml is created for you: it's already there, in the assembly of YLAD, you just can't see it. So the required steps are really simple:

  1. Install the NuGet package. Confirm that this has added the YLAD assembly to the references of your project, and that a Content/About/Data.xml file has been created in your project, with its properties set to a build action of "Content".
  2. Put the navigation code in the place where you want to show the about page, e.g. in a button click event handler, or in a click event handler of an application bar button etc.: NavigationService.Navigate(new Uri("/YourLastAboutDialog;component/AboutPage.xaml", UriKind.Relative));

That's it! You should see the about page when you run your application. All you need to do now is open the Content/About/Data.xml file and fill in your own data/replace the existing one with meaningful information. For that, you can find detailed information on the Documentation page here.

I hope this helps,
Peter 

Dec 21, 2011 at 8:12 AM

Oh thanks a lot! It's amazing! It looks like I haven't understand the meaning about the YLAD. I make a mistake, 8-)

I really appreciate your help! 

Dec 21, 2011 at 8:12 AM
Edited Dec 21, 2011 at 8:13 AM
depechie wrote:

Hello Yan,

The best way is to get YLAD through NuGet!

That way it will create the About.xaml and ../Data.xml for you! If you then use the NavigationService.Navigate, you will see a working page.

 

 

Thank you for your help! It works well now. 8-)

Dec 21, 2011 at 8:18 AM
Mister_Goodcat wrote:

Hallo Yan. You don't need to create the About.xaml, and no About.xaml is created for you: it's already there, in the assembly of YLAD, you just can't see it. So the required steps are really simple:

  1. Install the NuGet package. Confirm that this has added the YLAD assembly to the references of your project, and that a Content/About/Data.xml file has been created in your project, with its properties set to a build action of "Content".
  2. Put the navigation code in the place where you want to show the about page, e.g. in a button click event handler, or in a click event handler of an application bar button etc.: NavigationService.Navigate(new Uri("/YourLastAboutDialog;component/AboutPage.xaml", UriKind.Relative));

That's it! You should see the about page when you run your application. All you need to do now is open the Content/About/Data.xml file and fill in your own data/replace the existing one with meaningful information. For that, you can find detailed information on the Documentation page here.

I hope this helps,
Peter 

Thanks a lot! I thought I must create a About.xaml myself. The YLAD is a very good project.  I will recommend it  to others.