Solved

Quickrpt 2.0i setting the output bin in program

Posted on 1997-11-11
11
734 Views
Last Modified: 2012-06-22
How do I set the output bin in the program.

Like:
qrInvoice.PrinterSettings.OutputBin := ?;

I've tried a lot, but this one has me stumped... I don't have the source code so that might make it impossible?

Please no...
--Jason
0
Comment
Question by:loucks
  • 5
  • 5
11 Comments
 

Expert Comment

by:MAXcom
ID: 1350071
Hi,
There can be:
Auto
Casette
Envelope
EnvManual
First
LargeCapacity
LargeFormat
Last
Lower
Manual
Middle
SmallFormat
Tractor
Upper

Is this your report form you are editing? If so, there is an option in the Object Inspector - Printer Settings -Output Bin.
Hope this helps.
MAXcom
0
 

Author Comment

by:loucks
ID: 1350072
I need for the operator to be able to choose "Manual Feed", "Lower Tray" etc while RUNNING the form.  Thus, any answer which includes the object inspector will not work.

I need to know what goes in the ? above.
0
 
LVL 8

Expert Comment

by:ZifNab
ID: 1350073
What MaxCom said is correct : OutputBin property is of type TQRBin and TQRBin is a set of the ones MaxCom said. So if you want to use the Middle outputbin, you write :

 qrInvoice.PrinterSettings.OutputBin := Middle;

Though, if the printer doesn't support this property, the default (first) output bin will be used. LOOK OUT! : YOU CAN'T CHANGE OUTPUT BIN DURING A REPORT!!
0
 

Author Comment

by:loucks
ID: 1350074
if (fMainRepMenu.rgPrintTo.ItemIndex = 0) then
   qrLOInvoice.PrinterSettings.OutputBin := Upper;
if (fMainRepMenu.rgPrintTo.ItemIndex = 1) then
   qrLOInvoice.PrinterSettings.OutputBin := Lower;
if (fMainRepMenu.rgPrintTo.ItemIndex = 2) then
   qrLOInvoice.PrinterSettings.OutputBin := Manual;

This code does not compile.  What do I need to include to make it compile?  

The compiler returns a message stating: Undeclared Identifier: 'Upper'.  Undeclared Identifier: 'Lower'. etc...

If I try to give it a numeric value it says that integer is not compatible with TQRBin type.  
0
 
LVL 8

Expert Comment

by:ZifNab
ID: 1350075
Hi Loucks,

I see your problem, try it this way, it doesn't gives a compile error, but I can't try it out on a printer. Give me a sign if it works.

 qrLOInvoice.QRPrinter.OutputBin := Manual;

Have fun,
c.u. ZifNab;
0
Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

 

Author Comment

by:loucks
ID: 1350076
nope, still doesn't work...   it seems like I should have to use another unit or something where TQRBin is declared, but I can't find anything like that...  Please keep trying
0
 
LVL 8

Expert Comment

by:ZifNab
ID: 1350077
Strange, it compiles when I use that code, here is the form code.
I'll try to find another solution.


unit Unit1;

interface

uses
  Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs,
  StdCtrls, Buttons, ExtCtrls, quickrpt;

type
  TForm1 = class(TForm)
    QuickRep1: TQuickRep;
    BitBtn1: TBitBtn;
    procedure BitBtn1Click(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  Form1: TForm1;

implementation

{$R *.DFM}

procedure TForm1.BitBtn1Click(Sender: TObject);
begin
 Quickrep1.QRPrinter.OutputBin := Last;
end;

Have you put in fMainRepMenu the quickrpt unit?
end.

0
 

Author Comment

by:loucks
ID: 1350078
created a new project and tried it your way but it still didn't work...  I have "used" the quickrpt unit and still not working...

Do you have the full product from qusoft or just the standard?

I am using quickrpt 2.0i and delphi 3.0.

--Jason
0
 
LVL 8

Expert Comment

by:ZifNab
ID: 1350079
Hi Jason,

I'm using a registered version of QR 2.0i, with Delphi 2.0.

Try it like the first way :

 qrLOInvoice.PrinterSettings.OutputBin := Upper;

but add unit qrprntr to your unit.

Have fun! Hope this works,
c.u. ZifNab;

 

0
 

Author Comment

by:loucks
ID: 1350080
Guess what!?!!!  It worked!!!! That was exactly what I needed... 225 points goes to you for sticking with me...  Submit that as the answer and you will be graded A.  Thanks AGAIN!!!!

--Jason
0
 
LVL 8

Accepted Solution

by:
ZifNab earned 220 total points
ID: 1350081
Hi Jason,

Use following code example to change outputbin :

  qrLOInvoice.PrinterSettings.OutputBin := Upper;

BUT ADD ----> UNIT QRPRNTR <---- to your unit.

Well, it toke some time, but I'm glad it works now.

Have fun with your program,
c.u. ZifNab;

                         Have fun! Hope this works,
                         c.u. ZifNab;
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Strange code, can use it, but i cant figure out what it does. 3 54
Delphi XE10, MySQL Query 4 125
Delphi 2 45
PHP preg_replace code convert to Delphi 14 30
Have you ever had your Delphi form/application just hanging while waiting for data to load? This is the article to read if you want to learn some things about adding threads for data loading in the background. First, I'll setup a general applica…
Introduction Raise your hands if you were as upset with FireMonkey as I was when I discovered that there was no TListview.  I use TListView in almost all of my applications I've written, and I was not going to compromise by resorting to TStringGrid…
I designed this idea while studying technology in the classroom.  This is a semester long project.  Students are asked to take photographs on a specific topic which they find meaningful, it can be a place or situation such as travel or homelessness.…
The Email Laundry PDF encryption service allows companies to send confidential encrypted  emails to anybody. The PDF document can also contain attachments that are embedded in the encrypted PDF. The password is randomly generated by The Email Laundr…

947 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now