locked
4.5.1 RTM with Visual Studio 2012 (DatePicker won't work)

    Question

  • I'm trying to build a small application to test the new DatePicker control that is in Windows 8.1. I have the Windows 8.1 upgrade installed along with Visual Studio 2012. I have the Microsoft .NET Framework 4.5.1 Developer Pack installed as well and have targeted 4.5.1 in VS 2012.

    Before I state my problem, I did notice in the Object Explorer that both the 4.5 and 4.5.1 assemblies are loaded. I can't seem to get it to force the 4.5 out. Not sure if that makes a difference or not (it said the build system manages this)

    Using Xaml (C#) I can get intellisense for <DatePicker /> without a problem. When I go to compile, I get the following error:

    Error 1 Unknown type 'DatePicker' in XML namespace 'http://schemas.microsoft.com/winfx/2006/xaml/presentation'

    DatePicker is also a control listed in the toolbox. I tried dragging and dropping it onto the design surface just to be sure I was doing everything correctly. However, I still get the above error.

    What am I doing wrong.

    Friday, October 18, 2013 5:05 AM

Answers

  • The .Net Framework 4.5.1 Developer Pack allows targeting .Net Framework 4.5.1. This is different from targeting Windows 8.1. The Windows Runtime is different from the .Net Framework.

    You may be able to hack things to partially work, but this isn't supported and you'll run into weird edge cases like the one you describe in this thread.

    --Rob

    Friday, October 18, 2013 7:04 PM
    Moderator

All replies

  • You probabely need Visual Studio 2013 in order to develop Win8.1 applications.

    Kloc

    Friday, October 18, 2013 5:43 AM
  • You probabely need Visual Studio 2013 in order to develop Win8.1 applications.

    Kloc

    This is correct. Visual Studio 2013 is required to build Windows 8.1 apps. You can build Windows 8 apps in Visual Studio 2012 and use them on Windows 8.1, but they cannot use the new Windows 8.1 features.

    --Rob

    Friday, October 18, 2013 6:59 AM
  • Actually you can. The Microsoft .NET Framework 4.5.1 Developer Pack is used to add Windows 8.1 development to Visual Studio 2012.

    According to the web site:

    "The .NET Framework 4.5.1 Developer Pack installs the multi-targeting pack for .NET Framework 4.5.1. Developers can build applications targeting the .NET Framework 4.5.1 using either Visual Studio 2012 or third party IDEs. You need to download the web installer instead of this package if you intend to redistribute .NET Framework 4.5.1."

    In addition, we have successfully compiled a complete Windows 8.1 application purely in VS 2012 without any VS 2013 software installed.

    Friday, October 18, 2013 11:53 AM
  • You probabely need Visual Studio 2013 in order to develop Win8.1 applications.


    Kloc

    This is correct. Visual Studio 2013 is required to build Windows 8.1 apps. You can build Windows 8 apps in Visual Studio 2012 and use them on Windows 8.1, but they cannot use the new Windows 8.1 features.

    --Rob

    What's the downside to using 2013 express?

    Friday, October 18, 2013 5:15 PM
  • >>What's the downside to using 2013 express?

    You cannot develop apps for Win8 with 2013 express but only for win 8.1.

    There is no many users of 8.1 so I think it is better to stay with 2012 and old win8 apps much more that all Win8 apps work on Win8.1


    Andrzej



    • Edited by Andrzey Friday, October 18, 2013 5:56 PM
    Friday, October 18, 2013 5:53 PM
  • Not an option. We are upgrading a few internal programs and we need to support Bluetooth. Something we cannot do in Windows 8
    Friday, October 18, 2013 5:57 PM
  • The .Net Framework 4.5.1 Developer Pack allows targeting .Net Framework 4.5.1. This is different from targeting Windows 8.1. The Windows Runtime is different from the .Net Framework.

    You may be able to hack things to partially work, but this isn't supported and you'll run into weird edge cases like the one you describe in this thread.

    --Rob

    Friday, October 18, 2013 7:04 PM
    Moderator
  • The .Net Framework 4.5.1 Developer Pack allows targeting .Net Framework 4.5.1. This is different from targeting Windows 8.1. The Windows Runtime is different from the .Net Framework.

    You may be able to hack things to partially work, but this isn't supported and you'll run into weird edge cases like the one you describe in this thread.

    --Rob


    Ahhh... I thought 4.5.1 WAS Windows 8.1 Runtime.. heh. ok.. That sucks. Thank you for the response.
    Friday, October 18, 2013 7:06 PM