jinxster
asked on
Printing crviewer control by pressing one key only
Hi, I have a form (frmReport) which has one control on it (crvReport).
What I would like is when you press the "/" (Asc(47)) button the form must close and when pressing the "*" (Asc(42)) button the form must print and close.
The trouble is there is no keyboard event for the crviewer control.
What can I try?
TIA
What I would like is when you press the "/" (Asc(47)) button the form must close and when pressing the "*" (Asc(42)) button the form must print and close.
The trouble is there is no keyboard event for the crviewer control.
What can I try?
TIA
?
If you set keypreview to true on the form, you should get the form's key_press event.
Am I missing something?
If you set keypreview to true on the form, you should get the form's key_press event.
Am I missing something?
Eddy - The Crystal control only exposes the click events.
mlmcc
mlmcc
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
PAQ. no refund unless he responds
ASKER
I gave my own solution so I do not feel anyone really earned any points, sorry.
I wonder if you could put a timer on the form and have it check for a keypress through Windows API calls. I don't know how to do it but it might be possible.
mlmcc