Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Clear
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire de rapports & Rapports
Titre:
Re: Clear
Versions des environnements
Visual FoxPro:
VFP 9
OS:
Windows XP
Database:
Visual FoxPro
Divers
Thread ID:
01334444
Message ID:
01334458
Vues:
12
Generally when that happens it's because the recordsource is no longer there. If you are recreating "mycur" anywhere, you need to be sure and set the thisform.grid2.reccrodsource property again.

This might help:

thisform.grid2.SetFocus()
Select xxxxx from yyy where zzzz into cursor curReport && CurReport will drive the report
REPORT FORM rept1
thisform.grid2.RecordSource="mycur"
thisform.grid2.SetFocus()
tisform.grid2.Refresh()


>After i run the report, the grid disappearing ? i want to keep it include information after i run the report
>
>thanks
>
>>>i need to print what i have at the gride when i run the code, and keep it
>>
>>I'm confused about the question.
>>
>>After you run the report, is the grid still appearing empty? Is that what you want to keep?
>>Or is it the data from the SELECT statement that you want to keep?
>>Or is everything working, but in the grid you are on wrong record after report?
>>
>>
>>
>>>thank you,
>>>this code works fine,no errors
>>>
>>>i want to show you what i need ,
>>>
>>>i need to print what i have at the gride when i run the code, and keep it
>>>
>>>thanks
>>>
>>>
>>>
>>>>Are you trying to tell me something? Please understand that I am not interested in finding errors in your code by trying to analyze it. But I am interested in making you a better programmer by giving you hints on how to do things the best way.
>>>>
>>>>First try my way, and if you don't get it to work, you can ask specific questions. Your code to start he report should be something like this
>>>>thisform.grid2.SetFocus()
>>>>Select xxxxx from yyy where zzzz into cursor curReport && CurReport will drive the report
>>>>REPORT FORM rept1 preview
>>>>
>>>>
>>>>>thank you for reply,
>>>>>
>>>>>
>>>>>If Seek(ALLTRIM(thisform.text8.value), "X2", "f1")
>>>>>      local lcFind
>>>>>      thisform.text5.Value=f1
>>>>>  Store F4 to lcFind, thisform.text9.value
>>>>>     SELECT F5,f3,f2,f1 FROM x2 WHERE f4=m.lcFind;
>>>>>     order BY f5;
>>>>>     into CURSOR mycur NOFILTER
>>>>>
>>>>>thisform.grid2.Visible=.t.
>>>>>  thisform.text7.value = Reccount()
>>>>>  thisform.grid2.RecordSource="mycur"
>>>>>
>>>>>
>>>>>i run the report as via command button
>>>>>
>>>>> thisform.grid2.SetFocus()
>>>>>  REPORT FORM rept1 preview
>>>>>
>>>>>
>>>>>
>>>>>>>hi all,
>>>>>>>
>>>>>>>any help to keep all grids have information after i run the
>>>>>>>
>>>>>>>REPORT FORM rept1 preview
>>>>>>>
>>>>>>>thanks
>>>>>>
>>>>>>Don't run the report from the same cursors. Instead you run a separate SQL select statement to create a cursor which drives the cursor.
ICQ 10556 (ya), 254117
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform