Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Excel Positioning of Forms, Graphics etc different on another PC

Status
Not open for further replies.

hofburg

MIS
Feb 15, 2002
27
AT
Hi all,
I have an Excel (2010) sheet where I have graphics and forms drawn and positioned by VBA, like:

ActiveSheet.Shapes.AddShape(msoShapeRectangle, posleft, 115, 90#, boxsize). _
Select

Posleft and boxsize are calculated, as each next form has to be positioned farther to the right. Everything works fine for me.

However, when I give the file to a colleague and he opens it on his PC, all forms and graphics are slightly different in size and position. Not only on the Screen, but also when printed.

Both PCs are of the same type,set up from the same image. We print on the same printer.

Is there a way of having the object have the same size & position on different PCs, as the only purpose of this sheet is exactly that: having particular objects positioned correctly.

Thanks for help.
 
hi,

Make sure that the size & move properties are such that the size and postition do not change as row or column size changes.

Skip,
[sub]
[glasses]Just traded in my old subtlety...
for a NUANCE![tongue][/sub]
 
Hi Skip,
obviously this property (Selection.Placement = xlFreeFloating) has to be set explicitly - if not, then the opposite (xlMoveAndSize) is the default. However, even with this property set, thr result remains the same.
My procedure explicitly sets page size, margins, columns width and row height before drawing the objects (sorry - shapes, not forms).

Just made a test with an excel sheet with no macros:
Papersize is A4 (210 mm wide), left & right margins set to 10mm.
There is only one column, as wide as the paper at my disposal: it states 94,14 (854 Pixel)
In that column I put 4 rectangles, 4,4 cm wide, side by side, so as to just fit on one page.

When opened on another PC, the margins remain the same, the column shows as 94,14 (664 Pixel-?). The three left rectangles remain 4,4 cm wide, the rightmost shows as only 3,98 cm wide and a part of it jumps to a 2nd page. Only when reduced to 3,9 cm, everything fits on one page.

No problem with the lenght, i.e. height of the objects though.

Any idea? Many thanks anyway...
 
This sort of thing is usually a result of the other PC having dirrerent a printer/driver setting.

Consider using a Print Setup of ONE PAGE WIDE, for instance.

Skip,
[sub]
[glasses]Just traded in my old subtlety...
for a NUANCE![tongue][/sub]
 
Dear Skip,
thank you for your kind assistance.

I also thought about print setup. I have my two test PCs share the same network printer and use the same driver, downloaded from the server. "One page wide" was not set though.

With this setting, the sheet looks and prints the same on the "original" PC. On the second one, the rightmost rectangle remains narrower. The sheet prints on one page, but then the right margin is bigger and the entire content about 10-15% shorter.

Since both PCs have Adobe Acrobat installed I set AdobePDF as default printer on both. No change. I still can't get the sheet look the same on the two PCs.

Whatever controlls this behaviour seems well hidden in the background... Obviously the strenghts of Excel are in other areas.

Regards,
 
I had a similar problem on my personal laptop, using Vista/Excel 2007. Oddly enough, I have never had a similar problem on my work laptop or desktop VP/Excel 2007.

Here's what I did to solve a similar issue. I had to use the CAMERA Feature on the sheet with the shapes, putting the PICTURE on a separate sheet. The I printed the sheet containing the PICTURE.

I'd put the Camera icon in your QAT. When you CUSTOMIZE the QAT, Seartch thru ALL COMMANDS, for CAMERA.

Skip,
[sub]
[glasses]Just traded in my old subtlety...
for a NUANCE![tongue][/sub]
 
It may be due to some of the application-specific settings being different on the two PCs. For example, whether 'high quality mode for graphics' or 'scale content for A4/letter paper sizes' is checked.

Cheers
Paul Edstein
[MS MVP - Word]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top