The problem arises when I try to use some variable from PRG i FR3 file
I can use NUMERIC variable from PRG and show it in FR3
But when I want to use STRING variable, the report crashes.
- Code: Select all Expand view RUN
cCompanyName := ALLTRIM(vcompany->TITLE)
private m_fr := frreportmanager():new()
// x = ALIAS()
// n = SELECT()
m_fr:SetWorkArea(x,n) //"xreport", n)
// Now to define which FIELDS we want to show on the report
m_fr:SetFieldAliases(x, "NAME;SSN;DATEENTER;TOTALH;TOTALL;TOTALB;BALANCEH;PAIDH;DEPARTMENT") // DEPARTMENT is only needed if we sort by DEPARTMENT
m_fr:LoadFromFile(m_pj)
m_fr:AddVariable( "MyVars", "CoName", " ' cCompanyName ' " )
//m_fr:AddVariable( "MyVars", "CoName", " ' " + cCompanyName +" ' " )
//m_fr:AddVariable( "MyVars", "CoName", cCompanyName )
m_fr:DesignReport()
m_fr:DestroyFR()
return nil
None of the above AddVAriable() works
When I drag and drop the variable "coName" the system recognizes the content but shows this error message:
As you see the company name is recognized, but some error triggers and I cannot find the problem...
If I use NUMERIC it shows perfect
Any idea?