Hi,
Can someone please help me with finding some code to print an image which is larger than the screen?
I am trying to print a black background which is exactly A4 in height and width, yet even tho i pasted an image onto the form at that size, it gets cut off by the screen Because the screen isn't big enough.
I do not necessarily need to see it on screen properly, but i require it to print a black image 210mm wide and 297mm height.
Please help, its quite urgent??
Much Appreciated,
Robert
1 1970
Hi,
Can someone please help me with finding some code to print an image which is larger than the screen?
I am trying to print a black background which is exactly A4 in height and width, yet even tho i pasted an image onto the form at that size, it gets cut off by the screen Because the screen isn't big enough.
I do not necessarily need to see it on screen properly, but i require it to print a black image 210mm wide and 297mm height.
Please help, its quite urgent??
Much Appreciated,
Robert
hi
this a nasty habbit of vb ..
try using the following code, note however that resolution is not as good as the printdoc method
you need to put a picturebox on your form (Pic1)
Flat, NoBorder
in this case Form1 is being printed, but you may use any object as long as the property hWnd exist. -
-
Declare Function SendMessage Lib "user32" Alias "SendMessageA" (ByVal hWnd As Long, ByVal wMsg As Long, ByVal wParam As Long, ByVal lParam As Long) As Long
-
-
-
-
With Form1
-
.pic1.Left = 0
-
.pic1.Top = 0
-
.pic1.Width = 12000
-
.pic1.Height = 16500
-
.pic1.AutoRedraw = True
-
.pic1.ZOrder
-
.Refresh
-
rv = SendMessage(.hWnd, &HF, .pic1.hDC, 0)
-
rv = SendMessage(.hWnd, &H317, .pic1.hDC, &H34&)
-
.pic1.Picture = .pic1.Image
-
.pic1.ZOrder
-
Printer.Orientation = 1
-
Printer.PaintPicture .pic1.Picture, 0, 400, Printer.Width, Printer.Height, 0, 0, .pic1.Width, .pic1.Height
-
Printer.EndDoc
-
-
Sign in to post your reply or Sign up for a free account.
Similar topics
by: Mario |
last post by:
I could you print jpg or bmp from the printer commands
I tried something like ;
Printer.picturepaint ("92.bmp")
printer.enddoc
Doesn't work.. I want to be able to print a logo or a picture...
|
by: Ryan Sullivan |
last post by:
I have been struggling mightily in getting this to work with the scripts
I have seen. I have an image map that uses overlib to display
information about a school's campus:
...
|
by: Geoff Cox |
last post by:
Hello,
I am trying to have
1. web pages in large font
2. web pages with smaller font for printing
I am using
<link rel="stylesheet" media="print" type="text/css"
|
by: Michael Satterwhite |
last post by:
I'm opening a page that has a single image on it. I'd like to resize the
window containing the image to the size of the image (slightly larger OK,
not smaller). The width isn't a problem, but the...
|
by: Rhino |
last post by:
I am dabbling with print CSS for the first time and I need some guidance.
The web pages on my site look fine - to my untrained eye - when displayed on
the monitor in any of the standard browsers....
|
by: abico |
last post by:
Write a program that reads in a sequence of words and prints them in
reverse order.Using STACK.
|
by: EnjoyNews |
last post by:
Hi NG
I have a site where an invoice is shown on the screen in a IFrame.
I have this script on the site:
<script type="text/javascript">
function zPrint(oTgt)
{
oTgt.focus();
oTgt.print();
}
|
by: cjparis |
last post by:
Hello everyone. If anyone can give me a hand I would be gratefull
Am doing a site which requires a moving element and have used DHTML to do it. Have a simple Browser detect script to sort IE...
|
by: studentofknowledge |
last post by:
For some unknown reason ie is placing images I have in a div in a weird way. One image is overlapping another but this problem is not occuring in mozilla. I have looked at my code over and over again...
|
by: isladogs |
last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM).
In this month's session, we are pleased to welcome back...
|
by: Vimpel783 |
last post by:
Hello!
Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
|
by: ArrayDB |
last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
|
by: PapaRatzi |
last post by:
Hello,
I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
|
by: CloudSolutions |
last post by:
Introduction:
For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
|
by: Shællîpôpï 09 |
last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
|
by: af34tf |
last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
|
by: Faith0G |
last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome former...
| |