Storing user settings file

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Ron L

    #1

    Storing user settings file

    I have an application we are building that will be used by a number of
    different users on shared PCs. I want to be able to store a number of user
    settings in a location that is unique for each user, so that one user's
    settings do not affect another. Is there a "standard" location to store
    these files? How about a "standard" location to store a file of default
    settings if the user hasn't run the application yet?

    TIA
    Ron L



  • Herfried K. Wagner [MVP]

    #2
    Re: Storing user settings file

    "Ron L" <ronl@bogus.Add ress.com> schrieb:[color=blue]
    >I have an application we are building that will be used by a number of
    >different users on shared PCs. I want to be able to store a number of user
    >settings in a location that is unique for each user, so that one user's
    >settings do not affect another. Is there a "standard" location to store
    >these files? How about a "standard" location to store a file of default
    >settings if the user hasn't run the application yet?[/color]

    \\\
    Dim Path As String = _
    Environment.Get FolderPath( _
    Environment.Spe cialFolder.Loca lApplicationDat a _
    )
    ///

    --
    M S Herfried K. Wagner
    M V P <URL:http://dotnet.mvps.org/>
    V B <URL:http://classicvb.org/petition/>

    Comment

    • Ron L

      #3
      Re: Storing user settings file

      Herfried
      Thank you for the response. I assume that this will get the location
      for an individual user, do you know how to get one for a set of defaults, or
      should those simply be stored in the same directory as the application?

      TIA
      Ron L


      "Herfried K. Wagner [MVP]" <hirf-spam-me-here@gmx.at> wrote in message
      news:uhiY9jgZFH A.1088@TK2MSFTN GP14.phx.gbl...[color=blue]
      > "Ron L" <ronl@bogus.Add ress.com> schrieb:[color=green]
      >>I have an application we are building that will be used by a number of
      >>different users on shared PCs. I want to be able to store a number of
      >>user settings in a location that is unique for each user, so that one
      >>user's settings do not affect another. Is there a "standard" location to
      >>store these files? How about a "standard" location to store a file of
      >>default settings if the user hasn't run the application yet?[/color]
      >
      > \\\
      > Dim Path As String = _
      > Environment.Get FolderPath( _
      > Environment.Spe cialFolder.Loca lApplicationDat a _
      > )
      > ///
      >
      > --
      > M S Herfried K. Wagner
      > M V P <URL:http://dotnet.mvps.org/>
      > V B <URL:http://classicvb.org/petition/>[/color]


      Comment

      • Lebesgue

        #4
        Re: Storing user settings file

        You may want to store the settings in registry, use

        System.Windows. Forms.Applicati on.CommonAppDat aRegistry to store application
        specific settings (shared among all users)
        and System.Windows. Forms.Applicati on.UserAppDataR egistry for user-specific
        settings

        "Ron L" <ronl@bogus.Add ress.com> wrote in message
        news:euGKYegZFH A.3864@TK2MSFTN GP10.phx.gbl...[color=blue]
        > I have an application we are building that will be used by a number of
        > different users on shared PCs. I want to be able to store a number of[/color]
        user[color=blue]
        > settings in a location that is unique for each user, so that one user's
        > settings do not affect another. Is there a "standard" location to store
        > these files? How about a "standard" location to store a file of default
        > settings if the user hasn't run the application yet?
        >
        > TIA
        > Ron L
        >
        >
        >[/color]


        Comment

        • Pankaj Aggarwal

          #5
          RE: Storing user settings file

          Hi
          try to use isolated storage available in .net that is unique for every user.
          other good thing is that it acts like a harddisk space and you can even store
          files in that.

          "Ron L" wrote:
          [color=blue]
          > I have an application we are building that will be used by a number of
          > different users on shared PCs. I want to be able to store a number of user
          > settings in a location that is unique for each user, so that one user's
          > settings do not affect another. Is there a "standard" location to store
          > these files? How about a "standard" location to store a file of default
          > settings if the user hasn't run the application yet?
          >
          > TIA
          > Ron L
          >
          >
          >
          >[/color]

          Comment

          • Ron L

            #6
            Re: Storing user settings file

            Pankaj

            Thank you for the response. I am not sure what you mean by "isolated
            storage", can you elaborate on this, please?

            Ron L


            "Pankaj Aggarwal" <Pankaj Aggarwal@discus sions.microsoft .com> wrote in
            message news:7E865F05-CAE0-451C-A79C-F9CCDABE4127@mi crosoft.com...[color=blue]
            > Hi
            > try to use isolated storage available in .net that is unique for every
            > user.
            > other good thing is that it acts like a harddisk space and you can even
            > store
            > files in that.
            >
            > "Ron L" wrote:
            >[color=green]
            >> I have an application we are building that will be used by a number of
            >> different users on shared PCs. I want to be able to store a number of
            >> user
            >> settings in a location that is unique for each user, so that one user's
            >> settings do not affect another. Is there a "standard" location to store
            >> these files? How about a "standard" location to store a file of default
            >> settings if the user hasn't run the application yet?
            >>
            >> TIA
            >> Ron L
            >>
            >>
            >>
            >>[/color][/color]


            Comment

            • Herfried K. Wagner [MVP]

              #7
              Re: Storing user settings file

              "Ron L" <ronl@bogus.Add ress.com> schrieb:[color=blue]
              > I am not sure what you mean by "isolated storage", can you elaborate on
              > this, please?[/color]

              ..NET Framework Class Library -- 'System.IO.Isol atedStorage' Namespace
              <URL:http://msdn.microsoft. com/library/en-us/cpref/html/frlrfsystemiois olatedstorage.a sp>

              --
              M S Herfried K. Wagner
              M V P <URL:http://dotnet.mvps.org/>
              V B <URL:http://classicvb.org/petition/>

              Comment

              • Ron L

                #8
                Re: Storing user settings file

                Herfried

                Thank you, I will take a look at that link.

                Ron L

                "Herfried K. Wagner [MVP]" <hirf-spam-me-here@gmx.at> wrote in message
                news:%23En2zDtZ FHA.3320@TK2MSF TNGP12.phx.gbl. ..[color=blue]
                > "Ron L" <ronl@bogus.Add ress.com> schrieb:[color=green]
                >> I am not sure what you mean by "isolated storage", can you elaborate on
                >> this, please?[/color]
                >
                > .NET Framework Class Library -- 'System.IO.Isol atedStorage' Namespace
                > <URL:http://msdn.microsoft. com/library/en-us/cpref/html/frlrfsystemiois olatedstorage.a sp>
                >
                > --
                > M S Herfried K. Wagner
                > M V P <URL:http://dotnet.mvps.org/>
                > V B <URL:http://classicvb.org/petition/>[/color]


                Comment

                Working...