Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Report Form command changing alias()
Message
From
01/11/2006 16:02:53
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
01166325
Message ID:
01166374
Views:
12
The report works if run from the command window, correctly.

We are calling this report from a form. On the form, they have a choice of where the report can be sent, to the printer, to a text file, to the screen or to a pdf. With to a text file or to a pdf, they have to point to where the file is to be put and/or name the file, we have a default name, but they can change the name. that is the Putfile command. They then change their mind and say they want to send it to screen. They run the report by clicking on the "Run Report" button. This button does some checking, then selects the cursor created for this report, and goes to a case statement. The case that is for going to screen, only has one line of code, the code I stated to begin with:
   REPORT FORM (cReptFormFullName) TO PRINTER PROMPT PREVIEW
as soon it goes in, the selected cursor is changed to a different cursor then it is suppose to be on.

We try not to have any extra code in the reports, then the basic stuff that vfp report build puts in.

Did I answer all the questions?

>Beth,
>
>You need to provide a bit more info. I don't understand what are you telling about putfile, but when and how the alias changes?
>
>If you just create your table (or cursor) for the report and run it from the command window, does it work correctly?
>
>Are you calling this report from the form and experiencing the problem? Did you put alias() and dbf() in the report's title and footer to see, if they are indeed wrong?
>
>What is special about the form that calls this report?
>Finally, what is the exact code calling the report?
>
>
>
>>Hi All,
>> This is a very strange problem. It is almost like the Forms with Grids and printing reports Frequently Asked Questions #15515, but there is no grid on the form this is happening on.
>>
>>this is the line that the alias() is correct going into, but after coming out is wrong.
>>
>> REPORT FORM (cReptFormFullName) TO PRINTER PROMPT PREVIEW
>>
>>
>>when you run a putfile before hand with the same exact naming convention as the qmf_temp file used in this call. The putfile returns a qmf_temp.txt. If you name this anything else the line below works fine.
>>
>>Any Ideas?
>>
>>Thanks,
>>Beth
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform