locked
ApplicationModel.Package.Dependencies ?

Answers

  • Hi Michael,

    You did not select as what I told, choose "Microsoft Visual C++ 2013 Runtime Package" instead you should be able to see the number 1.

    Besides, as I referenced before:  App packages and deployment , only Windows Library for JavaScript, C++ Runtime Libraries (CRT), and PlayReady DRM, are essential to the creation of Windows Runtime apps, if you have reference to these libraries, ApplicationModel.Package.Dependencies will get other number than 0.

    --James

    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    • Marked as answer by Mike-EEE Wednesday, March 18, 2015 10:06 AM
    Wednesday, March 18, 2015 3:13 AM
    Moderator
  • I guess my first question would be: Why doesn't *any* dependency that I add as checked in my image above, increase the count of detected dependencies?

    Secondly, I did try to add "Microsoft Visual C++ 2013 Runtime Package" yesterday, but a yellow icon appeared to make it look like it was incompatible with my solution (thereby adding to my perception that this was all just broken/untested functionality):

    Naturally, in outstanding and award-winning Visual Studio user experience ;) ;) ;) mousing over the yellow icon gives no indication of why it is there.  It is not until I compile that I see that the default project platform target that I downloaded this project in as ("Any CPU") is not compatible with this dependency.  Selecting "x86" removes the yellow icon.  (YAYYYYYYYYYYYYYYYYY!!!!!!!!!!!!!!!! WE MAKE SOFTWARE WORK!!!!)

    Doing all of this finally gets the single dependency count to move to 1.  Pretty amazing the hoops one must go through on a sample solution to demonstrate such a simple feature.  The question still stands on why the other references do not make the dependency count increase.  What makes this one (ironically a C++ reference in a C# project?  So confusing.) different than the others that magically make the dependency count increase?

    In any case, I do appreciate your patience and assistance in getting this to (finally) work, James. :)


    • Edited by Mike-EEE Wednesday, March 18, 2015 10:06 AM
    • Marked as answer by Mike-EEE Wednesday, March 18, 2015 10:06 AM
    Wednesday, March 18, 2015 10:04 AM

All replies

  • Hi Michael,

    I have referenced to a VC++ Runtime package for Windows, and I can see the dependency is 1.

    For more information please ref: App packages and deployment

    The Store hosts a unique set of app packages that contain operating system components that are serviced independently of the operating system. Windows Runtime apps can use these app packages by declaring a dependency in their app package manifest. These components contained in app packages hosted by the Store are called operating system component libraries. The Store manages the process of ensuring that the correct version of the component library is present when the app is installed on a device.  These libraries, which include Windows Library for JavaScript, C++ Runtime Libraries (CRT), and PlayReady DRM, are essential to the creation of Windows Runtime apps. When an app deploys from the Store, the operating system satisfies the dependency declaration by downloading and installing the appropriate component library with the app that is being downloaded from the Store.

    For side loading Windows Store apps for testing or enterprise deployment, the Windows component library app package must be supplied and specified during deployment of the app package.

    --James


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    Monday, March 09, 2015 6:29 AM
    Moderator
  • Thanks James for your reply.  Just to be sure... you had to actually add a dependency to do this, correct?  If that is the case, why is the default code not like this?  It doesn't seem to be very useful if it is showing off default functionality and the user is expected to perform an action without and documentation to do so.

    I also did try to add a dependency to the C# project and it did not show up.  Is this a C++ only feature?

    Monday, March 09, 2015 4:42 PM
  • Hi Michael,

    Yes, I manually add the dependency. The sample code indeed demonstrate how to work with package.dependency API but not include any documentation for the explanation. I'm trying to find some channel that we can report to help improve our samples. Will reply here once I have some updates. Thanks for your understanding.

    It's not a C++ only feature, for example if we reference a C++ runtime library in a C# app, it is the project dependency, see my previous copied words:

    These libraries, which include Windows Library for JavaScript, C++ Runtime Libraries (CRT), and PlayReady DRM, are essential to the creation of Windows Runtime apps. When an app deploys from the Store, the operating system satisfies the dependency declaration by downloading and installing the appropriate component library with the app that is being downloaded from the Store.

    --James


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    Tuesday, March 10, 2015 6:06 AM
    Moderator
  • Wow... yes, this is pretty confusing and honestly poor guidance.  Not yours... the demo's. :)

    I want to be sure we are talking the same thing.  When I hear "dependency" I am thinking "reference."  I am beginning to suspect that this is not the same thing?

    This is what I am doing:

    1. Right-click References
    2. Click "Add Reference..."
    3. Select a Reference

    When I run the sample after doing this it is still showing 0 dependencies.  I have even created a ClassLibrary and have added it to my PackageSample.Windows project and it still does not show as a "Dependency."  Even though when I right-click a Project it mentions dependencies (and I can see this project as a dependency):

    There must be something I am overlooking.  Again, I am suspecting that "dependency" does not mean "reference".  It's pretty amazing that:

    1. The sample does not mention anything about this
    2. The documentation doesn't mention anything about this
    3. No one else using the documentation/sample has said anything about this!

    Or am I really the first person to actually download and look at that sample? ;P  I can't say I have ever seen a sample "demonstrate" an empty collection before by default, so you'll have to forgive my amazement here.


    • Edited by Mike-EEE Tuesday, March 10, 2015 11:26 AM
    Tuesday, March 10, 2015 11:25 AM
  • Yes, we are on the same thing, I will show you how I did this:

    #1, Right click references and Add Reference.

    #2, Select "Microsoft Visual C++ 2013 Runtime Package"

    #3, Run the app, you should be able to see the result.

    I'm not sure which kind of project you reference to because the image is broken in your link.

    Or we can create a new C++ Runtime component and reference it from our Package Sample project, you should be able to see the ApplicationModel.Package.Dependencies not 0.

    --James


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    Tuesday, March 17, 2015 2:58 AM
    Moderator
  • Yep, here are my references, and I still get 0.  This really looks and feels like untested/broken functionality (which is pretty much my experience with WinRT as a whole -- I hope this gets better with Windows 10!):


    Tuesday, March 17, 2015 10:47 AM
  • Hi Michael,

    You did not select as what I told, choose "Microsoft Visual C++ 2013 Runtime Package" instead you should be able to see the number 1.

    Besides, as I referenced before:  App packages and deployment , only Windows Library for JavaScript, C++ Runtime Libraries (CRT), and PlayReady DRM, are essential to the creation of Windows Runtime apps, if you have reference to these libraries, ApplicationModel.Package.Dependencies will get other number than 0.

    --James

    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    • Marked as answer by Mike-EEE Wednesday, March 18, 2015 10:06 AM
    Wednesday, March 18, 2015 3:13 AM
    Moderator
  • I guess my first question would be: Why doesn't *any* dependency that I add as checked in my image above, increase the count of detected dependencies?

    Secondly, I did try to add "Microsoft Visual C++ 2013 Runtime Package" yesterday, but a yellow icon appeared to make it look like it was incompatible with my solution (thereby adding to my perception that this was all just broken/untested functionality):

    Naturally, in outstanding and award-winning Visual Studio user experience ;) ;) ;) mousing over the yellow icon gives no indication of why it is there.  It is not until I compile that I see that the default project platform target that I downloaded this project in as ("Any CPU") is not compatible with this dependency.  Selecting "x86" removes the yellow icon.  (YAYYYYYYYYYYYYYYYYY!!!!!!!!!!!!!!!! WE MAKE SOFTWARE WORK!!!!)

    Doing all of this finally gets the single dependency count to move to 1.  Pretty amazing the hoops one must go through on a sample solution to demonstrate such a simple feature.  The question still stands on why the other references do not make the dependency count increase.  What makes this one (ironically a C++ reference in a C# project?  So confusing.) different than the others that magically make the dependency count increase?

    In any case, I do appreciate your patience and assistance in getting this to (finally) work, James. :)


    • Edited by Mike-EEE Wednesday, March 18, 2015 10:06 AM
    • Marked as answer by Mike-EEE Wednesday, March 18, 2015 10:06 AM
    Wednesday, March 18, 2015 10:04 AM
  • I guess I should clarify my question.  Again, I appreciate your patience and assistance here, James.

    I understand what you are saying in regards that only a few "dependencies" (for lack of a better term here) are registered as actual package dependencies (examples: Windows Library for JavaScript, C++ Runtime Libraries (CRT), and PlayReady DRM).  My question is ... what is the "special magic" here that happens to those dependencies that registers them as package dependencies?  And (more notably here) why are there so few of them?  It seems like (and the expectation is) *any* dependency that I add to my project would be a package dependency.

    At the end of the day, as someone who is exploring this API, this appears as a very obvious point in which I (as a developer wanting to utilize your API) can learn (and query) all of the package dependencies that are used to run my Store App.  Much like one would expect when they call AppDomain.GetAssemblies in a traditional .NET application (ahhh the good old days, when things were simpler, were intention-revealing, and "just worked." But I digress...).  However, that doesn't appear to be the case at all here, so again, we are sitting in confusion about the value of this property -- especially if it can only hold 1 or at most 2 (!) items (if I am understanding things correctly here -- please correct me if this not the case!).

    Wednesday, March 18, 2015 2:56 PM