Respecting Your Investments: How to Leverage Your Existing Code in a New Windows Runtime LOB App

Play Respecting Your Investments: How to Leverage Your Existing Code in a New Windows Runtime LOB App
Sign in to queue

Description

Many businesses are finding they need new versions of their trusty LOB apps for their increasingly mobile workforce. However, these businesses also want to leverage the existing investments they have made to date. In this session, learn about changes in Windows 8.1 Update to allow businesses to build new mobile LOB applications without having to re-write their entire app from scratch.

Day:

2

Session Type:

Breakout

Code:

WIN-B329

Room:

Room 370A

Embed

Download

Right click to download this episode

The Discussion

  • User profile image
    StephenPSA

    Great talk, very good! Beautiful sample for a Brokered WinRT component implementation. I had. however a difficult time replicating it.
    There are a couple of gotcha's I would like two point out:
    1) The dll proxy path must not contain spaces (or at least not be the user/Documents/.../Projects path)
    2) When attaching the debugger you attach to DLLHOST.DLL (but you must not change 'clrhost.dll' in the manifest)
    3) for some weird reason the manifest edit would not accept pasted coded, giving a 'Package/Extensions' must be empty exception whatever I tried. When entered manually, i.e. layer by layer' it worked fine. (although resulting in the exact same code, I double checked)
    <Extensions>
    <Extension Category="windows.activatableClass.inProcessServer">
    <InProcessServer>
    <Path>clrhost.dll</Path>
    <ActivatableClass ActivatableClassId="PsaHidRT.HidExplorer" ThreadingModel="both">
    <ActivatableClassAttribute Name="DesktopApplicationPath" Type="string"
    Value="C:\Sample\PsaHidRT\Debug\PsaHidProxy"/>
    </ActivatableClass>
    </InProcessServer>
    </Extension>
    </Extensions>
    // The error when manifest edited by Paste:
    Error 3 App manifest validation failed. Value of element '/Package/Extensions' must be empty string. C:\Sample\PsaHidRT\HidTester2\Package.appxmanifest 52 HidTester2
    4) The samples supplied by microsoft mostly would not build on my machine (all default and up-to-date VS2013 Pro with Update2 installed)
    That all folks...

  • User profile image
    StephenPSA

    Regarding the above point 3: weird manifest error

    I think I figured out what caused the above error:

    the 'Getting Started' document, supplied with the templates (Brokered WinRT...) package sample contains angle brackets within the quotes to replace, this confuses the xaml parser, so I suggest you edit first and then copy and paste

    PS It also has an additional step 7, not mentioned in the talk, which I did not do and apparently did not need.

  • User profile image
    StephenPSA

    Gotcha's further findings...

    1) The Brokered WinRT Component templates are not up-to-date, BUT IS DOES WORK. At least the 'component'-project is not recognized as such by the VS IDE (open the project properties and the project type is blank and you can't change it to 'RT component).

    2) The fact that you attach to dllhost.dll while the manifest says clrhost.dll is explained by the pre-process step in the MyComponent.csproj file

    ...
    $(WINDIR)\syswow64\windowspowershell\v1.0\powershell.exe" ... rocessName -eq \"dllhost\" ...
    ...

Add Your 2 Cents