Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Report question
Message
General information
Forum:
Visual FoxPro
Category:
The Mere Mortals Framework
Title:
Miscellaneous
Thread ID:
00642033
Message ID:
00646763
Views:
23
I've duplicated everything in the data environment from the ProgMgr report but still the form gets hung. I see you don't use a bizobj for the report (except to populate the combo boxes) so I took it off my report form. The only differences other than the obvious data names are:

ProgMgr ProjTaskenvironment:
initialselectedalias in quotes, mine isn't quoted, oerrorobj = .null. where mine = (None), oparentobj = .null. where mine = .f.

ProgMgr ProjTaskenvironment object ov_...:
alias = (None) mine is v_rptentrylog, cDatabaseName=(None) mine = CBSTAX, cursorsource=h.dbf mine=lv_rptentrylog, nodataonload=.f. mine=.t.

My data environment class is rptentrylogenvironment and its data is from lv_rptentrylog which is the select statement I sent in my previous message.

My code in the Ok and Cancel buttons is similar to yours except it doesn't have the sorting capability/code

Thanks!


>Sally,
>
>>I'm following the "Setting View Parameters for Reports" instructions but I'm not getting anywhere. Even if it wasn't returning any records, it should still do something like show a blank report, no?
>
>Not necessarily, by default, if your report has no data, VFP's print preview window opens up quickly and closes down again.
>
>>I'm sure I've got everything screwed up now with this report. I know it has to do with my inexperience with business objects and data environment objects. This way of creating a report is so foreign to me. Do I need a business object on the form that asks for a date range? >
>
>You really only need a business object if you are retrieving data from the back end or updating data.
>
>Here's what I recommend...make sure the business object works properly outside the context of the report. That means, instantiate it from the Command Window and check to make sure it returns data. For example:
>
>DO SetX
>x = CREATEOBJECT("MyBusinessObject")
>** Set your view parameters here
>x.Requery()
>
>If this works fine, have you checked out the sample Project Manager application to see how I'm doing it? If not, open up ProjMgr, go to the Documents tab in the Project, and open the ProjTask.frx report. Right-click on the report, and select "Data Environment" from the shortcut menu. Next, right-click on the form's Data Environment window and select "Code" from the shortcut menu. You'll see I have code in the Data Environment's "BeforeOpenTables", "Init" and "Destroy" methods that you can look at.
>
>I'd like to help you figure this one out...Let me know what you discover!
>
>Regards,
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform