Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default print a chart in another workbook without opening the workbook?


Is it possible to print a chart which is in another workbook withou
opening that other workbook?

at the moment i have

Set snagworkbook = Workbooks.Open("Snagging List - 1.xls", False
True)
snagworkbook.Charts("Snag Graph").Select
snagworkbook.Charts("Snag Graph").Select
snagworkbook.Charts("Snag Graph").PrintOut
snagworkbook.Close False

this is kinda slow due to the network (im running this macro for 1
files to print 10 graphs), and even though I hav
application.screenupdating set to false, you can also still see th
file being opened and closed on the screen.

thank

--
neowo
-----------------------------------------------------------------------
neowok's Profile: http://www.excelforum.com/member.php...nfo&userid=594
View this thread: http://www.excelforum.com/showthread.php?threadid=50670

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,600
Default print a chart in another workbook without opening the workbook?

Strange - for me with screenupdating disabled I don't see the file being
opened & closed. But to answer your question I'm pretty sure it's not
possible to print a chart from a closed workbook. In theory you could
extract the chart data from cells from a closed workbook, create a new chart
etc but quite a lot of work.

Try commenting the two select lines which are not necessary.

If needs must you could open your file in a new invisible instance

dim xlApp as excel.application
set xlApp = CreateObject("Excel.application")

Set snagworkbook = xlApp.Workbooks.Open("Snagging List - 1.xls", False,
True)
snagworkbook.Charts("Snag Graph").PrintOut
snagworkbook.Close False

set snagworkbook = Nothing
xlApp.quit
set xlApp = nothing

Regards,
Peter T

"neowok" wrote in
message ...

Is it possible to print a chart which is in another workbook without
opening that other workbook?

at the moment i have

Set snagworkbook = Workbooks.Open("Snagging List - 1.xls", False,
True)
snagworkbook.Charts("Snag Graph").Select
snagworkbook.Charts("Snag Graph").Select
snagworkbook.Charts("Snag Graph").PrintOut
snagworkbook.Close False

this is kinda slow due to the network (im running this macro for 10
files to print 10 graphs), and even though I have
application.screenupdating set to false, you can also still see the
file being opened and closed on the screen.

thanks


--
neowok
------------------------------------------------------------------------
neowok's Profile:

http://www.excelforum.com/member.php...fo&userid=5940
View this thread: http://www.excelforum.com/showthread...hreadid=506704



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Print workbook without opening it Brettjg Excel Discussion (Misc queries) 9 May 15th 07 11:28 PM
Print Chart in Shared Workbook Paul. Excel Discussion (Misc queries) 1 December 6th 04 11:47 PM
How to make the opening of a workbook conditional upon the opening of another workbook Marcello do Guzman Excel Programming 1 December 16th 03 06:09 AM
How to make opening of workbook conditional of opening of another workbook turk5555[_2_] Excel Programming 2 December 15th 03 11:07 PM
Preventing opening workbook inside active workbook. Serge[_4_] Excel Programming 2 November 4th 03 07:51 PM


All times are GMT +1. The time now is 10:55 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"