FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour ERROR ON REPORT CLASS : To Josè and to All
Posts: 3107
Joined: Fri Oct 07, 2005 06:28 PM
ERROR ON REPORT CLASS : To Josè and to All
Posted: Sun Apr 17, 2011 04:22 PM
I'm trying to modify tinforme class of Josè,

viewtopic.php?f=6&t=20860&p=111880&hilit=tinforme#p111880

adding new features : It run ok but I have some problems whith these :

1) preview or print colors of titles, header, and column
2) preview or print colors of the grid
3) preview or print styles of the grid








to set the color and size and stiles I use these commands


::={"CLR_BLACK","CLR_BLUE" ,"CLR_GREEN", "CLR_CYAN" , ;
"CLR_RED" ,"CLR_MAGENTA","CLR_GRAY","CLR_HBLUE", ;
"CLR_HGREEN","CLR_HCYAN","CLR_HRED" ,"CLR_HMAGENTA", ;
"CLR_YELLOW","CLR_WHITE","CLR_HGRAY"}

::={"Nero","Azurro","Verde","Cielo","Rosso","Magenta", ;
"Grigio","Azurro Intenso","Verde Intenso","Cielo Intenso", ;
"Rosso Intenso","Magenta Intenso","Amarillo","Bianco" ,"Grigio chiaro" }



::aPenSizes := { "1", "2", "3", "4", "5" }
::aPenEstilo := { "Solido", "Linea", "Punto", "Linea punto", "Linea punto punto" }
::aPenStilos:= { "PS_SOLID","PS_DASH","PS_DOT","PS_DASHDOT","PS_DASHDOTDOT"}


...

the gets ( you see on pictures)

...

::nColore := ::aColors[ VAL(ltrim(STR(AScan( ::aclr, Trim(::acColor ))))) ]
::= ::aPenSizes[ AScan( ::aPenSizes ,::acPenSizes)]
::nPenstilo:= ::aPenStilos[ AScan(::aPenEstilo,::acPenEstilo)]




to define the colors for the Grid I use the define pen :

DEFINE PEN ::AoPen1 STYLE ::nPenstilo WIDTH val(::nPensize) COLOR ::nColore OF ::oReport

but only the size val(::nPensize) run ok I not understood why ?




for the fonts I use the same and then the commnd END REPORT I insert these lines :

END REPORT
IF ::lCreated


::SetTxtColor(::nColoreFont1,1)
::SetTxtColor(::nColoreFont2,2)
::SetTxtColor(::nColoreFont3,3)

::SetPenColor(::nColore)

endif


::nColoreFont1,::nColoreFont2,::nColoreFont3 -> CLR_XXXX


BUT IT NOT RUN

ANY IDEA ?
Best Regards, Saludos



Falconi Silvio

Continue the discussion