Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
runtime err 76 on some laptops
on some laptops the following fails with a 76 run time eror on the copyfolder
line Set FsO = CreateObject("Scripting.FileSystemObject") sourceFolder = "CMA_Camera_Pictures" destFolder = "C:\CRISNET\EXPORT\CMA_Camera_Pictures" FsO.CopyFolder sourceFolder, destFolder, True in all cases, C:\CRISNET\EXPORT already exists. Anyone have any ideas? |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
runtime err 76 on some laptops
Marvin, are you certain the source folder "CMA_Camera_Pictures" always exists? "Marvin" wrote: on some laptops the following fails with a 76 run time eror on the copyfolder line Set FsO = CreateObject("Scripting.FileSystemObject") sourceFolder = "CMA_Camera_Pictures" destFolder = "C:\CRISNET\EXPORT\CMA_Camera_Pictures" FsO.CopyFolder sourceFolder, destFolder, True in all cases, C:\CRISNET\EXPORT already exists. Anyone have any ideas? |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
runtime err 76 on some laptops
Yes it always exists. What I discovered is that this error occurs when the
user has autorun turned off and then tries to run the installation spreadsheet manually. Since I did not know the path of the CD/DVD drive spec on everyone's machine I left it out of the path name. Apparently when the installation spreadsheet is not run from the autorun file, the copyfolder command fails. I am not sure why this happens since the default drive is selected by the user to get to the installation program so I would think that this would not be a problem. "Bill Pfister" wrote: Marvin, are you certain the source folder "CMA_Camera_Pictures" always exists? "Marvin" wrote: on some laptops the following fails with a 76 run time eror on the copyfolder line Set FsO = CreateObject("Scripting.FileSystemObject") sourceFolder = "CMA_Camera_Pictures" destFolder = "C:\CRISNET\EXPORT\CMA_Camera_Pictures" FsO.CopyFolder sourceFolder, destFolder, True in all cases, C:\CRISNET\EXPORT already exists. Anyone have any ideas? |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
runtime err 76 on some laptops
Unfortunately, I don't know all the implications of autorunning, but you
should be able to determine the absolute path by writing some detective routines that leverage other aspects of the FileSystemObject object. GetAbsolutePathName on the source folder should allow you to catch the error immediately. You can then use the Drives and DriveType properties to narrow the list of CD drives (if the machines are all undocked laptops, the probability of multiple cd/dvd drives is reasonably low). If they are docked (which is something you can programmatically confirm), then you can search for drives with media present. Once the drives are determined (if you're lucky, there is only one), you can search the drives for specific media/files. "Marvin" wrote: Yes it always exists. What I discovered is that this error occurs when the user has autorun turned off and then tries to run the installation spreadsheet manually. Since I did not know the path of the CD/DVD drive spec on everyone's machine I left it out of the path name. Apparently when the installation spreadsheet is not run from the autorun file, the copyfolder command fails. I am not sure why this happens since the default drive is selected by the user to get to the installation program so I would think that this would not be a problem. "Bill Pfister" wrote: Marvin, are you certain the source folder "CMA_Camera_Pictures" always exists? "Marvin" wrote: on some laptops the following fails with a 76 run time eror on the copyfolder line Set FsO = CreateObject("Scripting.FileSystemObject") sourceFolder = "CMA_Camera_Pictures" destFolder = "C:\CRISNET\EXPORT\CMA_Camera_Pictures" FsO.CopyFolder sourceFolder, destFolder, True in all cases, C:\CRISNET\EXPORT already exists. Anyone have any ideas? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Runtime | Excel Discussion (Misc queries) | |||
Link 2 laptops to 1 spreadsheet with immediate updates | Links and Linking in Excel | |||
Runtime 429 | Excel Programming | |||
treeview and laptops | Excel Programming | |||
Runtime Error 424 | Excel Programming |