procedure T_PRINT_SETUP.Print_Setup_BtnClick(Sender: TObject);
begin
xPrintSetup.Seton := 1;
xPrintsetup.Copies := sPinedit1.value;
xPrintsetup.Printerindex := cb_2.itemindex;
if checkbox1.Checked then
begin
xPrintsetup.FirstPage := spinedit2.value;
xPrintsetup.LastPage := spinedit3.value;
end;
if Radiobutton1.checked then
begin
xPrintsetup.Orientaion := poLandscape;
xPrintSetup.OrientFlag := 1;
end;
if Radiobutton2.Checked then
begin
xPrintsetup.Orientaion := poPortrait;
xPrintSetup.OrientFlag := 1;
end;
if RadioButton3.Checked then
xPrintsetup.OrientFlag := -1;
if (cb_1.text = '') then
begin
close;
modalResult := mrOk;
end;
if cb_1.Text = 'Default' then
xPrintsetup.PaperFlag := -1
else
xPrintsetup.PaperFlag := 1;
if cb_1.text = '사용자정의' then
xPrintSetup.PaperSize := Custom;
if cb_1.text = 'A3' then
begin
xPrintsetup.PaperSize := A3;
end;
if cb_1.text = 'A4' then
xPrintsetup.PaperSize := A4;
if cb_1.Text = 'A4Small' then
xPrintsetup.PaperSize := A4Small;
if cb_1.Text = 'A5' then
xPrintsetup.PaperSize := A5;
if cb_1.Text = 'B4' then
xPrintsetup.PaperSize := B4;
if cb_1.Text = 'B5' then
begin
xPrintsetup.PaperSize := B5;
end;
if cb_1.Text = '크기 360 X 280' then
begin
xPrintsetup.PaperSize := Custom;
xPrintsetup.Length := 280;
xPrintsetup.Width := 360;
end;
if cb_1.Text = '크기 216 X 280' then
begin
xPrintsetup.PaperSize := Custom;
xprintsetup.Length := 280;
xPrintsetup.Width := 216;
end;
if cb_1.Text = 'Letter' then
xPrintsetup.PaperSize := Letter;
if cb_1.Text = 'LetterSmall'then
xPrintsetup.PaperSize := LetterSmall;
if cb_1.Text = 'Tabloid' then
xPrintsetup.PaperSize := Tabloid;
if cb_1.Text = 'Ledger' then
xPrintsetup.PaperSize := Ledger;
if cb_1.Text = 'Legal' then
xPrintsetup.PaperSize := Legal;
if cb_1.Text = 'Statement' then
xPrintsetup.PaperSize := Statement;
if cb_1.Text = 'Executive' then
xPrintsetup.PaperSize := Executive;
close;
modalResult := mrOk;
procedure T_PRINT_SETUP.Print_Setup_BtnClick(Sender: TObject);
begin
xPrintSetup.Seton := 1;
xPrintsetup.Copies := sPinedit1.value;
xPrintsetup.Printerindex := cb_2.itemindex;
if checkbox1.Checked then
begin
xPrintsetup.FirstPage := spinedit2.value;
xPrintsetup.LastPage := spinedit3.value;
end;
if Radiobutton1.checked then
begin
xPrintsetup.Orientaion := poLandscape;
xPrintSetup.OrientFlag := 1;
end;
if Radiobutton2.Checked then
begin
xPrintsetup.Orientaion := poPortrait;
xPrintSetup.OrientFlag := 1;
end;
if RadioButton3.Checked then
xPrintsetup.OrientFlag := -1;
if (cb_1.text = '') then
begin
close;
modalResult := mrOk;
end;
if cb_1.Text = 'Default' then
xPrintsetup.PaperFlag := -1
else
xPrintsetup.PaperFlag := 1;
if cb_1.text = '사용자정의' then
xPrintSetup.PaperSize := Custom;
if cb_1.text = 'A3' then
begin
xPrintsetup.PaperSize := A3;
end;
if cb_1.text = 'A4' then
xPrintsetup.PaperSize := A4;
if cb_1.Text = 'A4Small' then
xPrintsetup.PaperSize := A4Small;
if cb_1.Text = 'A5' then
xPrintsetup.PaperSize := A5;
if cb_1.Text = 'B4' then
xPrintsetup.PaperSize := B4;
if cb_1.Text = 'B5' then
begin
xPrintsetup.PaperSize := B5;
end;
if cb_1.Text = '크기 360 X 280' then
begin
xPrintsetup.PaperSize := Custom;
xPrintsetup.Length := 280;
xPrintsetup.Width := 360;
end;
if cb_1.Text = '크기 216 X 280' then
begin
xPrintsetup.PaperSize := Custom;
xprintsetup.Length := 280;
xPrintsetup.Width := 216;
end;
if cb_1.Text = 'Letter' then
xPrintsetup.PaperSize := Letter;
if cb_1.Text = 'LetterSmall'then
xPrintsetup.PaperSize := LetterSmall;
if cb_1.Text = 'Tabloid' then
xPrintsetup.PaperSize := Tabloid;
if cb_1.Text = 'Ledger' then
xPrintsetup.PaperSize := Ledger;
if cb_1.Text = 'Legal' then
xPrintsetup.PaperSize := Legal;
if cb_1.Text = 'Statement' then
xPrintsetup.PaperSize := Statement;
if cb_1.Text = 'Executive' then
xPrintsetup.PaperSize := Executive;
close;
modalResult := mrOk;
이런식으로 셋팅을 해야 될 듯 싶군여......
그럼 즐코하세요...........