Sign in to follow this  
Followers 0
erezlevi

print GUI output????

5 posts in this topic

I made the following code:

Opt("GUIOnEventMode", 1)
#include <File.au3>
#include <Array.au3>
#include <GUIconstants.au3>
#include <String.au3>
#include <FontConstants.au3>
#include <GUIConstantsEx.au3>
#include <GuiListView.au3>
#include <ListViewConstants.au3>
#include <StructureConstants.au3>
#include <WinAPI.au3>
#include <WindowsConstants.au3>
#include <IE.au3>



#Region ====================Starting a GUI================================================
$GUI=GUICreate ("ACD Skill 24 hour report",950,660,30,20)
GUISetBkColor (0xffffff,$GUI)
;GUICtrlCreatePic ("c:\tableskill.bmp",20,50,900,600)
GUICtrlCreateLabel ("hour",860,80,40,20);("שעה",860,80,40,20)
GUICtrlSetBkColor (-1,0xe0e0e0)
GUICtrlSetFont (-1,10,600,"",'Arial')
GUICtrlCreateLabel ("calls",780,80,45,20);("שיחות",780,80,45,20)
GUICtrlSetFont (-1,10,600,"",'Arial')
GUICtrlCreateLabel ("ACD",783,100,45,20);("ACD",783,100,45,20)
GUICtrlSetFont (-1,10,600,"",'Arial')
GUICtrlCreateLabel ("Average speed",705,80,60,20);("זמן מענה",705,80,60,20)
GUICtrlSetFont (-1,10,600,"",'Arial')
guictrlcreatelabel ("of answer",715,100,45,20);("ממוצע",715,100,45,20)
GUICtrlSetFont (-1,10,600,"",'Arial')


GUISetOnEvent($GUI_EVENT_CLOSE, '_exit')
GUISetState ()
while True
    sleep (2000)
WEnd



#EndRegion ================================================================================
Func _exit()
    Exit
EndFunc   ;==>_exit

how can I make a "print" button, I know how to make a button, but how do I send this page (GUI) to the printer to print it?

Share this post


Link to post
Share on other sites



You should search the forums before posting your question. There are several printing udfs on the forum that I have seen.


[font="Verdana"] [size="2"]"[/size][/font]Failure is not an option -- it comes packaged with Windows"[font="Verdana"][size="2"] Gecko Web Browser[/size][/font][font="Verdana"][size="2"], [/size][/font][font="Verdana"][size="2"]Yahtzee![/size][/font][font="Verdana"][size="2"], Toolbar Launcher (like RocketDock)[/size][/font][font="Verdana"][size="2"]Internet Blocker, Simple Calculator, Local Weather, Easy GDI+ GUI [/size][/font][font="Verdana"][size="2"]Triangle Solver, TCP File Transfer, [/size][/font][font="Verdana"][size="2"]Valuater's Autoit Wrappers[/size][/font][font="Verdana"][size="3"][size="2"][size="2"]OOP In AutoIt[/size][/size][/size][/font][font="Verdana"][size="2"][size="1"]Using Windows XP SP3, 1GB RAM, AMD Athlon Processor @ 2.1 GHzCheck me out at gadgets.freehostrocket.com[/size][/size][/font]

Share this post


Link to post
Share on other sites

You should search the forums before posting your question. There are several printing udfs on the forum that I have seen.

well I am very sorry about that, I did search before I posted and all the print UDFs are about printing files. no GUI output.

so anyone else please.

Share this post


Link to post
Share on other sites

How about use the _ScreenCapture_Capture() on the area of your GUI when

Print Button is pressed then print that image?

I know this is not the correct one but just a workaround/suggestion.


[font="Palatino Linotype"][size="2"]*** The information contained in this post should be considered and certified WORKS ON MY MACHINE ***[/size][/font][font="Palatino Linotype"][size="2"] [/size][/font]

Share this post


Link to post
Share on other sites

Thats perfect!!!! Thanks!

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0