Windowed XAML App - c++

I want to make a windowed app in XAML on Windows 8 in C++, but the only XAML options as far as I can tell are Metro (casual) apps (full screen). However, my app is not a casual app, and as such I want it to be a desktop (windowed) app. Also, I would like Window 7 users who hate Windows 8 to be able to use it.
Is there any way? Changing <Page ... </Page> to <Window ... </Window> doesn't seem to fix the issue (at least for me). I know Visual Studio 2012 can do Windowed XAML C# as I opened a project from a while back and it runs windowed.
Is this just a project setting or what?

EDIT: It's not a project setting; you're attempting something that was never supported. C++ is not a WPF language. You'll need to use C# or Visual Basic to build a WPF Desktop app, which is supported both in VS2012 and VS2010. Sorry I missed the fact that you're working in C++.
(C# should not be a steep learning curve, if you haven't used it before and you're used to C++. And you can port C++ over in CLR libraries if needed.)
Probably, it's just a project setting, and it depends on the version of Visual Studio you have. I think the Express versions of Visual Studio 2012 only permit the creation of "Metro-style" apps, while the Professional, Premier, or Ultimate editions have desktop (WPF or Silverlight) target projects.
To be sure, start up a new solution and see if you're given the choice. If not, you probably don't have the right version of VS2012. Be sure to check down the treeview of project types to make sure that you haven't missed one. If it's really the Professional version of VS2012, it'll be in there or it'll be downloadable.

Related

Creating Winforms in Visual C++ for WinCE7 in Visual studio 2008 with WinCE7 platform builder

I did a User interface in Windows 7. It contains buttons, labels, tabs and almost all features available in VS2008 tool box.
The UI coding is done in Visual C++.
Now I want to port the same UI in WinCE7. I started the work by upgrading VS2008 Sp1 and Platform builder for WinCE7.
Now I took a new project->Visual c#->Smart Device->Device Application and started the UI.
So I need to make a good amount of changes, also some functions are not available.
So am not able to complete the UI, no tabs selection is found and many others.
So can I get any ideas to port the same UI (created in visual c++) in WinCE7?
How can I create a new UI for WinCE7 in Visual c++ in Visual Studio 2008 ?
It is sooooo not that easy. Windows CE is a small subset of Win32. You have to pull in your code, hit build and then start fixing the errors.
If you used good separation of UI from business logic then it's probably easiest to just start an entirely new UI app for CE and reuse the business bits. If your code it tightly coupled, well you've got a long road ahead. There is no magic bullet for this one.
You are mixing stuff here.
To develop applications for Windows CE 7 you don't need Platform Builder. You need it to build a configure an OS Image or to change a board-support-package (BSP) and debug it, including drivers.
For application development you need just Visual Studio 2008 professional and an SDK, provided by the device manufacturer.
Windows CE APIs are different from Win32 ones and may be seen as a subset of those.
You can create a new Windows CE application (with dialogs etc) using the new project dialog of visual studio 2008, just select the "Smart Device" category to see the templates you can use.
Porting existing code may require modification of C/C++ code (API changes) but also of the .rc file (resources) because Windows CE does not support all the features provided by Win32 resources.

Is it possible to run VC++, Win32 application compiled on Visual Studio 2005 on Windows 8 environment?

I am a C++ Developer and learning developing an application that runs on Windows 8 environment.
My current application is VC++ - Win32 (Non-MFC) application, it is compiled on Visual Studio 2005.
It runs on Windows XP, Windows 7 very well.
My Questions:
Is there any tutorial available freely that help me to make my application run on Windows 8?
Is it strongly required to re-write the code and convert my application to Metro Style Application?
You can run the application on Windows 8 (except Windows RT) as a regular win32 application. We currently compile our windows app with Visual Studio 2005, and it works on Windows 2000 to Windows 8.
If you want to make it a "Windows Store App" with the interface formerly known as Metro, you'll need to rewrite at least the user interface to use the new Metro APIs, and you won't be able to use Visual Studio 2005 for that. If you did that you'd need to make two versions of the app, one for the "Windows store" on windows 8 and one for all previous versions of Windows.
Your application should almost certainly run just fine on Windows 8 if it runs fine on 7 and Vista, provided that any necessary runtime components (e.g. the VS2005 redists) are installed, if they're not already present.
As for rewriting it as Metro style, that really depends, both on the app itself, and whether you think it makes sense for your target market. That question can only be answered by you (and I guess, your users).
For question 1, check MSDN, a lot of material there.
For 2, not required, most of old application can run on Windows 8 without modification. you don't need to convert your application to Metro style
And the reason why your store application needs to be written using Visual Studio 2012 is because for Store apps, only the C++ runtime from VS 2012 is supported. See the below post for more details:
http://blogs.msdn.com/b/vcblog/archive/2012/09/28/10354327.aspx

Deploy a C program compiled in VS2010

I have a compiled an older C++ program that runs fine in debug mode in VS2010 converted to VC++ 6 but I have no idea how to package or deploy the application.
VS2010 may not have anything to do with deploying the program at all but I thought I should mention it.
The "release" folder not only contains the executable but some "obj", "tlog", "vc100.pdb", "exe.intermediate.manifest" and "lastbuildstate".
This application is being installed on Windows Mobile OS (hopefully). It isn't as simple as copying the executable to the device is it?
Do I need to create a cab file or msi and, if so, how?
I am absolutely new at this being spoiled in C# and MVC for far too long!
Visual Studio 2010 does not have any of the Smart Device compilers (managed or native) required to even build for Windows Mobile (not Windows Phone). You must use Visual Studio 2008 to build, deploy and/or debug.
EDIT
FWIW, Studio 2012 will have support for Smart Devices (Studio 2010 still won't get support) in Q1 of next year. Backward-compatibility has yet to be announced, but it's always possible that you'll be able to develop for WinMo devices using the ARM compiler. There's a video here detailng some of the features.
Have you done a search on google yet? While I don't know anything about deploying to a windows phone, a quick google search found a few hits.
I searched for 'deploy windows phone app' and found a few things. Among which are:
http://msdn.microsoft.com/en-us/library/windowsphone/develop/gg588378(v=vs.92).aspx
http://msdn.microsoft.com/en-us/library/windowsphone/develop/ff928362(v=vs.92).aspx
Last of all, it looks like this has been asked before on this website. For instance:
Can you install you own apps on your windows 7 phone

Rich gui in MFC/C++ application

we have once application build using MFC/C++. We want make the bit rich UI like VS 2010 or outlook etc... at last we want give new look to our app like Microsoft does on every release of their products.
Please suggest me to topic that i need to look into or suggest me the option for the same.
If you're using Visual Studio 2010 or higher, the MFC application wizard itself will generate UI like VS 2010 with tabs and docking windows. In fact you can create an application that looks like VS 2010 without writing a single line of code. There is also support for the ribbon control which has replaced the menus in the new office applications.
As I am assuming you are going to use C++/native code, MFC is still the way to go or you can choose the WTL also. If you are ready yo go to a totally different direction then QT is one of the most advanced and modern cross platform library. MFC feels old compared to QT. AFAIK you can not use ribbon control in QT without microsoft license.
Another option is to go to managed way, you can use WPF with C#.
As already mentioned, you can use the new classes in the MFC feature pack, which came with Visual Studio 2008 Service Pack 1.
MSDN provided a tutorial how to migrate an old MFC application to the new MFC feature pack classes here: http://msdn.microsoft.com/en-us/library/bb983935%28v=vs.90%29.aspx

Visual C++ Development

I'm learning C++, and know a little bit of Visual Basic and an Delphi.
But I want to know, is there some program like Delphi, but for C++. Something where you can drag a button to a form, double click it, the like in Delphi and VB: opens a code editor and you edit the code of the button, but with a similar code of C++?
I'm using Windows Vista.
Yes, if you use MFC within Visual Studio.
MFC is Visual Studio's C++ class library for writing Windows programs, and for an MFC form Visual Studio behaves exactly as you describe.
As of Visual Studio 2008 with an upgrade pack you can create Office 2007 style applications, and Visual Studio style applications, using MFC.
There used to be "C++ Builder", a C++ version of Delphi, I don't know if this product is still being developed or not.
UPDATE: to summarize information from the comments, C++ Builder is actively developed and the product page is http://www.embarcadero.com/products/cbuilder/
You can have the following IDEs with GUI designers for free;
Visual Studio 2008 express from Microsoft
Qt Creator from Nokia
Eclipse with Qt plugin from community :)
C++ Builder from Embarcadero
(previously CodeGear, previously
Borland)
Have fun with C++!
There are other packages besides MFC that do GUI stuff, but I don't think they plug-in to Visual Studio. I must confess, I have never been a fan of MFC. I find it ugly and painful, so I can't really recommend it.
Qt has a designer, as does GTK. I haven't used the Qt designer, but the GTK one works well. It can be found here: http://glade.gnome.org/ You can get glade for Windows here: http://gladewin32.sourceforge.net/
It can be hassle to set these up, though.
Honestly, while I like C++ a lot, writing GUIs for Windows is not where it excels. I would recommend that you look at C# instead. You can still interface with C++ if you need to, but it makes writing Windows GUIs so much nicer.