How to delete more than 2 pages at a time in Publisher

I've got a 600 page Publisher 2003 document and want to delete 200 pages. Is 
there an easier way of doing this instead of doing EDIT > DELETE PAGE > BOTH 
PAGES 100 times!?


----------------
This post is a suggestion for Microsoft, and Microsoft responds to the 
suggestions with the most votes. To vote for this suggestion, click the "I 
Agree" button in the message pane. If you do not see the button, follow this 
link to open the suggestion in the Microsoft Web-based Newsreader and then 
click "I Agree" in the message pane.

http://www.microsoft.com/office/community/en-us/default.mspx?mid=c2b60410-6845-4225-aeae-a9712c55fadc&dg=microsoft.public.publisher
0
JT (62)
6/15/2005 1:15:03 AM
publisher 21446 articles. 4 followers. Follow

3 Replies
650 Views

Similar Articles

[PageSpeed] 50

JT wrote:
> I've got a 600 page Publisher 2003 document and want to delete 200
> pages. Is there an easier way of doing this instead of doing EDIT >
> DELETE PAGE > BOTH PAGES 100 times!?

TTBOMK, no. 


0
test1951 (392)
6/15/2005 1:46:39 AM
JT <JT@discussions.microsoft.com> was very recently heard to utter:
> I've got a 600 page Publisher 2003 document and want to delete 200
> pages. Is there an easier way of doing this instead of doing EDIT >
> DELETE PAGE > BOTH PAGES 100 times!?

Use a macro.

Go to Tools > Macro > Visual Basic Editor
Double-click Project > Microsoft Publisher Objects > ThisDocument.

Copy and paste the following into the code window:

'BEGIN COPY
Sub DeletePageXToY()
    Dim X As String, Y As String
    Dim Xi As Integer, Yi As Integer

    X = InputBox("Enter the number of the first page you would like to 
delete")
    If X = "" Then Exit Sub

    Y = InputBox("Enter the number of the last page you would like to 
delete")
    If Y = "" Then Exit Sub

    Xi = Val(X)
    Yi = Val(Y)
    If Not (Xi = Val(X) And Yi = Val(Y)) Then Beep: Exit Sub

    If Y < X Then Beep: Exit Sub
    If X > ThisDocument.Pages.Count Then Beep: Exit Sub

    ThisDocument.BeginCustomUndoAction "Delete Pages " & X & " to " & Y & 
"."

    Dim i As Integer
    For i = X To Y
        ThisDocument.Pages(X).Delete
    Next

    ThisDocument.EndCustomUndoAction
End Sub
'END COPY

Click inside the sub (say, click on ThisDocument.BeginCustomUndoAction), and 
click the big green Play button on the toolbar.  Follow the on-screen 
instructions.

-- 
Ed Bennett - MVP Microsoft Publisher 


0
the_nerd (6344)
6/15/2005 8:24:52 AM
JT <JT@discussions.microsoft.com> was very recently heard to utter:
> I've got a 600 page Publisher 2003 document and want to delete 200
> pages. Is there an easier way of doing this instead of doing EDIT >
> DELETE PAGE > BOTH PAGES 100 times!?

N.B. The code posted only works as expected if the page numbers start at 1 
and run without breaking.  Otherwise, pages other than the ones you expect 
to disappear will be deleted.

-- 
Ed Bennett - MVP Microsoft Publisher 


0
the_nerd (6344)
6/15/2005 8:25:41 AM
Reply:

Similar Artilces:

Age calculation #2
Hi, I'm looking for a formula to give a better response on age calculation. I have a list of computers with the data they were purchased on. I want to know how old they are. Here is what I have so far: G1 contains =today() to give current date F14 is the purchase date of the first computer in the list G14 is this formula, which tells me how many months old the computer is: =($G$1-F14)/30 The problem is that it tells me that the computer is 90 months old, which is correct, but I want to see that its 7.5 years old. Dividing that by 12 gives the answer, but there are newer computer...

Cannot delete subreport
I am using Access 2003 and have a report I did a while back with a simple subreport. I want to remove the subreport but for the life of me can't figure out how to do it. Any help would be greatly appreciated. Thanks. Hi - When you say "remove the sub report", what do you mean? Do you want to delete the entire subreport control containing the subreport, or do you want to keep the control, but change the report contained in it? The first is easy - select the control by clicking once on it once, then press delete. For the second, click the control once, then set ...

How to Recover Deleted Sent Mail?
While trying to delete very old "Sent" mail I seem to have deleted all "Sent" mail. Is there a way of recovering this mail? Have you closed Outlook since deleting the old sent mail? http://www.howto-outlook.com/howto/restoredeleteditemsfromanoutlookpst.htm might help. Next time, archive the items you want removed from your active .pst file. --� Milly Staples [MVP - Outlook] Post all replies to the group to keep the discussion intact. All unsolicited mail sent to my personal account will be deleted without reading. After furious head scratching, Sidney Friedman as...

Reply #2
Hi, I have tried this but it still tries to save as the default which in this case is No, when I need it to save as Yes Many thanks anyway John PS I think by putting your suggestion in, it just hides the alerts, but still keeps to the defaults. JohnUK wrote: > Hi, I have tried this but it still tries to save as the > default which in this case is No, when I need it to save > as Yes > Many thanks anyway > John > PS I think by putting your suggestion in, it just hides > the alerts, but still keeps to the defaults. If indeed you even see this, PLEASE do NOT change the su...

Rule for Deleted Items
I am being told that there is a rule in place on my Exchange server that will not empty the deleted items folder every 30 days for certain users in my organization. I found a recipient policy in System Manager that says "Users Excluded from Mailbox Cleanup" but it only shows 2 users and not the 3 I was told about. But I have confirmed that the missing person has email in her deleted items folder going back to 2005 so it must be working. Is there any other location I should be looking? Also, we just had someone come in and migrate our Exchange environment from 2000 to a new...

Time Card Report #2
Does anyone know if there is a more user friendly template for Time Card report ? We pay employees every 2 weeks and whenever I run a 2 week report, it only shows one date and below this date it sums up 2 dates of cumulative time worked instead of showing the isolated 2 dates. In other words, under a Monday 5/1, it will show 15 hours which actually means that the person worked cumulatively 15 hours on Monday 5/1 AND Monday 5/8... but Time Card report doesn't show the 5/8 separately which is quite confusing and invonvenient. Any help would be highly appreciated! Here is an addit...

1.2 Integration Release
Microsoft, when is 1.2 Integration going to release? All I hear is "soon", but "soon" is now turned into months. -- Brandon IT Director Presentations Direct - Office Equipment & Supplies http://www.presentationsdirect.com I have NO real information, but if I had to guess it would be announced just prior to or during Convergence (3/21- 24). >-----Original Message----- >Microsoft, when is 1.2 Integration going to release? All I hear is "soon", >but "soon" is now turned into months. > >-- >Brandon >IT Director >Present...

cannot delete message from deleted items
I have a message in my deleted items folder that when choosing delete opens the McAfee box warning of potential virus and wants me to choose open or do not open, but will not delete. I have tried choosing another file and holding ctrl and choosing the file I want deleted and then choosing delete, I have tried moving it to the desktop but it will only copy there, I have tried every form of delete possible. I need help. Anyone know how? Outlook 2002. Can you empty the deleted items folder entirely? Or turn off the McAfee scanning temporarily to see if it makes a difference? Julie wr...

Referring to Names #2
Hi Frank I'm looking for something that's easy to copy across. Say column A contains an alpha and columns B to X contain variou numerical values with range created names of Bdata to Xdata. I'm wondering if there is any way of writing the formul Sumif(Alpha,A,Bdata) by referring Bdata to a cell reference instead o using the term "Bdata" itself, so that I can change the cell and brin up the relevant result. Hope this makes sense Timmy Ma -- Timmy Mac ----------------------------------------------------------------------- Timmy Mac1's Profile: http://www.excelfo...

hello #2
hello how am i able to give a percantage discount on the pos screen. i have a dollar retail bussiness and some times customer buys for example 50 or 100 candles from me for a weeding. so is their a way that i can give her 8% discount. so it should be something like this .... 0000123 white taper candles $1.00 x 100 = $100.00 minus 8 % = $100.00 - 8% = $92.00 92.00 plus tax thanx in advance From POS do Shift-F3 to get to the Discounts tab and take a look at the variations. You should be able to accomplish what you need. Richard "Adnan" wrote: > hello > how am i able t...

number of rows #2
I used autoformat so that my rows would alternate colors. But, it added a bunch of empty rows so that the sheet is maxed out and my file is huge. I don't need all those empty rows and I can't find a way to delete them. Any suggestions for how to get rid of the rows, or limit the number of rows on a worksheet? I know I could copy all the data to a new worksheet, but I'd like a better solution. Try this: click on the number of the first empty row, so the whole row is selected. Using the vertical scrollbar, go to the last row on the sheet. Hold down the shift key while you cli...

Outlook won't check 2nd email address #2
I have two email accounts set up in Outlook '02 SP3 (10.2627.6626). When sending/receiving only the default account is being checked. Send/Receive group is configured as follows. Beneath "Group Name" it says "All Accounts. Beneath "Send/Receive when" it says "Online and Offline." "Include this group in send/receive" is checked. I guess this is default as I have never configured this manually. I have tried deleteing the account and re-entering it. After re-entering, Outlook will "Test Account Settings" okay. A message is sent t...

I can not delete a duplicate personal folders list #2
Vall... amazing that there isn't an easy fix for this. The instructions provided simply don't work ( tools-email accounts-view change email accounts-deliver to new account-finish-close outlook and reopen ), and none of the other offered explanations have worked either. As this is such a common problem; why hasn't microsoft provided a very EASY fix? I am more confused ( and frightened ) and don't want to make the problem worse! Your profile is corrupt, probably based on an incorrect migration of your ..pst file. Create a new mail profile and configure it to use your exi...

GP 10 Keyboard Page Up/Down and Mouse Wheel
After upgrading from GP 9 tp GP 10 the keyboard Page Up/Down buttons and the mouse wheel do not work when trying to advance a page of a report that was printed to the Screen as the desination. Anyone else experience this problem? If so, is there a work around? Thank you, Don It is a known issue. Click the box for the magnification. You don't even have to change the magnification. Once you click on the magnification box (or field), click in the report and you can scroll up and down. -- Charles Allen, MVP "Don Leugers" wrote: > After upgrading from GP 9 tp GP 10...

File conversion #2
I have been using Excel for Mac. I have now reverted to Windows and although I'm able to work and save the file I'm prompted with a 'File conversion in Progress'. How can I stop this message and still use the file? TIA - Dave "Dasco" <cadasco@SUPERhotmail.com> wrote in message news:6dotv5F3m1sbU1@mid.individual.net... >I have been using Excel for Mac. I have now reverted to Windows and >although I'm able to work and save the file I'm prompted with a 'File >conversion in Progress'. How can I stop this message and still use the ...

Horizontal Page Breaks
HI: Can anyone tell me if there is a limit to the number of horizontal page breaks I can have in a work sheet. I have a sheet with 43 Pages, which ends at Row 2066. When I add another page, I am unable to pull the print area down any further. If I go up a few rows and insert a page break, I can adjust that just fine. However, I can still not pull it past row 2066. Thanks, Sam I ran this macro: Option Explicit Sub testme01() Dim iCtr As Long ActiveSheet.ResetAllPageBreaks For iCtr = 2 To 65536 Step 2 ActiveSheet.HPageBreaks.Add before:=Cells(iCtr, "A") ...

Retrieval of Deleted Items After Being Deleted from the Deleted Items File
I deleted a number of important emails from the deleted items file in Outlook 2000. This may sound stupid, but I completely emptied the deleted items file instead of deleting them one by one. Pretty stupid, huh. Anyone. Can they be retrieved? Please help. Thanks. Sorry for sending this again but I seem to be computer illiterate and it has taken me some time to explain the whole situation. Thanks again. unless you use Exchange server with deleted retention enabled, you are most likely out of luck, but you can try something that might help.... http://www.outlook-tips.net/howto/r...

Follow Up Flag #2
When I set a follow up flag in Outlook 2000 it inserts a default time of 18:00. Is there a way to alter this default or do I have to change the time manually for every flag I set? ...

Conditional Formating #2
Good morning to everyone. Does anyone know if Conditional Formating have an issue in the charts? i have make text boxes which bring values from another sheet and i want to show the figures inside as green when i have an improve or red if i have damage. Any suggestions? Ps I am using EXCEL XP edition Regards Bill Jon Peltier has instructions for conditional charts: http://www.peltiertech.com/Excel/Charts/format.html#CondChart You could change the formula, to calculate if an amount is greater or less than the previous amount. Bill wrote: > Good morning to everyone. > >...

Prints blank page first?
I created a publication on one computer (Pub 2000, Win98SE), burned it to a CD, and am trying to print from another computer (Publisher 2000 with Win2000 and an HP Deskjet printer). Ctrl+P, Print page 1 to 1 - and I get a blank sheet coming out first, then Page 1. Same thing happened with Page 2. Did I miss a setting somewhere? Ed Did you try copying the file to the hard drive first and then print? Open the printers and fax folder in the control panel, right-click your printer, properties, advanced tab, separator page button, clear anything it may say in the "separator page"...

Delete macros
I am using Excel 2002. When I click on Tools->Macro->Macros... i see 2 macros. The problem I am having is that I can't delete these macros, the delete button to the right is grayed out. How can I delete these macros? Hi maybe the macros are protected. Try hitting ALT + F11 to open the VBA editor and try to delete the macros / modules there -- Regards Frank Kabel Frankfurt, Germany excel777 wrote: > I am using Excel 2002. When I click on Tools->Macro->Macros... i see > 2 macros. The problem I am having is that I can't delete these > macros, the delete button to ...

deleting email in outlook, freezes before i can delete
i have a file with pics that symetec scanner says is to large. i can receieve email but cannot send any. it freezes before i can delete and says non responding. Hi All, I want to re-raise the old issue of Fax numbers showing up in the Outlook Address book when one is sending an email. I know that this can be stopped by prepending the Contact's fax number with a letter so that Outlook doesn't see it as a valid fax number and therefore doesn't list it. What's always puzzled me, however, is that this fix doesn't work if the fax numbers are changed using an export to CSV...

Run time Error '1004
I have a macro to run right before the workbook closes. It is as follows: Private Sub Workbook_BeforeClose(Cancel As Boolean) Range("A1").Select ActiveSheet.ShowAllData ActiveWorkbook.Save End Sub The top row has the autofilter on. If the data is not filtered then when the macro runs it throws a Run Time Error '1004'. If it is filtered the Macro runs fine. I can't seems to find the right code to get the macro to end if it errors out. I think it would be an if then statement but my coding skills aren't quite up the par. Any help would be great. Thanks in adva...

How do I set up an incoming hyperlink to a page within a frame?
I have a web site that uses frames under FrontPage 2003. Each frame typically contains a banner page, a contents page and a main page. How does another web site hyperlink to a bookmark within a paricular main page so that the banner and contents pages are displayed as well (ie. together with the main page). Without these, it is impossible to navigate around the web site after the hyperlink is executed. No Link to your Website ....... No Help for Website we do not know if It is a <frameset></frameset> Or <iframe></iframe> Add-to-favorites Script for if...

Combining pages
How do I combine two A4 pages of pictues in to a single publisher document? Alan wrote: > How do I combine two A4 pages of pictues in to a single publisher > document? ================================ Add a blank page to the target document. To add the second page...Select All / Copy / Paste. FWIW...you can open more than one instance of Publisher. -- J. Inzer MS-MVP Digital Media Experience Notice This is not tech support I am a volunteer Solutions that work for me may not work for you Proceed at your own risk ...