General information
Category:
Coding, syntax & commands
>>My guess is that the file that you are trying to copy is also a file in the project (same name). The file you have is a report file (FRX) and I guess that your project structure contains this file in a sub-directory "Reports". In the project file, it stores the path relative to the base directory containing the PJX file. So it would store as:
>>
>>..\Reports\MyFile.FRX
>>
>>If the 'Reports' directory exists as a sub-directory from your project file. During execution of the built project, VFP will always use the file included in the build regardless of the path that you give. So I am guessing that the copy command is being 'hijacked' by this and the relative path is being set to your variable.
>
>I'll bet that's it. The story is that master copies of the reports are kept in a Reports folder, but in order to allow editing, each user has their own copy in a different folder. This code copies from that different folder to a temp folder in case the user has multiple instances and wants to use the same report multiple times.
>
>And this would explain why this happens, even though the Reports folder isn't in the path.
>
>Tamar
I had the same problem and tracked it down to this a number of years ago. My solution was to copy the reports to a generated name using SYS(2015) initially and save the generated report name to a user local configuration table. This way I could allow the users to edit the report and have a 'personalized' version of the report and I would then read the config table to get the name for additional edits or printing.
Previous
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only