If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
Copy, Paste, Hide
Hello all,
Using Access ’03… I have some VBA code that copies an mdb from one directory to another; e.g.: FileCopy SourceFile, DestinationFile (where both are defined in previous code) When the file is copied to the destination, I’d like its attribute to be hidden. Can I do this in code? Thanks, alex |
#2
|
|||
|
|||
Copy, Paste, Hide
SetAttr "C:\Folder\File.mdb", GetAttr("C:\Folder\File.mdb") Or vbHidden
-- Doug Steele, Microsoft Access MVP http://I.Am/DougSteele (no e-mails, please!) "alex" wrote in message ... Hello all, Using Access ’03… I have some VBA code that copies an mdb from one directory to another; e.g.: FileCopy SourceFile, DestinationFile (where both are defined in previous code) When the file is copied to the destination, I’d like its attribute to be hidden. Can I do this in code? Thanks, alex |
#3
|
|||
|
|||
Copy, Paste, Hide
On Jul 9, 7:12*am, "Douglas J. Steele"
wrote: SetAttr "C:\Folder\File.mdb", GetAttr("C:\Folder\File.mdb") Or vbHidden -- Doug Steele, Microsoft Access MVPhttp://I.Am/DougSteele (no e-mails, please!) "alex" wrote in message ... Hello all, Using Access ’03… I have some VBA code that copies an mdb from one directory to another; e.g.: FileCopy SourceFile, DestinationFile (where both are defined in previous code) When the file is copied to the destination, I’d like its attribute to be hidden. Can I do this in code? Thanks, alex Works perfectly Doug. Thanks for your help. alex |
#4
|
|||
|
|||
Copy, Paste, Hide
"alex" wrote in message
... SetAttr "C:\Folder\File.mdb", GetAttr("C:\Folder\File.mdb") Or vbHidden Works perfectly Doug. Thanks for your help. Of course, you realize that hidden files can be easily viewed by changing the settings in Windows Explorer. -- Doug Steele, Microsoft Access MVP http://I.Am/DougSteele (no e-mails, please!) |
#5
|
|||
|
|||
Copy, Paste, Hide
On Jul 9, 10:49*am, "Douglas J. Steele"
wrote: "alex" wrote in message ... SetAttr "C:\Folder\File.mdb", GetAttr("C:\Folder\File.mdb") Or vbHidden Works perfectly Doug. *Thanks for your help. Of course, you realize that hidden files can be easily viewed by changing the settings in Windows Explorer. -- Doug Steele, Microsoft Access MVPhttp://I.Am/DougSteele (no e-mails, please!) I did know that. Most/all of my users have not changed that setting. Besides, hiding the file is a nice-to-have; they'll be using it, but not directly. alex |
Thread Tools | |
Display Modes | |
|
|