Solved

deny a file access

Posted on 2001-09-13
7
186 Views
Last Modified: 2010-05-02
is it possible to deny a file access like we see in opened access database files .
can we implement the same idea to protect any file
thanks
jophie
0
Comment
Question by:jofykuttan
7 Comments
 
LVL 5

Accepted Solution

by:
rkot2000 earned 50 total points
ID: 6480180
you can try to use open file


Enables input/output (I/O) to a file.

Syntax

Open pathname For mode [Access access] [lock] As [#]filenumber [Len=reclength]

lock - Optional. Keyword specifying the operations restricted on the open file by other processes: Shared, Lock Read, Lock Write, and Lock Read Write.
0
 
LVL 43

Expert Comment

by:TimCottee
ID: 6481990
If you are using NTFS then you can set permissions on the file which will deny access. Otherwise you have to open the file exclusively as suggested.
0
 

Author Comment

by:jofykuttan
ID: 6622093
dear,
in fact
what i asked is
to deny access to virtually any file
like we see in Access

and is it possible it implement that logic in VB
0
Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

 
LVL 49

Expert Comment

by:DanRollins
ID: 7208363
jofykuttan, an EE Moderator will delete this for you.
Moderator, my recommended disposition is:

    DELETE this question.

DanRollins -- EE database cleanup volunteer
0
 
LVL 5

Expert Comment

by:rkot2000
ID: 7209165
Access denies access to this file because the file is open for io operations.
Opening any other file will do the same.
So I have the correct answer.
0
 
LVL 49

Expert Comment

by:DanRollins
ID: 7224049
Moderator, my recommended disposition is:

   accept rkot2000's comment as an answer

DanRollins -- EE database cleanup volunteer
0
 
LVL 5

Expert Comment

by:Netminder
ID: 7241192
Per recommendation, force-accepted.

Netminder
CS Moderator
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Controlling which port to download from 4 72
Saving history changes to sub form 4 37
VBA Shell can't Find Word document 11 77
TT Auto Dashboard 13 85
Introduction In a recent article (http://www.experts-exchange.com/A_7811-A-Better-Concatenate-Function.html) for the Excel community, I showed an improved version of the Excel Concatenate() function.  While writing that article I realized that no o…
Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

863 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now