Design Problem!!

Discussion in 'ASP .Net Web Services' started by Jay, May 25, 2004.

  1. Jay

    Jay Guest

    Hello,

    I have Windows Forms application which uses MS Access Database and a Pocket
    PC application which uses Datasets, Iam trying to pass Datasets between
    these applications using WebServices. Both these applications are shrink
    wrapped so they need to perform with little user configuration

    WebService/IIS is running on the computer having the Windows Application and
    Pocket PC connectss to the webservice through Active Sync.

    Iam trying to accomplish following task and am breaking my head over it-

    1. How does the Webservice know where the MS Access Database is present. ie
    How will the windows application let webservice know the location of the MS
    Access database?
    * I thought of registry but WebService might not have permission to read
    it.
    * I thought of saving an xml file in wwwroot but it could be read only.
    * Web.config solution is not possible because end user is not very computer
    savvy, so every time MS Access database changes its path Web.config needs to
    chnage.
    * Finally I thought of Web Cache. But evertime user restarts his computer
    cache might get over written.
    Any other workable suggestions?

    2. When application starts up in the pocket pc, how will it find the name of
    the host computer to get to the location of the webservice? Since the
    client's computer name is not known in advance, can pocket pc application
    find it other than entering the name manually.

    Thanks a lot.
    Jay
     
    Jay, May 25, 2004
    #1
    1. Advertising

  2. Jay

    Jan Tielens Guest

    1) I would go for storing the location in the web.config. You can create a
    setup package that alters the web.config while installing the app. No user
    interaction is needed.

    2) I think you better post this question in a compact framework newsgroup...

    Another question, are you planning to run web services on a desktop pc?

    --
    Greetz
    Jan
    ________________
    Read my weblog: http://weblogs.asp.net/jan


    "Jay" <> schreef in bericht
    news:...
    > Hello,
    >
    > I have Windows Forms application which uses MS Access Database and a

    Pocket
    > PC application which uses Datasets, Iam trying to pass Datasets between
    > these applications using WebServices. Both these applications are shrink
    > wrapped so they need to perform with little user configuration
    >
    > WebService/IIS is running on the computer having the Windows Application

    and
    > Pocket PC connectss to the webservice through Active Sync.
    >
    > Iam trying to accomplish following task and am breaking my head over it-
    >
    > 1. How does the Webservice know where the MS Access Database is present.

    ie
    > How will the windows application let webservice know the location of the

    MS
    > Access database?
    > * I thought of registry but WebService might not have permission to read
    > it.
    > * I thought of saving an xml file in wwwroot but it could be read only.
    > * Web.config solution is not possible because end user is not very

    computer
    > savvy, so every time MS Access database changes its path Web.config needs

    to
    > chnage.
    > * Finally I thought of Web Cache. But evertime user restarts his computer
    > cache might get over written.
    > Any other workable suggestions?
    >
    > 2. When application starts up in the pocket pc, how will it find the name

    of
    > the host computer to get to the location of the webservice? Since the
    > client's computer name is not known in advance, can pocket pc application
    > find it other than entering the name manually.
    >
    > Thanks a lot.
    > Jay
    >
    >
     
    Jan Tielens, May 25, 2004
    #2
    1. Advertising

  3. Jay

    Rick Spiewak Guest

    I would recommend that the Windows Forms application pass the location of
    the Access database to the Web Service. The Web Service can store it in the
    cache. As far as restarting the computer, you can put the Windows Forms app
    (or one of its friends) in the startup group, and have it pass the
    information then. Of course, the Windows Forms app will have to know where
    the database is, but then someone has to start this thing!

    If the Pocket PC is connected via ActiveSync, you could have the Windows app
    put a config file into the mirrored files on the host, where it would
    automatically get synced to the PPC. The profile for the PPC would have to
    include syncing files. For example, here's where some files are that get
    synced to one of my PPC's:

    C:\Documents and Settings\Rick\My Documents\IPAQ_3650 My Documents\Business



    "Jay" <> wrote in message
    news:...
    > Hello,
    >
    > I have Windows Forms application which uses MS Access Database and a

    Pocket
    > PC application which uses Datasets, Iam trying to pass Datasets between
    > these applications using WebServices. Both these applications are shrink
    > wrapped so they need to perform with little user configuration
    >
    > WebService/IIS is running on the computer having the Windows Application

    and
    > Pocket PC connectss to the webservice through Active Sync.
    >
    > Iam trying to accomplish following task and am breaking my head over it-
    >
    > 1. How does the Webservice know where the MS Access Database is present.

    ie
    > How will the windows application let webservice know the location of the

    MS
    > Access database?
    > * I thought of registry but WebService might not have permission to read
    > it.
    > * I thought of saving an xml file in wwwroot but it could be read only.
    > * Web.config solution is not possible because end user is not very

    computer
    > savvy, so every time MS Access database changes its path Web.config needs

    to
    > chnage.
    > * Finally I thought of Web Cache. But evertime user restarts his computer
    > cache might get over written.
    > Any other workable suggestions?
    >
    > 2. When application starts up in the pocket pc, how will it find the name

    of
    > the host computer to get to the location of the webservice? Since the
    > client's computer name is not known in advance, can pocket pc application
    > find it other than entering the name manually.
    >
    > Thanks a lot.
    > Jay
    >
    >
     
    Rick Spiewak, May 26, 2004
    #3
  4. Hi Jay,

    Let me restate to clarify,
    You are developing two applications, one WinForms and one Pocket PC that
    both need to connect to the same database. The database will be located on
    the client desktop. You also are trying to use a Web Services to connect to
    the database where the Web Service is running on the desktop.

    Let me first start by questioning your use of Web Services on a client
    desktop that needs to be easily configured. Obviously I don't know your
    exact situation, however, deploying .NET Web Services to each client will as
    you know require IIS to be setup and configured. This alone sounds to
    increase the complexity for end users and for the most part(in my opinion) I
    would say IT would not want IIS running on all the end user desktops.

    Too the questions:
    How does the Web Service know where the database is?
    In this situation, I would suggest the web.config. You could utilize the
    Web Cache to facilitate a slightly faster lookup of the connection string,
    however, the cache needs to still be loaded from some place. Again the
    web.config should suffice. The problem I assume you are running into is
    that you are having the WinForm directly conect to the database and the
    PocketPC connect to the Web Service thererfore having to manage the database
    connection string in two places.

    One option is to have the WinForms app point to the Web Service as well.
    However, this may not give you the performance you are looking for.
    Another option is build a single Data Layer and point the Web Service to
    that Data Layer as well as the WinForm app.

    In the end, (with out specific knowledge of your problem) I would suggest
    not using a Web Service and connecting the PocketPC directly to the database
    through ActiveSync.

    Now if this was a Server based solution my recommendations would be
    different, and most likley include Web Services. The great thing about
    using a web service is you would be able to sync the PocketPC database over
    wireless.

    Btw- You never mentioned how you were storing the data on the PocketPC. You
    mentioned Datasets, however, datasets are not going to help you when the
    PocketPC is off unless you are planning to serialize them. You may want to
    consider using SQL CE on the Pocket PC and MSDE on the Desktop. If you do
    this you can leverage the built-in replication features.

    Let me know if you need anything else,

    Tom Krueger



    "Jay" <> wrote in message
    news:...
    > Hello,
    >
    > I have Windows Forms application which uses MS Access Database and a

    Pocket
    > PC application which uses Datasets, Iam trying to pass Datasets between
    > these applications using WebServices. Both these applications are shrink
    > wrapped so they need to perform with little user configuration
    >
    > WebService/IIS is running on the computer having the Windows Application

    and
    > Pocket PC connectss to the webservice through Active Sync.
    >
    > Iam trying to accomplish following task and am breaking my head over it-
    >
    > 1. How does the Webservice know where the MS Access Database is present.

    ie
    > How will the windows application let webservice know the location of the

    MS
    > Access database?
    > * I thought of registry but WebService might not have permission to read
    > it.
    > * I thought of saving an xml file in wwwroot but it could be read only.
    > * Web.config solution is not possible because end user is not very

    computer
    > savvy, so every time MS Access database changes its path Web.config needs

    to
    > chnage.
    > * Finally I thought of Web Cache. But evertime user restarts his computer
    > cache might get over written.
    > Any other workable suggestions?
    >
    > 2. When application starts up in the pocket pc, how will it find the name

    of
    > the host computer to get to the location of the webservice? Since the
    > client's computer name is not known in advance, can pocket pc application
    > find it other than entering the name manually.
    >
    > Thanks a lot.
    > Jay
    >
    >
     
    Tom Krueger [MSFT], May 27, 2004
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. ZackS
    Replies:
    5
    Views:
    6,854
    Just an Illusion
    Jul 9, 2004
  2. SpamProof
    Replies:
    3
    Views:
    662
    SpamProof
    Dec 1, 2003
  3. dave
    Replies:
    5
    Views:
    611
    William Brogden
    Jul 17, 2004
  4. Tim Smith
    Replies:
    2
    Views:
    874
    Tim Smith
    Dec 15, 2004
  5. trint
    Replies:
    1
    Views:
    366
    trint
    Nov 21, 2006
Loading...

Share This Page