Docstoc

Xprint and Multiple buttons

Document Sample
Xprint and Multiple buttons Powered By Docstoc
					                                         Xprint and Multiple buttons

Xprint and Multiple buttons

Source:
http://www.tech−archive.net/Archive/Outlook/microsoft.public.outlook.program_forms/2005−10/msg00120.html



      • From: "Lutiana" <emailjrc@xxxxxxxxx>
      • Date: 17 Oct 2005 09:17:45 −0700

Hi all, I am new at customizing outlook forms and I am having an issue
with trying to have multiple print buttons on a form.

I am trying to create a form that will allow me to print 2 kinds of
things. One is an internal doc for our filing and the other is one for
our customer (these do not need to be printed at the same time, nor do
I think they ever would be).

I am using xprint and I am trying to extrapolate from the MS example
how to do this. If I use just one button it works fine, but as soon as
I try to add another I get an error message (after the option to
debug).

Error 1: Object doesn't support this property or method:
'objPage2.Xprint2' Line No. 17

Then when I click the button I get: Object required: 'objXprint2'

I cannot seem to find any information anywhere on this, and as near as
a I can see the code is complete.

Here is my code:

Dim objInsp
Dim objPage1, objPage2
Dim objXPrint1, objXPrint2

Function Item_Open()
Set objInsp = Item.GetInspector
Set objPage1 = objInsp.ModifiedFormPages("RMA Entry")
Set objXPrint1 = objPage1.XPrint1
objXPrint1.Preview = True
objXPrint1.Controls = objPage1.Controls
End Function

Function Item2_Open()
Set objInsp = Item.GetInspector
Set objPage2 = objInsp.ModifiedFormPages("PrintReport")


Xprint and Multiple buttons                                                                        1
                                         Xprint and Multiple buttons
Set objXPrint2 = objPage2.XPrint2
objXPrint2.Preview = True
objXPrint2.Controls = objPage2.Controls
End Function

Sub cmdPrint_Click()
objXPrint1.PrintForm
End Sub

Sub cmdPrintReport_Click()
objXPrint2.PrintForm
End Sub


Any help would be greatly appreciated.

Thanks

J

.



      • Follow−Ups:
             ♦ Re: Xprint and Multiple buttons
                    ◊ From: Sue Mosher [MVP−Outlook]

      • Prev by Date: Re: No Signature (Outlook 2002)
      • Next by Date: Re: Xprint and Multiple buttons
      • Previous by thread: Custom forms displayed incorrectly when O2003 in cached mode
      • Next by thread: Re: Xprint and Multiple buttons
      • Index(es):
             ♦ Date
             ♦ Thread




Xprint and Multiple buttons                                                                2

				
DOCUMENT INFO
Shared By:
Categories:
Tags:
Stats:
views:2
posted:7/8/2011
language:English
pages:2