.head 6 - Call VpePrint( hDoc, 950, 1050 + nY * 750 / nYR, s )
.head 6 - Set nY = nY + 2
.head 5 - Set nY = 1850
.head 5 - Set s = "[S 14]The three graphs together consist of " || SalNumberToStrX( nSegments, 0 ) || " (number determined during runtime) single lines!
.head 5 - Set y = VpeWrite( hDoc, 200, 1100, 1800, VFREE,
"VPE supports 21 barcode types. Barcodes can be rotated in 90 degree steps, the text can be drawn on bottom or top of the barcode, and also independently the add-on text. Any of these features can be combined." )
.head 5 - !
.head 5 - Set y = VpePrint(hDoc, 500, y+100, "[S 24 U C LtYellow]Text and images")
.head 5 - Call VpePrint(hDoc, VRIGHT, VBOTTOM, "[Rot 900 C Blue] can be freely ")
.head 5 - Call VpeWriteBox(hDoc, 500, VBOTTOM, VLEFT, VFREE, "[Rot 1800 C Red CE]rotated in 90")
.head 5 - !
.head 5 - ! The WIDTH (after rotation it's the height) is the top of the last inserted text
.head 5 - ! minus the bottom of the first inserted object.
.head 5 - Call VpeWriteBox(hDoc, 400, y, -(VpeGet(hDoc, VTOP) - y), VFREE, "[Rot 2700 C Green]degree steps")
.head 5 - !
.head 3 + Function: page5
.head 4 - Description:
.head 4 - Returns
.head 4 + Parameters
.head 5 - Number: hDoc
.head 4 - Static Variables
.head 4 + Local variables
.head 5 - Number: nY
.head 5 - Number: nY2
.head 5 - Number: nX
.head 5 - Number: p
.head 4 + Actions
.head 5 - Call VpePageBreak( hDoc )
.head 5 - Call VpeUseSet( hDoc, HEADLINE )
.head 5 - Set nY = VpeWriteBox( hDoc, 100, 200, 2000, -1,
"VPE is also able to manage bitmaps for you!
Place your logo wherever you want." )
.head 5 - Set nY = VpeWriteBox( hDoc, 100, nY, 1400, -1,
"[S 10 L BO IO UO] [Note: These are 256-color bitmaps, in 16-color mode it doesn't look very good)" )
.head 5 - Set nY = VpeWriteBox( hDoc, 100, nY + 50, 1400, -1,
"[N B U]VPE supports the following graphics file formats:" )
.head 6 - Call Status( 'Here no preview is shown. Also no printer-setup is done - setting of the standard printer or of your last setup in VPE is taken' )
.head 6 - Call SalDisableWindow( hWndItem )
.head 6 - Call Precision( 1 )
.head 6 - Call SalEnableWindow( hWndItem )
.head 3 + Pushbutton: pbPrecision
.head 4 - Class Child Ref Key: 0
.head 4 - Class ChildKey: 0
.head 4 - Class:
.head 4 - Property Template:
.head 4 - Class DLL Name:
.head 4 - Title: Capabilities + Precision
.head 4 - Window Location and Size
.head 5 - Left: 1.883"
.head 5 - Top: 0.119"
.head 5 - Width: 2.567"
.head 5 - Width Editable? Yes
.head 5 - Height: 0.292"
.head 5 - Height Editable? Yes
.head 4 - Visible? Yes
.head 4 - Keyboard Accelerator: (none)
.head 4 - Font Name: Default
.head 4 - Font Size: Default
.head 4 - Font Enhancement: Default
.head 4 - Picture File Name:
.head 4 - Picture Transparent Color: None
.head 4 - Image Style: Single
.head 4 - Text Color: Default
.head 4 - Background Color: Default
.head 4 + Message Actions
.head 5 + On SAM_Click
.head 6 + If gnPrecision
.head 7 - Call Status( 'Precision test is already running' )
.head 6 + Else
.head 7 - Call Status( 'The window titled \'VPE\' is the application\'s main window. It\'s content is an embedded window from the VPE-DLL!!! ' ||
.head 7 - Call Status( 'A demonstration of VPE\'s graphing capabilities will appear in the main window. The calculations take a short time. Once computed, VPE can display the graph incredibly fast.' )
.head 7 - Call Graph( )
.head 7 - Call SalEnableWindow( pbCloseGraph )
.head 3 + Pushbutton: pbCloseGraph
.head 4 - Class Child Ref Key: 0
.head 4 - Class ChildKey: 0
.head 4 - Class:
.head 4 - Property Template:
.head 4 - Class DLL Name:
.head 4 - Title: Close
.head 4 - Window Location and Size
.head 5 - Left: 4.633"
.head 5 - Top: 0.786"
.head 5 - Width: 0.767"
.head 5 - Width Editable? Yes
.head 5 - Height: 0.238"
.head 5 - Height Editable? Yes
.head 4 - Visible? Yes
.head 4 - Keyboard Accelerator: (none)
.head 4 - Font Name: Default
.head 4 - Font Size: Default
.head 4 - Font Enhancement: Default
.head 4 - Picture File Name:
.head 4 - Picture Transparent Color: None
.head 4 - Image Style: Single
.head 4 - Text Color: Default
.head 4 - Background Color: Default
.head 4 + Message Actions
.head 5 + On SAM_Create
.head 6 - Call SalDisableWindow( hWndItem )
.head 5 + On SAM_Click
.head 6 + If NOT VpeCloseDoc( gnGraph )
.head 7 - Call Status( 'Can\'t close, task \'Graphing\' is currently printing' )
.head 10 - Call SalMessageBox( 'Database connection failed. Please ensure you are using a valid combination of database name, user name and password with the rights to create a table.', 'VPE Demo Database Login', MB_Ok )
.head 11 - Call Status( 'Generating report demo data. This data will be deleted when you exit the demo. Please wait.' )
.head 11 - Call GenerateData( )
.head 11 - Set gbTableCreated = TRUE
.head 10 + Else
.head 11 - Call SalMessageBox( 'VPE Demo was unable to create the table in the database for setting up the demo data. Please ensure that the user ID has sufficient rights to create a table in the database.', 'VPE Demo CREATE TABLE failed', MB_Ok )
.head 7 + If gbTableCreated
.head 8 - Call Status( 'Creating report from the database.' )
.head 8 - Call PrintJournal( )
.head 8 - Call SalEnableWindow( pbCloseSpeed )
.head 3 + Pushbutton: pbCloseSpeed
.head 4 - Class Child Ref Key: 0
.head 4 - Class ChildKey: 0
.head 4 - Class:
.head 4 - Property Template:
.head 4 - Class DLL Name:
.head 4 - Title: Close
.head 4 - Window Location and Size
.head 5 - Left: 4.633"
.head 5 - Top: 1.143"
.head 5 - Width: 0.767"
.head 5 - Width Editable? Yes
.head 5 - Height: 0.238"
.head 5 - Height Editable? Yes
.head 4 - Visible? Yes
.head 4 - Keyboard Accelerator: (none)
.head 4 - Font Name: Default
.head 4 - Font Size: Default
.head 4 - Font Enhancement: Default
.head 4 - Picture File Name:
.head 4 - Picture Transparent Color: None
.head 4 - Image Style: Single
.head 4 - Text Color: Default
.head 4 - Background Color: Default
.head 4 + Message Actions
.head 5 + On SAM_Create
.head 6 - Call SalDisableWindow( hWndItem )
.head 5 + On SAM_Click
.head 6 + If NOT VpeCloseDoc( gnSpeed )
.head 7 - Call Status( 'Can\'t close, task \'Speed and Tables\' is currently printing' )
.head 6 + Else
.head 7 - Call SalDisableWindow( hWndItem )
.head 7 - Set gnSpeed = 0
.head 3 + Pushbutton: pbColors
.head 4 - Class Child Ref Key: 0
.head 4 - Class ChildKey: 0
.head 4 - Class:
.head 4 - Property Template:
.head 4 - Class DLL Name:
.head 4 - Title: Colors
.head 4 - Window Location and Size
.head 5 - Left: 1.883"
.head 5 - Top: 1.476"
.head 5 - Width: 2.567"
.head 5 - Width Editable? Yes
.head 5 - Height: 0.292"
.head 5 - Height Editable? Yes
.head 4 - Visible? Yes
.head 4 - Keyboard Accelerator: (none)
.head 4 - Font Name: Default
.head 4 - Font Size: Default
.head 4 - Font Enhancement: Default
.head 4 - Picture File Name:
.head 4 - Picture Transparent Color: None
.head 4 - Image Style: Single
.head 4 - Text Color: Default
.head 4 - Background Color: Default
.head 4 + Message Actions
.head 5 + On SAM_Click
.head 6 + If gnColors
.head 7 - Call Status( 'Color test is already running' )
.head 6 + Else
.head 7 - Call SalWaitCursor( TRUE )
.head 7 - Call colortest( )
.head 7 - Call SalWaitCursor( FALSE )
.head 7 - Call SalEnableWindow( pbCloseColors )
.head 3 + Pushbutton: pbCloseColors
.head 4 - Class Child Ref Key: 0
.head 4 - Class ChildKey: 0
.head 4 - Class:
.head 4 - Property Template:
.head 4 - Class DLL Name:
.head 4 - Title: Close
.head 4 - Window Location and Size
.head 5 - Left: 4.633"
.head 5 - Top: 1.5"
.head 5 - Width: 0.767"
.head 5 - Width Editable? Yes
.head 5 - Height: 0.238"
.head 5 - Height Editable? Yes
.head 4 - Visible? Yes
.head 4 - Keyboard Accelerator: (none)
.head 4 - Font Name: Default
.head 4 - Font Size: Default
.head 4 - Font Enhancement: Default
.head 4 - Picture File Name:
.head 4 - Picture Transparent Color: None
.head 4 - Image Style: Single
.head 4 - Text Color: Default
.head 4 - Background Color: Default
.head 4 + Message Actions
.head 5 + On SAM_Create
.head 6 - Call SalDisableWindow( hWndItem )
.head 5 + On SAM_Click
.head 6 + If NOT VpeCloseDoc( gnColors )
.head 7 - Call Status( 'Can\'t close, task \'color test\' is currently printing' )
.head 6 + Else
.head 7 - Call SalDisableWindow( hWndItem )
.head 7 - Set gnColors = 0
.head 3 + Pushbutton: pbReport
.head 4 - Class Child Ref Key: 0
.head 4 - Class ChildKey: 0
.head 4 - Class:
.head 4 - Property Template:
.head 4 - Class DLL Name:
.head 4 - Title: Report
.head 4 - Window Location and Size
.head 5 - Left: 1.883"
.head 5 - Top: 1.821"
.head 5 - Width: 2.567"
.head 5 - Width Editable? Yes
.head 5 - Height: 0.292"
.head 5 - Height Editable? Yes
.head 4 - Visible? Yes
.head 4 - Keyboard Accelerator: (none)
.head 4 - Font Name: Default
.head 4 - Font Size: Default
.head 4 - Font Enhancement: Default
.head 4 - Picture File Name:
.head 4 - Picture Transparent Color: None
.head 4 - Image Style: Single
.head 4 - Text Color: Default
.head 4 - Background Color: Default
.head 4 + Message Actions
.head 5 + On SAM_Click
.head 6 + If gnReport
.head 7 - Call Status( 'Report test is already running' )
.head 6 + Else
.head 7 - Call reporttest( )
.head 7 - Call SalEnableWindow( pbCloseReport )
.head 3 + Pushbutton: pbCloseReport
.head 4 - Class Child Ref Key: 0
.head 4 - Class ChildKey: 0
.head 4 - Class:
.head 4 - Property Template:
.head 4 - Class DLL Name:
.head 4 - Title: Close
.head 4 - Window Location and Size
.head 5 - Left: 4.633"
.head 5 - Top: 1.845"
.head 5 - Width: 0.767"
.head 5 - Width Editable? Yes
.head 5 - Height: 0.238"
.head 5 - Height Editable? Yes
.head 4 - Visible? Yes
.head 4 - Keyboard Accelerator: (none)
.head 4 - Font Name: Default
.head 4 - Font Size: Default
.head 4 - Font Enhancement: Default
.head 4 - Picture File Name:
.head 4 - Picture Transparent Color: None
.head 4 - Image Style: Single
.head 4 - Text Color: Default
.head 4 - Background Color: Default
.head 4 + Message Actions
.head 5 + On SAM_Create
.head 6 - Call SalDisableWindow( hWndItem )
.head 5 + On SAM_Click
.head 6 + If NOT VpeCloseDoc( gnReport )
.head 7 - Call Status( 'Can\'t close, task \'report test\' is currently printing' )
.head 3 - Background Text: This part of the VPE demo shows how VPE can be used to generate reports from a SQL database.
VPE Demo needs to connect to a database with a user ID that has the rights to create a new table. The table will be deleted upon completion of this part of the demo.
Please provide connection information. The default values are suitable for a standard SQLWindows 5.0 installation.