C# and XAMAL

This topic contains 1 reply, has 1 voice, and was last updated by  SapnaVishwas 2 years, 7 months ago.

  • Author
    Posts
  • #10493

    Arnold
    Member

    I need a little and maybe you guys/girls can point to me in the right direction.

    I am creating a Windows 8 application in Visual Studio using C# and XAMAL.
    I am having problem with loading an image once you click on a radio button. Then, if you click another radio button, the image change. Any help?
    Not sure if this is the correct way

  • #10494

    SapnaVishwas
    Member

    The above code is one of the ways you can do it, but for a starters that looks like VB.NET not C#. Once you have your XAML though, if you double click the control in Visual Studio it’ll automatically create the method for you to put your code in.

    However, the preferred way to do it in WPF is through the Model-View-View-Model (MVVM) pattern, which uses the concept of bindings. Basically, your View is the XAML and the View Model contains properties to store things like commands, text in text fields and selected values, which are binded to the controls in your XAML. The Model is basically the logic of the program and the classes that contain the functionality of your program.

    Check out the following link. I found the video at “Jason Dolinger’s presentation on the Model-View-ViewModel” extremely useful personally, but I learn better from videos.

    http://stackoverflow.com/questions/1405739/mvvm-tutorial-from-start-to-finish

You must be logged in to reply to this topic.