Open a doc, grab a range without having the whole doc being tabled
Author |
Message |
Mark #1 / 7
|
 Open a doc, grab a range without having the whole doc being tabled
Is it possible to open a doc with VBA code from another doc and then get some bookmark.ranges, without having to wait for the whole doc being build? I want to open each doc in a directory and then grab the bookmark.ranges, print them, and close the doc's again. ( and here comes the problem!! ) But because the doc's have got a lot of pages with a whole lot of tables in them, waiting seems like forever. So, is there anybody that has got a suggestion in which way I have got to proceed. Thx, Mark G
|
Wed, 05 Nov 2003 02:16:53 GMT |
|
 |
Mark Tangar #2 / 7
|
 Open a doc, grab a range without having the whole doc being tabled
Mark, Is it because the tables are linked to another source and the waiting for the document to be "built" is because those links are updated when the file is opened? If so, could you solve it just by clearing the Update Automatic Links At Open option (in Tools-> Options-> General), either manually or -- maybe best -- programmatically & then returning it to its original setting at the end of the macro?
------ WWW: http://www.speakeasy.org/~mtangard ---------------------- ------------- "Life is nothing if you aren't obsessed." --John Waters --------------------------------------------------------------------- Quote:
> Is it possible to open a doc with VBA code from another doc and then get > some bookmark.ranges, without having to wait for the whole doc being build? > I want to open each doc in a directory and then grab the bookmark.ranges, > print them, and close the doc's again. > ( and here comes the problem!! ) > But because the doc's have got a lot of pages with a whole lot of tables in > them, waiting seems like forever. So, is there anybody that has got a > suggestion in which way I have got to proceed. > Thx, > Mark G
|
Wed, 05 Nov 2003 07:14:41 GMT |
|
 |
Jonathan Wes #3 / 7
|
 Open a doc, grab a range without having the whole doc being tabled
Hi Mark, Not really. If the document takes a long time to open, it just takes a long time. You might be able to make things go a bit quicker if the document is currently on a network drive. Try copying it to the C drive and opening it there. That sometimes makes things go faster. -- Regards Jonathan West - Word MVP MultiLinker - Automated generation of hyperlinks in Word Conversion to PDF & HTML http://www.multilinker.com Word FAQs at http://www.multilinker.com/wordfaq Please post any follow-up in the newsgroup. I do not reply to Word questions by email
Quote: > Is it possible to open a doc with VBA code from another doc and then get > some bookmark.ranges, without having to wait for the whole doc being build? > I want to open each doc in a directory and then grab the bookmark.ranges, > print them, and close the doc's again. > ( and here comes the problem!! ) > But because the doc's have got a lot of pages with a whole lot of tables in > them, waiting seems like forever. So, is there anybody that has got a > suggestion in which way I have got to proceed. > Thx, > Mark G
|
Wed, 05 Nov 2003 07:36:23 GMT |
|
 |
Mark #4 / 7
|
 Open a doc, grab a range without having the whole doc being tabled
Thanks Mark for that one, It was not quite the same, but you brought me in new direction. I think I know what it is and I can use some help to put that in code. I'll explain what I figured out so far. docRuncode opens doc2 to get some info, then close, then opens doc3 and so on and so on doc2 has a reference set to (a timeconsuming) .dot, which is read only and is forbidden to edit that one. That same dot also has it's one Sub AutoOpen() and Sub AutoNew(). here it comes: When I open the dot and I manually stop the AutoOpen() from executing and THEN (while the .dot stays open) run the program written in docRuncode and leave it open while docRuncode is running and is collecting the info from all the doc2 to doc999. Well, wow, the speed of lighting has just arrived. I had to close the dot after I got my info manually, of course. So, now I still need the code that does just that for me. AnyOne ? Tia Mark G
Quote: > Mark, > Is it because the tables are linked to another source and the waiting > for the document to be "built" is because those links are updated when > the file is opened? If so, could you solve it just by clearing the > Update Automatic Links At Open option (in Tools-> Options-> General), > either manually or -- maybe best -- programmatically & then returning > it to its original setting at the end of the macro?
> ------ WWW: http://www.speakeasy.org/~mtangard ---------------------- > ------------- "Life is nothing if you aren't obsessed." --John Waters > ---------------------------------------------------------------------
> > Is it possible to open a doc with VBA code from another doc and then get > > some bookmark.ranges, without having to wait for the whole doc being build? > > I want to open each doc in a directory and then grab the bookmark.ranges, > > print them, and close the doc's again. > > ( and here comes the problem!! ) > > But because the doc's have got a lot of pages with a whole lot of tables in > > them, waiting seems like forever. So, is there anybody that has got a > > suggestion in which way I have got to proceed. > > Thx, > > Mark G
|
Wed, 05 Nov 2003 15:47:50 GMT |
|
 |
Mark #5 / 7
|
 Open a doc, grab a range without having the whole doc being tabled
* * * Found it , thanks all. * * :-)
Quote: > Thanks Mark for that one, > It was not quite the same, but you brought me in new direction. I think I > know what it is and I can use some help to put that in code. I'll explain > what I figured out so far. > docRuncode opens doc2 to get some info, then close, then opens doc3 and so > on and so on > doc2 has a reference set to (a timeconsuming) .dot, which is read only and > is forbidden to edit that one. That same dot also has it's one Sub > AutoOpen() and Sub AutoNew(). > here it comes: > When I open the dot and I manually stop the AutoOpen() from executing and > THEN (while the .dot stays open) run the program written in docRuncode and > leave it open while docRuncode is running and is collecting the info from > all the doc2 to doc999. Well, wow, the speed of lighting has just arrived. > I had to close the dot after I got my info manually, of course. > So, now I still need the code that does just that for me. > AnyOne ? > Tia > Mark G
> > Mark, > > Is it because the tables are linked to another source and the waiting > > for the document to be "built" is because those links are updated when > > the file is opened? If so, could you solve it just by clearing the > > Update Automatic Links At Open option (in Tools-> Options-> General), > > either manually or -- maybe best -- programmatically & then returning > > it to its original setting at the end of the macro?
> > ------ WWW: http://www.speakeasy.org/~mtangard ---------------------- > > ------------- "Life is nothing if you aren't obsessed." --John Waters > > ---------------------------------------------------------------------
> > > Is it possible to open a doc with VBA code from another doc and then get > > > some bookmark.ranges, without having to wait for the whole doc being > build? > > > I want to open each doc in a directory and then grab the > bookmark.ranges, > > > print them, and close the doc's again. > > > ( and here comes the problem!! ) > > > But because the doc's have got a lot of pages with a whole lot of tables > in > > > them, waiting seems like forever. So, is there anybody that has got a > > > suggestion in which way I have got to proceed. > > > Thx, > > > Mark G
|
Thu, 06 Nov 2003 00:46:32 GMT |
|
 |
Mark Tangar #6 / 7
|
 Open a doc, grab a range without having the whole doc being tabled
What was the solution? I'd like to know. Quote:
> * > * > * Found it , thanks all. > * > * > :-)
> > Thanks Mark for that one, > > It was not quite the same, but you brought me in new direction. I think I > > know what it is and I can use some help to put that in code. I'll explain > > what I figured out so far. > > docRuncode opens doc2 to get some info, then close, then opens doc3 and so > > on and so on > > doc2 has a reference set to (a timeconsuming) .dot, which is read only and > > is forbidden to edit that one. That same dot also has it's one Sub > > AutoOpen() and Sub AutoNew(). > > here it comes: > > When I open the dot and I manually stop the AutoOpen() from executing and > > THEN (while the .dot stays open) run the program written in docRuncode and > > leave it open while docRuncode is running and is collecting the info from > > all the doc2 to doc999. Well, wow, the speed of lighting has just arrived. > > I had to close the dot after I got my info manually, of course. > > So, now I still need the code that does just that for me. > > AnyOne ? > > Tia > > Mark G
> > > Mark, > > > Is it because the tables are linked to another source and the waiting > > > for the document to be "built" is because those links are updated when > > > the file is opened? If so, could you solve it just by clearing the > > > Update Automatic Links At Open option (in Tools-> Options-> General), > > > either manually or -- maybe best -- programmatically & then returning > > > it to its original setting at the end of the macro?
> > > ------ WWW: http://www.speakeasy.org/~mtangard ---------------------- > > > ------------- "Life is nothing if you aren't obsessed." --John Waters > > > ---------------------------------------------------------------------
> > > > Is it possible to open a doc with VBA code from another doc and then > get > > > > some bookmark.ranges, without having to wait for the whole doc being > > build? > > > > I want to open each doc in a directory and then grab the > > bookmark.ranges, > > > > print them, and close the doc's again. > > > > ( and here comes the problem!! ) > > > > But because the doc's have got a lot of pages with a whole lot of > tables > > in > > > > them, waiting seems like forever. So, is there anybody that has got a > > > > suggestion in which way I have got to proceed. > > > > Thx, > > > > Mark G
|
Thu, 06 Nov 2003 10:00:11 GMT |
|
 |
Mark #7 / 7
|
 Open a doc, grab a range without having the whole doc being tabled
First I opened .dot template and kept it open in the readonly mode, then I ran through all the files like Open, getinfo, close and at the end, I closed the template again. And this performing speed was so much better, because the template was already loaded and they all used that same template.
Quote: > What was the solution? I'd like to know.
> > * > > * > > * Found it , thanks all. > > * > > * > > :-)
> > > Thanks Mark for that one, > > > It was not quite the same, but you brought me in new direction. I think I > > > know what it is and I can use some help to put that in code. I'll explain > > > what I figured out so far. > > > docRuncode opens doc2 to get some info, then close, then opens doc3 and so > > > on and so on > > > doc2 has a reference set to (a timeconsuming) .dot, which is read only and > > > is forbidden to edit that one. That same dot also has it's one Sub > > > AutoOpen() and Sub AutoNew(). > > > here it comes: > > > When I open the dot and I manually stop the AutoOpen() from executing and > > > THEN (while the .dot stays open) run the program written in docRuncode and > > > leave it open while docRuncode is running and is collecting the info from > > > all the doc2 to doc999. Well, wow, the speed of lighting has just arrived. > > > I had to close the dot after I got my info manually, of course. > > > So, now I still need the code that does just that for me. > > > AnyOne ? > > > Tia > > > Mark G
> > > > Mark, > > > > Is it because the tables are linked to another source and the waiting > > > > for the document to be "built" is because those links are updated when > > > > the file is opened? If so, could you solve it just by clearing the > > > > Update Automatic Links At Open option (in Tools-> Options-> General), > > > > either manually or -- maybe best -- programmatically & then returning > > > > it to its original setting at the end of the macro? > > > > -- Mark Tangard
Quote: > > > > ------ WWW:
http://www.speakeasy.org/~mtangard ---------------------- Quote: > > > > ------------- "Life is nothing if you aren't obsessed." --John Waters > ---------------------------------------------------------------------
> > > > > Is it possible to open a doc with VBA code from another doc and then > > get > > > > > some bookmark.ranges, without having to wait for the whole doc being > > > build? > > > > > I want to open each doc in a directory and then grab the > > > bookmark.ranges, > > > > > print them, and close the doc's again. > > > > > ( and here comes the problem!! ) > > > > > But because the doc's have got a lot of pages with a whole lot of > > tables > > > in > > > > > them, waiting seems like forever. So, is there anybody that has got a > > > > > suggestion in which way I have got to proceed. > > > > > Thx, > > > > > Mark G
|
Thu, 06 Nov 2003 14:14:37 GMT |
|
|
|