473,761 Members | 5,163 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

System.Drawing. Graphic.Visible ClipBounds

I have a program that prints 2 different reports and I have 2 different
printers (hp 9000, hp9050). The first report prints perfectly on both
printers. The second only prints pefectly on the 9000. On the 9050, I only
get a small square's worth in the upper left corner.

I've narrowed the problem down to the VisibleClipBoun ds(VCB) property of the
Graphic object I'm using to do the drawing. For some reason, on the second
report the VCB gets set to unusually low numbers when printing to the 9050.
I am not modifying the clip bounds on either report, so I am unsure why it
changes.

The only thing I do change is the
Graphic.PageUni t = System.Drawing. GraphicsUnit.Do cument;
however, this is the first line for both drawing functions. In the second
function, I've tried using both
Graphic.Clip.Ma keInfinite();
Graphic.ResetCl ip();
neither one seem to change the VCB

Anyone have any ideas as to why it would do this?
Nov 22 '05 #1
1 3609

I am having the same problem. Did you find a fix or workaround?

Thanks for your help.

Brett wrote:
*I have a program that prints 2 different reports and I have 2
different
printers (hp 9000, hp9050). The first report prints perfectly on
both
printers. The second only prints pefectly on the 9000. On the 9050,
I only
get a small square's worth in the upper left corner.

I've narrowed the problem down to the VisibleClipBoun ds(VCB) property
of the
Graphic object I'm using to do the drawing. For some reason, on the
second
report the VCB gets set to unusually low numbers when printing to
the 9050.
I am not modifying the clip bounds on either report, so I am unsure
why it
changes.

The only thing I do change is the
Graphic.PageUni t = System.Drawing. GraphicsUnit.Do cument;
however, this is the first line for both drawing functions. In the
second
function, I've tried using both
Graphic.Clip.Ma keInfinite();
Graphic.ResetCl ip();
neither one seem to change the VCB

Anyone have any ideas as to why it would do this? *


--
jstreit
------------------------------------------------------------------------
Posted via http://www.mcse.ms
------------------------------------------------------------------------
View this thread: http://www.mcse.ms/message1577886.html

Jun 10 '06 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
1648
by: padawan | last post by:
I have a winforms control that draws a rectangle for a boarder and positions some graphical elements around the control to create the boarder effect I desired. In the control I have overriden the onpaint event and added the code to draw my rectangle and position my graphic items: Protected Overrides Sub OnPaint(ByVal e As System.Windows.Forms.PaintEventArgs) e.Graphics.Clear(Color.FromArgb(255, 255, 255))
0
396
by: Brett | last post by:
I have a program that prints 2 different reports and I have 2 different printers (hp 9000, hp9050). The first report prints perfectly on both printers. The second only prints pefectly on the 9000. On the 9050, I only get a small square's worth in the upper left corner. I've narrowed the problem down to the VisibleClipBounds(VCB) property of the Graphic object I'm using to do the drawing. For some reason, on the second report the VCB...
9
1370
by: Oddball | last post by:
Firstly I'd like to say hello. This is my first post having ghosted for some time - I know, I'm a bad man. I'm pretty sure this following post hasn't been adressed on the forum, I may be wrong - it's quite large. Why on this earth is the following line of code causing a NullReferenceException? pfc = new PrivateFontCollection();
0
2628
by: eruess | last post by:
Here's the scenario: I've got a whole bunch (for the sake of argument, let's say thousands) of different little 32x14 .png files that act as buttons all over a very large website. Each button image has 4 transparent pixels; the upper left, upper right, lower left & lower right. This is to help give the otherwise square button graphic a slightly rounded look to it.
1
3234
by: Hadar | last post by:
Hi, I'm getting "object is currently in use elsewhere" when I use System.Drawing.Graphics.MesureString. This is what I do: My controls use a utility class the helps it to mesure strings. To get the best performance for the utility class, its members, as well as the System.Drawing.Graphics object, are static:
2
1483
by: Richard | last post by:
I each time get errors when I use an .bmp or ,.gif file as source but whenever I use a .jpg file it works perfect. Why is that? and how to fix it? I almost have no knowledge about the system.drawing and so I am in the dark about this. This is my code
13
3347
by: Metallicraft | last post by:
I have a vb6 application. On the main form is a picture box with one or two images and several pieces of text displayed in it. These are created on the fly using gdi32 routines that are all in a referenced, custom dll. I call a PrintImage routine in the dll and pass it only the the Picturebox.hdc from the main form. The dll's print routine draws to the hdc and it shows up in the picturebox perfectly. I would like to do a similar thing...
5
9889
by: Michael C# | last post by:
Hi all, I set up a System.Timers.Time in my app. The code basically just updates the screen, but since the processing performed is so CPU-intensive, I wanted to make sure it gets updated regularly; like every 1.5 secs. or so. I only ran into one issue - the MyTimer_Elapsed event handler was not updating the screen correctly all the time, often leaving large chunks of the screen un-painted for several seconds. On a whim I decided to...
3
4029
by: forest demon | last post by:
for example, let's say I do something like, System.Diagnostics.Process.Start("notepad.exe","sample.txt"); if the user does a SaveAs (in notepad), how can i capture the path that the user selects? thanks...
1
3133
by: ata | last post by:
Hi, Consider a custom control, say, MyControl that's being derived from Control. 1. How am I supposed to set the initial size of MyControl? Am I supposed to override the DefaultSize property? 2. If so, the VisibleClipBounds of the control is not actually what I've asked in the DefaultSize property, if the BorderStyle of MyControl is set to FixedSingle or Fixed3D. i.e., if the DefaultSize
0
9336
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10111
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9948
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
9902
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9765
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
6603
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5215
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
3866
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
2738
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.