Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 237
Default Runtime error Permission Denied

Below is my code. It works on my computer but when I
tried it on another computer I get the error "Runtime
error 70. Permission Denied." and it highlights the last
code (FileCopy FileFrom, FileTo). The code is below.

Dim FileFrom As String
Dim FileTo As String

FileFrom = Worksheets(1).Range("G4").Value
FileTo = Worksheets(1).Range("G5").Value
FileCopy FileFrom, FileTo

The file paths are correct but it wont bperform the copy
to instruction. I tried to mannualy copy and paste and it
works, so why can it not programmatically do it?

Thank you

Todd Huttenstine
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 237
Default Runtime error Permission Denied

Nevermind, I got it to work. I just restarted Excel and
it solved the problem.

Todd Huttenstine


-----Original Message-----
Below is my code. It works on my computer but when I
tried it on another computer I get the error "Runtime
error 70. Permission Denied." and it highlights the last
code (FileCopy FileFrom, FileTo). The code is below.

Dim FileFrom As String
Dim FileTo As String

FileFrom = Worksheets(1).Range("G4").Value
FileTo = Worksheets(1).Range("G5").Value
FileCopy FileFrom, FileTo

The file paths are correct but it wont bperform the copy
to instruction. I tried to mannualy copy and paste and

it
works, so why can it not programmatically do it?

Thank you

Todd Huttenstine
.

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
xpath error? Runtime Error 13 type mismatch SteveM Excel Discussion (Misc queries) 1 December 4th 07 09:16 AM
Runtime error '1004' General ODBC error star_lucas New Users to Excel 0 August 29th 05 04:09 PM
Excel 2003 Macro Error - Runtime error 1004 Cow Excel Discussion (Misc queries) 2 June 7th 05 01:40 PM
Permission Denied Audrey Ng Excel Programming 1 October 1st 03 07:20 AM
Error Msg: Permission to use object denied A. Nguyen Excel Programming 4 July 14th 03 09:05 PM


All times are GMT +1. The time now is 02:40 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"