Results 1 to 6 of 6

Thread: [RESOLVED] Admin and Guest access

  1. #1

    Thread Starter
    Member
    Join Date
    Oct 2002
    Posts
    54

    Resolved [RESOLVED] Admin and Guest access

    I have a text file I can open for Binary access when logged into XP pro as an Admin but not as a guest, which is causing problems for a corporate customer.

    I purposely stored the files in
    C:\Documents and Settings\All Users\Application Data\MyFolder\Myfile.dat
    thinking everyone has access to these folders, but I get error 75, Path/File access error.

    Can anyone please advise?

    Thank you

  2. #2
    Just Married shakti5385's Avatar
    Join Date
    Mar 2006
    Location
    Udaipur,Rajasthan(INDIA)
    Posts
    3,747

    Thumbs up Re: Admin and Guest access

    C:\Documents and Settings\All Users\Application Data\MyFolder\Myfile.dat
    This location is not correct for all the computer because there is possibility of changing the user name on the other computer. So I suggest that put the file at the desktop or in a specific drive.

  3. #3

    Thread Starter
    Member
    Join Date
    Oct 2002
    Posts
    54

    Re: Admin and Guest access

    Ok, sorry, maybe a better description of the path would have been

    C:\Documents and Settings\All Users\Application Data\AppFolder\Appfile.dat

    The users arent limited in their access to the file by way of their log-in names.

    I locate the All Users/Application folder using the Special Folders API (thanks to all who helped me there), I create the dataFolder and the file while an Administrator.

    What I need then is a Guest user allowed to read and write to the same file.

  4. #4
    Super Moderator si_the_geek's Avatar
    Join Date
    Jul 2002
    Location
    Bristol, UK
    Posts
    41,974

    Re: Admin and Guest access

    Are you trying to just read the file, or write to it aswell?

    If you are just trying to read it, specify "INPUT" in the Open line (see the help for exactly where/how to do it).

    If you want to write it too, right click on the file and ensure that the permissions allow all users to write to/modify it.

  5. #5

    Thread Starter
    Member
    Join Date
    Oct 2002
    Posts
    54

    Re: Admin and Guest access

    I think my problem was the access.

    Another programmer had specified the files for Binary Access, which worked OK if logged in as administrator but gave problems for restricted users.

    I used the usual INPUT as you suggested (and I would usually have used myself lol) and everything worked. I had assumed it was the file location giving problems and used most of the afternoon trying to find out why.

    Thanks for your help.

  6. #6
    Super Moderator si_the_geek's Avatar
    Join Date
    Jul 2002
    Location
    Bristol, UK
    Posts
    41,974

    Re: [RESOLVED] Admin and Guest access

    Good stuff.. I had a quick check and found I was thinking of the wrong word before! What I was actually thinking of was "Access Read":
    VB Code:
    1. Open "c:\TESTFILE" For Binary Access Read As #1
    ..so you can still open in Binary mode (so no need to change other code).

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width