Information générale
Catégorie:
Codage, syntaxe et commandes
Titre:
Still a problem - syntax error that occurs occassionally
here is what i have done up to this point.
Rep is a table, not a cursor. It contains a program name (rep_prg_nm) that will run a report from a separate executable. The report name. And the title of the report (rep_ds). Basically, I have a form with a list box that is filled using the rep_ds field. The user selects a report from the list box and then clicks on a print button. Below is the code in the print button where the error occurs.
I have taken out all commas, periods, quotes, slashes, dashes, etc. in the rep_ds field.
if not empty(rep.rep_prg_nm)
ThisForm.LockScreen = .T.
ThisForm.List1.RowSourceType = 0
ThisForm.List1.RowSource = ''
cReportProcedure = alltrim(rep.rep_prg_nm)
* lcRep is a separate executable for running reports. All you do is send
* it the rep record and it will run the report, select the rep table and then
* return back to here.
lcDo = "do " + lcRep + " with 'arm', .T., .T., " + ;
alltrim(str(rep.rep_pk)) + ", '" +
lcCompanyName + "', .F., .F., " + ;
lc2BillType
&lcDo
Select rep
ThisForm.List1.RowSourceType = 6
* the syntax error occurs on the following line, i cannot narrow it down to
* a specific report. a matter of fact, i can't reproduce the error on my
* machine, it just occurs every now and then.
ThisForm.List1.RowSource = 'Rep.rep_ds'
ThisForm.LockScreen = .F.
else
MessageBox("There is no program associated with this report.", 0+48+0, ;
"No Report Program Defined")
return
EndIf
Any insight. Thanks for your help in advance.
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement