Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Disgarding lnk files
Hello.
I am writing some VBA in excel which auto-archives files in a set of folders/subfolders. All's going well, other than when the application.filesearch command encounters a shortcut, it tries to archive the file the shortcut points to. I need to isolate the .lnk files to disregard them. I've tried to isolate the shortcuts using '.filename = "*.lnk"', but to no avail. Could anyone please tell me how to isolate them? Thanks in advance. |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Disgarding lnk files
Have u tried this: Code ------------------- .FileType = msoFileTypeExcelWorkbook ------------------- -- ilyaskaz ----------------------------------------------------------------------- ilyaskazi's Profile: http://www.excelforum.com/member.php...fo&userid=2396 View this thread: http://www.excelforum.com/showthread.php?threadid=47905 |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Disgarding lnk files
.filename like "*.lnk"
to demonstrate from the immediate window: sStr = "C:\My folder\My File.lnk" ? sStr like "*.lnk" True sStr = "C:\My folder\My File.xls" ? sStr like "*.lnk" False -- Regards, Tom Ogilvy "Les" wrote in message ... Hello. I am writing some VBA in excel which auto-archives files in a set of folders/subfolders. All's going well, other than when the application.filesearch command encounters a shortcut, it tries to archive the file the shortcut points to. I need to isolate the .lnk files to disregard them. I've tried to isolate the shortcuts using '.filename = "*.lnk"', but to no avail. Could anyone please tell me how to isolate them? Thanks in advance. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Navigating to Excel files over network slow, but not Word files | Excel Discussion (Misc queries) | |||
How can I batch convert 97-2003 .xls files to 2007 .xlsx files | Excel Discussion (Misc queries) | |||
Excel 2007 tmp files filling up drive with XLSM files | Excel Worksheet Functions | |||
How to change default Open/Files of Type to "Microsoft Excel Files | Excel Discussion (Misc queries) | |||
Drive Erased, got Files back but only excel files scrambled, help. | Excel Discussion (Misc queries) |