Hi folks,
Today I want to talk a little more about the
Windows Embedded Silverlight Tools (
WEST) that come with
Windows Embedded Compact 7 (WEC7).
As explained in my
Silverlight for Windows Embedded (SWE) tutorial for WEC7,
WEST generates most of the C++ glue code that with
Windows Embedded CE 6.0 R3 we would have to write ourselves!
But can
WEST be used to write a stand-alone application without
Platform Builder?
Well
WEST generates a
Platform Builder subproject that can not be used out of the box as of now. This subproject contains, amongst others, a
sources file,
.bib,
.reg,
.dat, and .
db files as well as a
.pbxml file. There is no
.sln file. So in order to use the
Platform Builder subproject generated by
WEST, we need to create a solution using the generated source files as well as a
WEC7 SDK including
SWE support.
How about using
WEST to generate code for
SWE in
Windows Embedded CE 6.0 R3?
First of all
WEST installs in
Visual Studio 2008 SP1 whereas
Windows Embedded CE 6.0 R3 is a plug-in for
Visual Studio 2005. So you need to have both versions of
Visual Studio installed.
I created a simple
SWE project for
Windows Embedded CE 6.0 R3 in
Expression Blend 2, similar to the one I showed in my
SWE tutorial for WEC7. Surprisingly,
WEST generated the C++ glue code for my simple
SWE project for
Windows Embedded CE 6.0 R3 and it even ran without problems on
WEC7.
But when trying to import the C++ code generated by
WEST into a
Windows Embedded CE 6.0 R3 subproject, I experienced some build errors. After including the correct header files and tweaking the sources file a little, I saw that the
API set was extended in
SWE for
WEC7. In my specific example the
SetResource() function as well as the
XRXamlSource constructor was extended by a version that takes 2 arguments that is not available in
SWE for
Windows Embedded CE 6.0 R3.
After adjusting those calls my
WEST generated sample compiled under
Windows Embedded CE 6.0 R3.
Summary:
I would advice against using
WEST to created
SWE C++ code for
Windows Embedded CE 6.0 R3 as even in my very simple sample project there were a lot of things to take care of manually. Instead rather use fellow
MVP Valter Minutes comandline tool XAML2CPP to generate the C++ glue code for
SWE for
Windows Embedded CE 6.0 R3 projects.
Have fun!
Read more!
Post this to a friend!