#1
|
|||
|
|||
Printing Issue When Using A Table
Hello All
I have a document set up that I want to use for electronic case notes. It is created in Word 2003 and has a table inserted into it with columns for date, case notes, hours completed and a next reporting date. I want to be able to print the document each time I meet with a client. If the page is not full then I want the print to commence where it left off on the page last time. I did have this set up for Office 2000 Professional and had it working fine if I clicked on the outside of the table and highlighted just the section I wanted to print. It would automatically print just that section of the document and in that specific location on the page. This would allow me to meet with a client two or three times and print the case note without having to use/waste paper. Can anyone direct me to the specific print settings that I should use. I am using an HP printer but am also networked to a Minolta Copier/Printer. Thanks for your help! Kiwi |
#2
|
||||
|
||||
Hi Kiwi,
AFAIK, when printing just a part-page selection, all versions of Word start printing from the top of the page by default. To be able to start printing from somewhere lower down on the page implies temporarily making the preceding text white (so that it doesn't print), then changing its colour back afterwards. That would require a macro that intercepts the print command. Do you still have the Word 2000 version of your case notes template?
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
#3
|
|||
|
|||
Hello Paul
Unfortunately I do not have the Word 2000 version of the case note. I have recorded macros before but only very simple ones for specific text. I will give it a try and if I cant get it I will re-post. Thanks so much for your help. Christine |
#4
|
|||
|
|||
Hi Paul
Clearly I dont have it :-( I have tried a couple of times to create the macro and it is not working for me. I can get it to change the text colour but it also changes the new text that I am trying to print. I have to be able to create something that is very simple so that it is not confusing to other users..... or me :-)What we are trying to get is a version of electronic case notes that the Ministry will approve but that is not going to cost our non profit agency additional money... something that we dont have. Thanks for any help you can give me! Christine |
#5
|
||||
|
||||
Hi Christine,
I think this one would be beyond the macro recorder's capabilities. Try the following: Code:
Sub PartPrint() Application.ScreenUpdating = False Dim RngPrn As Range, RngClr As Range With ActiveDocument Set RngPrn = .GoTo(What:=wdGoToPage, Name:=.Range.Information(wdActiveEndPageNumber)) Set RngPrn = RngPrn.GoTo(What:=wdGoToBookmark, Name:="\page") Set RngClr = RngPrn With RngPrn .End = Selection.Range.Start .Font.Color = wdColorWhite Application.PrintOut Range:=wdPrintCurrentPage End With .Undo End With Application.ScreenUpdating = True End Sub If you add the macro to Word's 'Normal' template it will be available for use with any document. To use, simply press Alt-F8 and choose 'part print'. It will only print the current page and any type preceding the current insertion point will not be printed (unless you've got a coloured paper and white ink!)
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
#6
|
|||
|
|||
Hello Paul
Thanks for your help. The printing is now working great!! |
#7
|
|||
|
|||
Hello Paul
After a VERY long time the Ministry has finally approved our electronic case notes. I have the template set up in a table in word. I have installed the macro and the text part of the macro works fine when I do the printing however I have an issue where the table lines are printing again. They are not being turned white as the text is when I run the macro. Is there a simple fix for this? I would like to delete the table lines but unfortunately I am not able to do that. Thanks so much for your help! Christine |
#8
|
||||
|
||||
Hi Christine,
Try the following revised code: Code:
Sub PartPrint() Application.ScreenUpdating = False Dim RngPrn As Range, RngSel As Range, oTbl As Table, oCel As Cell, i As Long, j As Long With ActiveDocument Set RngPrn = .GoTo(What:=wdGoToPage, Name:=.Range.Information(wdActiveEndPageNumber)) Set RngPrn = RngPrn.GoTo(What:=wdGoToBookmark, Name:="\page") Set RngSel = Selection.Range With RngPrn .End = RngSel.Start .Font.Color = wdColorWhite For Each oTbl In RngPrn.Tables For Each oCel In oTbl.Range.Cells For j = 1 To oCel.Borders.Count oCel.Borders(j).Color = wdColorWhite i = i + 1 Next Next Next Application.PrintOut Range:=wdPrintCurrentPage End With For j = 1 To i .Undo If RngPrn.Font.Color <> wdColorWhite Then Exit For Next RngSel.Select End With Application.ScreenUpdating = True End Sub
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
#9
|
|||
|
|||
Hi Paul
We are almost there (Well you. It is your hard work that has done this). What I have is case notes in a table. I need the table to print along with the case notes. With the original macro the table was printing each time the paper was inserted into the printer and the only text that was printing was the part after the insertion point. I need for the table lines to print after the insertion point too if that is possible. Thanks again for your help. This is going to make my job so much easier rather than having to hand write everything. Have a great day! Christine |
#10
|
||||
|
||||
Hi Christine,
Another version for you to try: Code:
Sub PartPrint() Application.ScreenUpdating = False Dim RngPrn As Range, RngSel As Range, oTbl As Table, oCel As Cell, i As Long With ActiveDocument Set RngSel = Selection.Range Set RngClr = .GoTo(What:=wdGoToPage, Name:=RngSel.Characters.First.Information(wdActiveEndPageNumber)) Set RngClr = RngClr.GoTo(What:=wdGoToBookmark, Name:="\page") With RngPrn .End = RngSel.Start .Font.Color = wdColorWhite If RngSel.Characters.First.Information(wdWithInTable) = True Then For Each oTbl In RngPrn.Tables If oTbl.Range.End < RngSel.Tables(RngSel.Tables.Count).Range.End Then For Each oCel In oTbl.Range.Cells For i = 1 To oCel.Borders.Count oCel.Borders(i).Color = wdColorWhite Next Next Else For Each oCel In oTbl.Range.Cells If oCel.Row.Index < RngSel.Rows.First.Index Then For i = 1 To oCel.Borders.Count oCel.Borders(i).Color = wdColorWhite Next End If Next End If Next Else For Each oTbl In RngPrn.Tables For Each oCel In oTbl.Range.Cells For i = 1 To oCel.Borders.Count oCel.Borders(i).Color = wdColorWhite Next Next Next End If Application.PrintOut Range:=wdPrintCurrentPage End With While RngPrn.Font.Color = wdColorWhite .Undo Wend RngSel.Select End With Application.ScreenUpdating = True End Sub
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] Last edited by macropod; 11-13-2011 at 03:38 AM. Reason: Minor bug fixes |
#11
|
|||
|
|||
Printing Issues When Using A Table
I have been using a macro for a part print of a document when using a table. It worked fine until I found that one of my client files went onto a second page. It will only print the first page. I know the line of the macro that needs to be change...
Application.PrintOut Range:=wdPrintCurrentPage but I am not sure what I should be changing it to. Any help would be awesome. Thanks so much! Christine |
#12
|
||||
|
||||
Hi Christine,
Try the following: Code:
Sub PartPrint() Application.ScreenUpdating = False Dim RngClr As Range, RngSel As Range, oTbl As Table, oCel As Cell, i As Long With ActiveDocument Set RngSel = Selection.Range Set RngClr = .GoTo(What:=wdGoToPage, Name:=RngSel.Characters.First.Information(wdActiveEndPageNumber)) Set RngClr = RngClr.GoTo(What:=wdGoToBookmark, Name:="\page") With RngClr .End = RngSel.Start .Font.Color = wdColorWhite If RngSel.Characters.First.Information(wdWithInTable) = True Then For Each oTbl In RngClr.Tables If oTbl.Range.End < RngSel.Tables(RngSel.Tables.Count).Range.End Then For Each oCel In oTbl.Range.Cells For i = 1 To oCel.Borders.Count oCel.Borders(i).Color = wdColorWhite Next Next Else For Each oCel In oTbl.Range.Cells If oCel.Row.Index < RngSel.Rows.First.Index Then For i = 1 To oCel.Borders.Count oCel.Borders(i).Color = wdColorWhite Next End If Next End If Next Else For Each oTbl In RngClr.Tables For Each oCel In oTbl.Range.Cells For i = 1 To oCel.Borders.Count oCel.Borders(i).Color = wdColorWhite Next Next Next End If End With Application.PrintOut Range:=wdPrintFromTo, _ From:=CStr(RngSel.Characters.First.Information(wdActiveEndPageNumber)), _ To:=CStr(.Range.Characters.Last.Information(wdActiveEndPageNumber)) While RngClr.Font.Color = wdColorWhite .Undo Wend RngSel.Select End With Application.ScreenUpdating = True End Sub
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
#13
|
|||
|
|||
Thanks so much. You are amazing!!! I have it all set up and have run a test on one file and it appears to be working.
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Caption and Table of Figures issue | reece22345 | Word | 3 | 04-15-2011 12:18 AM |
Issue with Last Row in Table | BabyBoomerBooster | Word Tables | 1 | 02-25-2011 02:49 AM |
Powerpoint printing issue | eidius | PowerPoint | 1 | 01-13-2011 07:38 AM |
Non-Printing Graphics vs Printing | v_kiviranna | Drawing and Graphics | 4 | 06-29-2010 07:04 AM |
Pasting table in Photoshop cutting off table | azdolfan | Word Tables | 0 | 05-16-2010 01:52 PM |