Jump to content
Fivewin Brasil

erro de preview


neto_23

Recommended Posts

porque esse erro no relatorio do preview ?

erro (6) deleting enhanced metal file

erro description

ok

olhem a instrução

************

funct ctt3q(nqual)

*************

Local aArray,nX

local oPrn, oFont

local nRowStep, nColStep

local nRow := 0, nCol := 0, n, m

**************

pas = ' '

gr = ' '

dopa = ' '

sldant = 0

saldo = 0

cvar1:='FUNCI'+nl

cvar2:='MOVPE'+nl

cSql := "select "+cvar1+".codfu,"+cvar1+".nomfu,"+cvar1+".arqui,"+cvar1+".comis,"

cSql := cSql+cvar2+".cadcl,"+cvar2+".vende,"+cvar2+".adesa,"+cvar2+".npart,"

cSql := cSql+cvar2+".cance,"+cvar2+".comte"

cSql := cSql+" from "+cvar1+" left join "+cvar2+" on "+cvar1+".codfu "

cSql := cSql+" = "+cvar2+".vende where "+cvar1+".arqui = ' ' and "

cSql := cSql+cvar2+".dtarq between "+sqldate(dt1)+" and "+sqldate(dt2)+" order by "

cSql := cSql+cvar1+".codfu"

sele 0

use sql (cSql) alias retarqui via 'Mysql'

go top

bol1=0

metag = 0

vendag = 0

efetg = 0

elevg = 0

elefg = 0

motvg = 0

motfg = 0

carvg = 0

carfg = 0

cfuini = codfu

impini = 0

cfu = codfu

nfu = nomfu

meta = comis

bol = 0

venda = 0

eleven = 0

eleefe = 0

motven = 0

motefe = 0

carven = 0

carefe = 0

cancetotal = 0

efet = 0

**************************************************************

PRINT oPrn NAME "Arquivados por vendedor" preview

oPrn:SetPage(9) // A4

oPrn:SetPortrait() //Vertical

if Empty( oPrn:hDC )

return nil // Printer was not installed or ready

endif

DEFINE FONT oFont NAME "Courier New" SIZE 0, -9 OF oPrn

DEFINE FONT oFont2 NAME "Courier New" SIZE 0, -8 OF oPrn

DEFINE PEN oPen WIDTH 2 OF oPrn

nRowStep = oPrn:nVertRes() / 40 // We want 20 rows

nColStep = oPrn:nHorzRes() / 15 // We want 15 cols

lin := 90

nPg := 00

linl = 0

linc = 0

//page

**************************************************************

do while .t.

if lin > 56

page

npg++

oPrn:Box( 020, 020, 190, 940, open)

oPrn:Say( 040, 030, "Data:"+dtoc(date()), oFont )

oPrn:Say( 040, 400, alltrim(nemp), oFont )

oPrn:Say( 040, 790, "Pagina:"+trans(nPg,"99999"), oFont)

oPrn:Say( 070, 030, "Arquivados por vendedor", oFont)

oPrn:Say( 070, 790, "HORA : "+time(), oFont)

oPrn:Say( 100, 030, "Periodo..:"+dtoc(dt1)+" ate "+dtoc(dt2), oFont)

oPrn:Box( 130, 030, 180, 930, open)

oPrn:Say( 160, 030, "Vendedor Arquivado Eletro:(Arquivado) Moto:(Arquivado) Carro:(Arquivado)",oFont2)

* 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890

* 1 2 3 4 5 6 7 8 9 10 11 12

lin = 8

linl = 210

pas = 't'

endif

*vasco

if cance = 'A'

cancetotal++

endif

if cance = 'A'

bol = bol + 1

bol1 = bol1 + 1

venda = venda + 1

if npart = '60'

carven = carven + 1

crg = cadcl

elseif npart = '48'

motven = motven + 1

crg = cadcl

elseif npart = '24' .or. npart = '36'

eleven = eleven + 1

crg = cadcl

else

eleven = eleven + 1

crg = cadcl

endif

endif

skip

if cfuini # codfu

if venda > 0

oPrn:say(@ linl, 030, substr(nfu,1,35), oFont2)

oPrn:say(@ linl, 370, trans(venda,'99,999'), oFont2)

vendag = vendag + venda

oPrn:say(@ linl, 530, trans(eleven,'99,999'), oFont2)

elevg = elevg + eleven

elefg = elefg + eleefe

oPrn:say(@ linl, 660, trans(motven,'99,999'), oFont2)

motvg = motvg + motven

motfg = motfg + motefe

oPrn:say(@ linl, 800, trans(carven,'99,999'), oFont2)

carvg = carvg + carven

carfg = carfg + carefe

lin++

linl = linl + 25

endif

cfuini = codfu

impini = 0

cfu = codfu

nfu = nomfu

meta = comis

bol = 0

venda = 0

eleven = 0

eleefe = 0

motven = 0

motefe = 0

carven = 0

carefe = 0

efet = 0

cancetotal = 0

endif

if lin > 56

oPrn:Box( linl, 030, linl+50, 930, open)

oPrn:say( linl+30, 030, "Sistema 32 Bits CP-80 Versão.: 5.0 MYSQL xHABOUR BCC582", oFont2)

oPrn:say( linl+30, 570, "Usuário:"+alltrim(nusu), oFont2)

endpage

endif

if eof()

linl = linl + 25

oPrn:Box( linl, 030, linl+50, 930, open)

oPrn:say(@ linl, 030, "Totais:", oFont2)

oPrn:say(@ linl, 370, trans(vendag,'99,999'), oFont2)

oPrn:say(@ linl, 530, trans(elevg,'99,999'), oFont2)

oPrn:say(@ linl, 660, trans(motvg,'99,999'), oFont2)

oPrn:say(@ linl, 800, trans(carvg,'99,999'), oFont2)

linl = linl + 25

oPrn:say( linl+30, 030, "Sistema 32 Bits CP-80 Versão.: 5.0 MYSQL xHABOUR BCC582", oFont2)

oPrn:say( linl+30, 570, "Usuário:"+alltrim(nusu), oFont2)

endpage

exit

endif

enddo

endprint

oFont:end()

oFont2:end()

close retarqui

return

fw10.8harbour-xDev.70 Studio-bcc582-Mysql-Pelles

programadorcp80@hotmail.com.br ;

Link to comment
Share on other sites

porque esse erro no relatorio do preview ?

erro (6) deleting enhanced metal file

erro description

ok

olhem a instrução

************

funct ctt3q(nqual)

*************

Local aArray,nX

local oPrn, oFont

local nRowStep, nColStep

local nRow := 0, nCol := 0, n, m

**************

pas = ' '

gr = ' '

dopa = ' '

sldant = 0

saldo = 0

cvar1:='FUNCI'+nl

cvar2:='MOVPE'+nl

cSql := "select "+cvar1+".codfu,"+cvar1+".nomfu,"+cvar1+".arqui,"+cvar1+".comis,"

cSql := cSql+cvar2+".cadcl,"+cvar2+".vende,"+cvar2+".adesa,"+cvar2+".npart,"

cSql := cSql+cvar2+".cance,"+cvar2+".comte"

cSql := cSql+" from "+cvar1+" left join "+cvar2+" on "+cvar1+".codfu "

cSql := cSql+" = "+cvar2+".vende where "+cvar1+".arqui = ' ' and "

cSql := cSql+cvar2+".dtarq between "+sqldate(dt1)+" and "+sqldate(dt2)+" order by "

cSql := cSql+cvar1+".codfu"

sele 0

use sql (cSql) alias retarqui via 'Mysql'

go top

bol1=0

metag = 0

vendag = 0

efetg = 0

elevg = 0

elefg = 0

motvg = 0

motfg = 0

carvg = 0

carfg = 0

cfuini = codfu

impini = 0

cfu = codfu

nfu = nomfu

meta = comis

bol = 0

venda = 0

eleven = 0

eleefe = 0

motven = 0

motefe = 0

carven = 0

carefe = 0

cancetotal = 0

efet = 0

**************************************************************

PRINT oPrn NAME "Arquivados por vendedor" preview

oPrn:SetPage(9) // A4

oPrn:SetPortrait() //Vertical

if Empty( oPrn:hDC )

return nil // Printer was not installed or ready

endif

DEFINE FONT oFont NAME "Courier New" SIZE 0, -9 OF oPrn

DEFINE FONT oFont2 NAME "Courier New" SIZE 0, -8 OF oPrn

DEFINE PEN oPen WIDTH 2 OF oPrn

nRowStep = oPrn:nVertRes() / 40 // We want 20 rows

nColStep = oPrn:nHorzRes() / 15 // We want 15 cols

lin := 90

nPg := 00

linl = 0

linc = 0

//page

**************************************************************

do while .t.

if lin > 56

page

npg++

oPrn:Box( 020, 020, 190, 940, open)

oPrn:Say( 040, 030, "Data:"+dtoc(date()), oFont )

oPrn:Say( 040, 400, alltrim(nemp), oFont )

oPrn:Say( 040, 790, "Pagina:"+trans(nPg,"99999"), oFont)

oPrn:Say( 070, 030, "Arquivados por vendedor", oFont)

oPrn:Say( 070, 790, "HORA : "+time(), oFont)

oPrn:Say( 100, 030, "Periodo..:"+dtoc(dt1)+" ate "+dtoc(dt2), oFont)

oPrn:Box( 130, 030, 180, 930, open)

oPrn:Say( 160, 030, "Vendedor Arquivado Eletro:(Arquivado) Moto:(Arquivado) Carro:(Arquivado)",oFont2)

* 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890

* 1 2 3 4 5 6 7 8 9 10 11 12

lin = 8

linl = 210

pas = 't'

endif

*vasco

if cance = 'A'

cancetotal++

endif

if cance = 'A'

bol = bol + 1

bol1 = bol1 + 1

venda = venda + 1

if npart = '60'

carven = carven + 1

crg = cadcl

elseif npart = '48'

motven = motven + 1

crg = cadcl

elseif npart = '24' .or. npart = '36'

eleven = eleven + 1

crg = cadcl

else

eleven = eleven + 1

crg = cadcl

endif

endif

skip

if cfuini # codfu

if venda > 0

oPrn:say(@ linl, 030, substr(nfu,1,35), oFont2)

oPrn:say(@ linl, 370, trans(venda,'99,999'), oFont2)

vendag = vendag + venda

oPrn:say(@ linl, 530, trans(eleven,'99,999'), oFont2)

elevg = elevg + eleven

elefg = elefg + eleefe

oPrn:say(@ linl, 660, trans(motven,'99,999'), oFont2)

motvg = motvg + motven

motfg = motfg + motefe

oPrn:say(@ linl, 800, trans(carven,'99,999'), oFont2)

carvg = carvg + carven

carfg = carfg + carefe

lin++

linl = linl + 25

endif

cfuini = codfu

impini = 0

cfu = codfu

nfu = nomfu

meta = comis

bol = 0

venda = 0

eleven = 0

eleefe = 0

motven = 0

motefe = 0

carven = 0

carefe = 0

efet = 0

cancetotal = 0

endif

if lin > 56

oPrn:Box( linl, 030, linl+50, 930, open)

oPrn:say( linl+30, 030, "Sistema 32 Bits CP-80 Versão.: 5.0 MYSQL xHABOUR BCC582", oFont2)

oPrn:say( linl+30, 570, "Usuário:"+alltrim(nusu), oFont2)

endpage

endif

if eof()

linl = linl + 25

oPrn:Box( linl, 030, linl+50, 930, open)

oPrn:say(@ linl, 030, "Totais:", oFont2)

oPrn:say(@ linl, 370, trans(vendag,'99,999'), oFont2)

oPrn:say(@ linl, 530, trans(elevg,'99,999'), oFont2)

oPrn:say(@ linl, 660, trans(motvg,'99,999'), oFont2)

oPrn:say(@ linl, 800, trans(carvg,'99,999'), oFont2)

linl = linl + 25

oPrn:say( linl+30, 030, "Sistema 32 Bits CP-80 Versão.: 5.0 MYSQL xHABOUR BCC582", oFont2)

oPrn:say( linl+30, 570, "Usuário:"+alltrim(nusu), oFont2)

endpage

exit

endif

enddo

endprint

oFont:end()

oFont2:end()

close retarqui

return

fw10.8harbour-xDev.70 Studio-bcc582-Mysql-Pelles

programadorcp80@hotmail.com.br ;

Link to comment
Share on other sites

Um chute:

Ou voce não criou uma nova pagina.

Ou voce nao está com a PREV32.DLL desta versao.

ou voce não incoporou a TMETAFIL.PRG desta versão.

somente um chute. kkkkkkkkkkkkk, ou tres.....

João Santos - São Paulo.

kmt_karinha@pop.com.br

joao@pleno.com.br

Fone: (11) 3106-2832 / 8243-5632

FWH 2.7 - xHARBOUR WorkShop.Exe

dentinho.jpg?rnd=0.830315402649066

Link to comment
Share on other sites

kapiaba: obrigado pela ajuda!

Um chute:

Ou voce não criou uma nova pagina.?

® ( pode ser) mais tem o comand page

Ou voce nao está com a PREV32.DLL desta versao. ?

®estou com a prev32.dll, tenho certeza,

ou voce não incoporou a TMETAFIL.PRG desta versão.

® não tem esse arquivo no fwh 10.8

somente um chute. kkkkkkkkkkkkk, ou tres.....

fw10.8harbour-xDev.70 Studio-bcc582-Mysql-Pelles

programadorcp80@hotmail.com.br ;

Link to comment
Share on other sites

  • 2 weeks later...

Realmente o problema é um PAGE sem ENDPAGE. Tomei a liberdade de alterar seus códigos para que funcione. Procure onde tem "by shark" e saberás o que deve modificar no seu fonte original ok?

SharkAbraços!

lin := 8 // by shark

nPg := 00

linl = 0

linc = 0

lEndPage := .F. // by shark

lNewPage := .T. // by shark

//page

**************************************************************

do while .t.

IF lEndPage // by shark

lEndPage := .F.

lNewPage := .T.

oPrn:Box( linl, 030, linl+50, 930, open)

oPrn:say( linl+30, 030, "Sistema 32 Bits CP-80 Versão.: 5.0 MYSQL xHABOUR BCC582", oFont2)

oPrn:say( linl+30, 570, "Usuário:"+alltrim(nusu), oFont2)

endpage

ENDIF

if lNewPage // by shark lin > 56

lNewPage := .F. // by shark

page

npg++

oPrn:Box( 020, 020, 190, 940, open)

oPrn:Say( 040, 030, "Data:"+dtoc(date()), oFont )

oPrn:Say( 040, 400, alltrim(nemp), oFont )

oPrn:Say( 040, 790, "Pagina:"+trans(nPg,"99999"), oFont)

oPrn:Say( 070, 030, "Arquivados por vendedor", oFont)

oPrn:Say( 070, 790, "HORA : "+time(), oFont)

oPrn:Say( 100, 030, "Periodo..:"+dtoc(dt1)+" ate "+dtoc(dt2), oFont)

oPrn:Box( 130, 030, 180, 930, open)

oPrn:Say( 160, 030, "Vendedor Arquivado Eletro:(Arquivado) Moto:(Arquivado) Carro:(Arquivado)",oFont2)

* 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890

* 1 2 3 4 5 6 7 8 9 10 11 12

lin = 8

linl = 210

pas = 't'

endif

*vasco

if cance = 'A'

cancetotal++

endif

if cance = 'A'

bol = bol + 1

bol1 = bol1 + 1

venda = venda + 1

if npart = '60'

carven = carven + 1

crg = cadcl

elseif npart = '48'

motven = motven + 1

crg = cadcl

elseif npart = '24' .or. npart = '36'

eleven = eleven + 1

crg = cadcl

else

eleven = eleven + 1

crg = cadcl

endif

endif

skip

if cfuini # codfu

if venda > 0

oPrn:say(@ linl, 030, substr(nfu,1,35), oFont2)

oPrn:say(@ linl, 370, trans(venda,'99,999'), oFont2)

vendag = vendag + venda

oPrn:say(@ linl, 530, trans(eleven,'99,999'), oFont2)

elevg = elevg + eleven

elefg = elefg + eleefe

oPrn:say(@ linl, 660, trans(motven,'99,999'), oFont2)

motvg = motvg + motven

motfg = motfg + motefe

oPrn:say(@ linl, 800, trans(carven,'99,999'), oFont2)

carvg = carvg + carven

carfg = carfg + carefe

lin++

linl = linl + 25

endif

cfuini = codfu

impini = 0

cfu = codfu

nfu = nomfu

meta = comis

bol = 0

venda = 0

eleven = 0

eleefe = 0

motven = 0

motefe = 0

carven = 0

carefe = 0

efet = 0

cancetotal = 0

endif

if lin > 56 // by shark

lEndPage := .T. // by shark

// by shark

//oPrn:Box( linl, 030, linl+50, 930, open)

//oPrn:say( linl+30, 030, "Sistema 32 Bits CP-80 Versão.: 5.0 MYSQL xHABOUR BCC582", oFont2)

//oPrn:say( linl+30, 570, "Usuário:"+alltrim(nusu), oFont2)

//endpage

endif

if eof()

IF lEndPage // by shark

oPrn:Box( linl, 030, linl+50, 930, open)

oPrn:say( linl+30, 030, "Sistema 32 Bits CP-80 Versão.: 5.0 MYSQL xHABOUR BCC582", oFont2)

oPrn:say( linl+30, 570, "Usuário:"+alltrim(nusu), oFont2)

endpage

page

npg++

oPrn:Box( 020, 020, 190, 940, open)

oPrn:Say( 040, 030, "Data:"+dtoc(date()), oFont )

oPrn:Say( 040, 400, alltrim(nemp), oFont )

oPrn:Say( 040, 790, "Pagina:"+trans(nPg,"99999"), oFont)

oPrn:Say( 070, 030, "Arquivados por vendedor", oFont)

oPrn:Say( 070, 790, "HORA : "+time(), oFont)

oPrn:Say( 100, 030, "Periodo..:"+dtoc(dt1)+" ate "+dtoc(dt2), oFont)

oPrn:Box( 130, 030, 180, 930, open)

oPrn:Say( 160, 030, "Vendedor Arquivado Eletro:(Arquivado) Moto:(Arquivado) Carro:(Arquivado)",oFont2)

* 1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890

* 1 2 3 4 5 6 7 8 9 10 11 12

lin = 8

linl = 210

lEndPage := .F.

ENDIF

linl = linl + 25

oPrn:Box( linl, 030, linl+50, 930, open)

oPrn:say(@ linl, 030, "Totais:", oFont2)

oPrn:say(@ linl, 370, trans(vendag,'99,999'), oFont2)

oPrn:say(@ linl, 530, trans(elevg,'99,999'), oFont2)

oPrn:say(@ linl, 660, trans(motvg,'99,999'), oFont2)

oPrn:say(@ linl, 800, trans(carvg,'99,999'), oFont2)

linl = linl + 25

oPrn:say( linl+30, 030, "Sistema 32 Bits CP-80 Versão.: 5.0 MYSQL xHABOUR BCC582", oFont2)

oPrn:say( linl+30, 570, "Usuário:"+alltrim(nusu), oFont2)

IF !lEndPage // by shark

endpage

ENDIF

exit

endif

enddo

endprint

oFont:end()

oFont2:end()

close retarqui

return

Shark - FWH 8.09 / xharbour 1.1.0 / xMate 1.15 / Resource WorkShop

figura21fd4.jpg

http://www.superdownloads.com.br/download/41/programa-de-auto-escola-automax/

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...