![]() |
how to prevent a bitmap from "bleeding" over two pages?
(I thought that I posted this last night but, for whatever reason, it doesn't
appear in the discussion group. So, I'm posting it, again. Sorry if this is a duplicate.) At the very end of my macro, I "Insert Picture From File." The bitmap is "inserted" at the end (after the last row) of my data. The problem is that the data can end on practically any Row (my results vary all the time) and, when the spreadsheet is printed, the printout can be anywhere from 1 to 4 pages. So when I insert the bitmap, half the bitmap might print at the bottom of page two and then the rest of it prints at the top of page three. (or it bleeds over pages 1 and 2 or pages 3 and 4, again depending upon how much data there is). I need to make sure that the whole bitmap is printed together on the same page. So, how can I "tell" the macro to insert the bitmap at the top of the next page if (and only if) it won't totally fit on the previous page? FYI, I'm not sure how often my macro executes the following (partial) command but it does exist in the macro so I'm listing it here, just in case it matters (this sets the page length to 74 lines, I think?): i = Val(lrow) / 74 Thanks. Dan (I'm a salesman, not a programmer.) |
how to prevent a bitmap from "bleeding" over two pages?
Place your graphic entirely inside a row. Since Excel usually won't split a single row over two pages, that eliminates the problem. You can grab the picture height and size the row so it is just slightly taller. The maximum row height is 409, or about the 30 to 40 normal sized rows, so graphic size should not be a problem. The "Print Selections Only" add-in, at my website, uses that technique. -- Jim Cone San Francisco, USA http://www.realezsites.com/bus/primitivesoftware "crimsonkng" wrote in message (I thought that I posted this last night but, for whatever reason, it doesn't appear in the discussion group. So, I'm posting it, again. Sorry if this is a duplicate.) At the very end of my macro, I "Insert Picture From File." The bitmap is "inserted" at the end (after the last row) of my data. The problem is that the data can end on practically any Row (my results vary all the time) and, when the spreadsheet is printed, the printout can be anywhere from 1 to 4 pages. So when I insert the bitmap, half the bitmap might print at the bottom of page two and then the rest of it prints at the top of page three. (or it bleeds over pages 1 and 2 or pages 3 and 4, again depending upon how much data there is). I need to make sure that the whole bitmap is printed together on the same page. So, how can I "tell" the macro to insert the bitmap at the top of the next page if (and only if) it won't totally fit on the previous page? FYI, I'm not sure how often my macro executes the following (partial) command but it does exist in the macro so I'm listing it here, just in case it matters (this sets the page length to 74 lines, I think?): i = Val(lrow) / 74 Thanks. Dan (I'm a salesman, not a programmer.) |
how to prevent a bitmap from "bleeding" over two pages?
On Jun 6, 10:49 pm, "Jim Cone" wrote:
Place your graphic entirely inside a row. Since Excel usually won't split a single row over two pages, that eliminates the problem. You can grab the picture height and size the row so it is just slightly taller. The maximum row height is 409, or about the 30 to 40 normal sized rows, so graphic size should not be a problem. The "Print Selections Only" add-in, at my website, uses that technique. -- Jim Cone San Francisco, USAhttp://www.realezsites.com/bus/primitivesoftware "crimsonkng" wrote in message (I thought that I posted this last night but, for whatever reason, it doesn't appear in the discussion group. So, I'm posting it, again. Sorry if this is a duplicate.) At the very end of my macro, I "Insert Picture From File." Thebitmapis "inserted" at the end (after the last row) of my data. The problem is that the data can end on practically any Row (my results vary all the time) and, when the spreadsheet is printed, the printout can be anywhere from 1 to 4 pages. So when I insert thebitmap, half thebitmapmight print at the bottom of page two and then the rest of it prints at the top of page three. (or it bleeds over pages 1 and 2 or pages 3 and 4, again depending upon how much data there is). I need to make sure that the wholebitmapis printed together on the same page. So, how can I "tell" the macro to insert thebitmapat the top of the next page if (and only if) it won't totally fit on the previous page? FYI, I'm not sure how often my macro executes the following (partial) command but it does exist in the macro so I'm listing it here, just in case it matters (this sets the page length to 74 lines, I think?): i = Val(lrow) / 74 Thanks. Dan (I'm a salesman, not a programmer.) Fantastic idea! Thanks, Jim! |
how to prevent a bitmap from "bleeding" over two pages?
You are welcome. It was Leo Heuser, I believe, who came with the idea originally. -- Jim Cone San Francisco, USA http://www.realezsites.com/bus/primitivesoftware wrote in message Fantastic idea! Thanks, Jim! |
All times are GMT +1. The time now is 04:04 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com