Home > database >  Please help eldest brother, how to give the variable assignment after defining variables?
Please help eldest brother, how to give the variable assignment after defining variables?

Time:09-30

New questions, ask everybody to help,

I built a button to click to get the window after a value comp_id (dynamic, after every open a new record, the comp_id is different,)

You should give the field after I string comp_id assignment,

But I don't know how to write the assignment to, can anyone help me? Thank!!!!!

CodePudding user response:

Don't understand

CodePudding user response:

I am a layman, may express errors, so

I want to in the PB in enterprise information window, add a print button, print which the two fields of the enterprise, comp_id, comp_name
Excuse me how to get these two dynamic value pay barcode printer?

//openport (1) open the printer port
PTK_ClearBuffer ()//clear the cache
PTK_SetDarkness (10)//set the printer to print temperature
PTK_SetPrintSpeed (4)//set the printer to print speed
PTK_SetLabelHeight (600)//set the height and clearance size of tag
PTK_SetLabelWidth (800)//set the width of the tag
PTK_DrawBarcode (350, 50, 0, "1", 2, 2, 60, 'B', 'comp_id')//print barcode
PTK_DrawTextTrueTypeW (350, 10, 40, 0, "Arial", 1, 400, 0, 0, 0, "AB", 'come_name')
//printPTK_DrawLineOr (350, 140, 200, 4)//draw lines
PTK_PrintLabel (1, 1)//set the print quantity
ClosePort ()//close port



Global variable definition:

Function Long OpenPort (OP) Library "CDFPSK. DLL
"The Function Long PTK_PrintLabel (Long number, Long cpnumber) Library "CDFPSK. DLL
"The Function Long PTK_DrawTextTrueTypeW (Long x, Long y, Long FHeight, Long FWidth, String FType, Long Fspin, Long FWeight, Long FItalic, Long FUnline, Long FStrikeOut, String id_name, String data) Library "CDFPSK. DLL
"The Function Long PTK_ClearBuffer () Library "CDFPSK. DLL
"The Function Long ClosePort () Library "CDFPSK. DLL
"The Function Long PTK_SetLabelHeight (Long lheight, Long gapH) Library "CDFPSK. DLL
"The Function Long PTK_SetLabelWidth (Long lwidth) Library "CDFPSK. DLL
"The Function Long PTK_DrawBarcode (Long px, Long py, Long pdirec, String typee, Long NarrowWidth, Long pHorizontal, Long pVertical, char ptext, String PSTR) Library "CDFPSK. DLL
"The Function Long PTK_DrawLineOr (Long px, Long py, Long plength, Long pH) Library "CDFPSK. DLL
"The Function Long PTK_SetPrintSpeed (Long speed) Library "CDFPSK. DLL
"The Function Long PTK_SetDarkness (Long darkness) Library "CDFPSK. DLL
"

CodePudding user response:

Problem has been solved, thank you,
  • Related