none
No App.Config for Mobile Application in VS2008? RRS feed

  • Question

  • I have a Smart Device application that I am trying to connect to a local WSE3 web service.  I am learning about WSE3 and it claims that I need to make changes to the .Config of the client application in order to enable it for WSE3 etc. Now, this is where I sound very stupid, why can I not add an app.config file to the smart device application? In my templates I have everything but an application config file that I can add to the project. What am I missing something?


    THanks for any help.

    Santiago Perez
    Thursday, January 8, 2009 4:34 PM

Answers

  • WCE3 (and 2 for that matter - though there's 3rd party implementation for WCE2 AFAIK) is not supported by NETCF.

    Configuration file you've mentioned is just a tip of an iceberg - which is in this case plain missing. It is actually supported by NETCF, but only entries about framework and assembly versions are actually processed.


    This posting is provided "AS IS" with no warranties, and confers no rights.
    Thursday, January 8, 2009 6:38 PM
    Moderator

All replies

  • WCE3 (and 2 for that matter - though there's 3rd party implementation for WCE2 AFAIK) is not supported by NETCF.

    Configuration file you've mentioned is just a tip of an iceberg - which is in this case plain missing. It is actually supported by NETCF, but only entries about framework and assembly versions are actually processed.


    This posting is provided "AS IS" with no warranties, and confers no rights.
    Thursday, January 8, 2009 6:38 PM
    Moderator
  • SO you're telling me I cannot access a WSE3 Web service from Windows Mobile 6??? If this is the case, what are my options for sending an serializable object from my handheld to the server? Plain old Web services?


    Santiago Perez
    Friday, January 9, 2009 2:21 PM
  • Correct, you cannot.

    You can use Web Services without WCE, MSMQ, subset of WPF supported in NETCF V3.5 and sockets.


    This posting is provided "AS IS" with no warranties, and confers no rights.
    Sunday, January 11, 2009 7:47 AM
    Moderator
  • I understand that you can't connect MObile app to WSE 3.0 but just for my curiosity, why can't I add an App.config to my mobile application? I don't see it in the templates when you do "Add new Item" on the project.

    Thanks
    Santiago Perez
    Monday, January 12, 2009 2:45 PM
  • There are no good reasons to add it, but you can do it by adding a "Text File" and typing in the name.


    This posting is provided "AS IS" with no warranties, and confers no rights.
    Monday, January 12, 2009 4:49 PM
    Moderator
  • Dynamic URL for web services :)
    Santiago Perez
    Monday, January 12, 2009 7:20 PM
  • That is also not supported. As I mentioned, nothing is supported except for framework and assembly versions retargeting.

    The only reason to add 'app.config' file into device project is to suppress warnings from using any assemblies compiled for previous framework version.


    This posting is provided "AS IS" with no warranties, and confers no rights.
    Monday, January 12, 2009 8:56 PM
    Moderator
  • SO what is a good way to have configurable way to change the location of the Web Service from Development through QA/Staging to Production? The Web Service will physically change locations and therefore there should be an easy way for the mobile client to adapt. I do apologize if this may seem as very basic questions but it is really surprising the way the mobile framework is setup.

    THanks for all your great help with this thread and the others.

    Santiago Perez
    Monday, January 12, 2009 9:02 PM
  • Nothing stops you from adding and processing app.config file (or any other configuration storage) in your code.

    Just open the file, parse it (e.g. with LINQ app.config can be parsed in pretty much one line of code) and set up URL for your Web service programmatically using this information.


    This posting is provided "AS IS" with no warranties, and confers no rights.
    Monday, January 12, 2009 9:10 PM
    Moderator
  • SO does that qualify as a good reason? :) ha ha, Just messing with you. Had to get you a litte frustated as I've been these past couple of days.


    That is exactly what I ended up doing. Was just wondering if there was a more elequant way of doing this.

    Santiago Perez
    Monday, January 12, 2009 9:14 PM
  • I've been using the Confugiration block from the MCSF on a number of projects:

    http://www.codeplex.com/smartclient

    -Alex
    Wednesday, January 14, 2009 4:41 PM