geometrisk
New Member
- Joined
- Jul 8, 2011
- Messages
- 2
Hi <?xml:namespace prefix = o ns = "urn:schemas-microsoft-comfficeffice" /><o></o>
<o></o>
I’m having a problem with my macro. <o></o>
<o></o>
The process consists of to workbooks, “corrective action” and “corrective action oversight”, the macro saves some values from “corrective action” to “corrective action oversight”.<o></o>
<o></o>
The 2 workbooks will always be I the same folder, but may not always have the same path on all computers; therefore I used the following code:
<o></o>
<o></o>
<o>
</o>
<o></o>
<o></o>
The macro works fine when the files are on my C drive, but when they are moved to the network I get an error on the second line.<o></o>
<o></o>
If I substitute the code with the direct path on the network the macro works.
Please help <o></o>
<o></o>
I’m having a problem with my macro. <o></o>
<o></o>
The process consists of to workbooks, “corrective action” and “corrective action oversight”, the macro saves some values from “corrective action” to “corrective action oversight”.<o></o>
<o></o>
The 2 workbooks will always be I the same folder, but may not always have the same path on all computers; therefore I used the following code:
<o></o>
<o></o>
<o>
Code:
<o:p>ChDir (ActiveWorkbook.path)
Workbooks.Open Filename:="Corrective action Oversigt.xls"
</o:p>
<o></o>
<o></o>
The macro works fine when the files are on my C drive, but when they are moved to the network I get an error on the second line.<o></o>
<o></o>
If I substitute the code with the direct path on the network the macro works.
Please help <o></o>