Printing to OIPI printer (AREV64)
At 28 FEB 2024 10:07:14PM Barry Stevens wrote:
Is there anyway to change the @lptrHigh/Wide when a report is run to be able to force a Portrait/Landscape print.
I see in the config settings UI for AREV64 OIPI, there is a reference to SET_OIPI_PROPERTIES, I dont see any documentation on it.
I assume that is what I should be using.
At 28 FEB 2024 10:16PM Barry Stevens wrote:
Is there anyway to change the @lptrHigh/Wide when a report is run to be able to force a Portrait/Landscape print.
I see in the config settings UI for AREV64 OIPI, there is a reference to SET_OIPI_PROPERTIES, I dont see any documentation on it.
I assume that is what I should be using.
Ooops, just remembered and found the KB article, this looks like what I want.
At 28 FEB 2024 11:47PM Barry Stevens wrote:
Is there anyway to change the @lptrHigh/Wide when a report is run to be able to force a Portrait/Landscape print.
I see in the config settings UI for AREV64 OIPI, there is a reference to SET_OIPI_PROPERTIES, I dont see any documentation on it.
I assume that is what I should be using.
Ooops, just remembered and found the KB article, this looks like what I want.
At 29 FEB 2024 08:15AM bshumsky wrote:
Hi, Barry.
If you set that flag in the CFG_AREV64_OIPI configuration record (most easily, through the OI Console, or manually by putting a "1" in field 1 of the record), then when you use an OIPI printer in AREV64, it will determine whether to print in landscape or portrait based on @lptrwide. If @lptrwide is greater than the page width, then OIPI will switch that output to landscape for you.
There is an alternative method as well, which is what the second section of that wiki description talks about. There is a stored procedure called SET_OIPI_PROPERTIES that you can use in your AREV64 routines to override many of the OIPI properties (if you're using an OIPI printer from AREV64) - it gives you access to the other parameters that you would normally have in the SET_PRINTER("INIT") call. The question is, if your program is using SET_OIPI_PROPERTIES and you're passing in a "1" to the landscape parameter - should that take precedence over the CFG_AREV64_OIPI flag that says determine landscape or portrait dynamically? That's what field 2 of the config record clarifies…
Hope that helps,
- Bryan Shumsky
At 29 FEB 2024 01:58PM Barry Stevens wrote:
Hi, Barry.
If you set that flag in the CFG_AREV64_OIPI configuration record (most easily, through the OI Console, or manually by putting a "1" in field 1 of the record), then when you use an OIPI printer in AREV64, it will determine whether to print in landscape or portrait based on @lptrwide. If @lptrwide is greater than the page width, then OIPI will switch that output to landscape for you.
There is an alternative method as well, which is what the second section of that wiki description talks about. There is a stored procedure called SET_OIPI_PROPERTIES that you can use in your AREV64 routines to override many of the OIPI properties (if you're using an OIPI printer from AREV64) - it gives you access to the other parameters that you would normally have in the SET_PRINTER("INIT") call. The question is, if your program is using SET_OIPI_PROPERTIES and you're passing in a "1" to the landscape parameter - should that take precedence over the CFG_AREV64_OIPI flag that says determine landscape or portrait dynamically? That's what field 2 of the config record clarifies…
Hope that helps,
- Bryan Shumsky
That's the bit that got me.
But, I now see you have a reference to SET_PRINTER("INIT") in you statement.
So, all I can guess is that SET_OIPI_PROPERTIES has the exact same parameters as the "INIT" method?
If so, may I say that is very cool.
At 29 FEB 2024 02:38PM bshumsky wrote:
Hi, Barry.
Oh, you want to know what the parameters _are_? I guess that might be useful…
Here is the interface to SET_OIPI_PROPERTIES:
call SET_OIPI_PROPERTIES(fileInfo, titleInfo, pageInfo, pageSetup, printSetup, printer)
(and as you will recall, the parameters to the OIPI "init" call are:
set_property("INIT", fileInfo, titleInfo, pageInfo, pageSetup, printSetup, printer)
so yes, they are the same)
- Bryan Shumsky
At 29 FEB 2024 02:41PM bshumsky wrote:
You can also find more info about the call by looking at this link in the wiki.
- Bryan Shumsky
At 29 FEB 2024 03:28PM Barry Stevens wrote:
You can also find more info about the call by looking at this link in the wiki.
- Bryan Shumsky
I assume params 7,8,9 are not relevant to arev64
I can confirm this works like a charm!!!