Creating PDF's from OIPI - write fails (OpenInsight 64-bit)
At 25 JUL 2023 05:12:17PM Greg Helland wrote:
We create PDF's using OIPI and this has worked flawlessly in OI9.4. In 10.2, the OIPI form is created properly and then when it goes to automatically write out the PDF, some, not all, users get an error shown below.
It works flawlessly in OI10.2 when I am RDP'd into the server. It also works for the in house administrator. Not for general users. Actually, if the user waits about 5 minutes, the PDF will be created, error message below displayed and then the PDF opened.
I have been going round and round with their external IT support group and they keep telling me there is no reason it should not work for "regular" users. I keep pointing out that it does not look like the user has write privileges to create the tempfile on C:\Users….. We know that the user has rights to the T:\ because I have logged onto a users desktop and created a TXT file in T:\. I have also been able to create a TXT file in the C:\Users\DJF\AppData\Local\Temp\ folder. So, it points to them having proper rights.
Any help is appreciated!
Here is how the OIPI call is set up:
InitPrint: Display = "Job Cost Analysis for: ":SO FileInfo = "" FileInfo<3> = 6 PDF_Path = Xlate("COMPANY", "DFLT_PDF_PATH", 1, "X") Rinfo = 'Detail' If RPTYP = 'S' Then Rinfo = 'Summary' End * FileInfo<4> = PDF_Path:"JOBCOST ":Rinfo:" for ":SO:".PDF" * PrintSet = '' PrintSet<1,1> = 5 PrintSet<1,2> = 2 PrintSet<1,3> = 1 ;* Hide the printing window PrintSet<1,4> = 3 ;* 1 minimized, 2=hidden, 3=completly hidden PrintSet<1,5> = 1 PrintSet<1,6> = 3 * Mode = 4 Mode<1,2> = 0 FOOT = " " ldata = '' PrintError = set_printer("INIT",FileInfo,Display,"",PrintSet,Mode)I will also note that PrintSet<1,4> = 3 does NOT hide the OIPI window when it is rendering the document. Have tried 1, 2 and 3, no difference. Any hints on that would be appreciated as well.
Thanks,
Greg Helland
BleuPelikan, Inc.
At 26 JUL 2023 03:02PM Greg Helland wrote:
Further info on this error. Still points to rights issues but their external IT group is saying this is incorrect. I still disagree. I tried saving as an RTF to see if I got the same error. A little different error came up saying "Make Sure Your Environment Paths Are Valid And Have Full Rights"
Anyone know what environment paths this is referring to? Any help is appreciated!
At 26 JUL 2023 03:58PM Barry Stevens wrote:
Further info on this error. Still points to rights issues but their external IT group is saying this is incorrect. I still disagree. I tried saving as an RTF to see if I got the same error. A little different error came up saying "Make Sure Your Environment Paths Are Valid And Have Full Rights"
Anyone know what environment paths this is referring to? Any help is appreciated!
%TEMP% ?
At 26 JUL 2023 04:49PM Greg Helland wrote:
Barry,
Thanks for chiming in. I had checked those and just checked again. Went into Environment Variables and verified that TEMP and TMP are in the path and have full access from C:\Users\DJF\ down the path.
That is why this is so frustrating is that all seems accurate on the surface but something else is not set properly.
Any other ideas? Anyone, anyone? Bueller, Bueller?
Thanks,
Greg
At 26 JUL 2023 05:27PM bshumsky wrote:
Hi, Greg.
OIPI "Classic" or OIPI.Net?
What are the contents (if any) of SYSENV's CFG_OIPI (and its various iterations - CFG_OIPI*<appid>, CFG_OIPI**<username>, CFG_OIPI*<appid>*<username> ) on both the working and non-working systems?
- Bryan Shumsky
At 26 JUL 2023 06:08PM Greg Helland wrote:
Bryan,
Thanks for pointing me in that direction. CFG_OIPI was a null record. I know I set it to VSPRINTER2 as there was another issue related to that earlier. Either way, put VSPRINTER2 in field 1 and all works well.
Thanks so much!!!!!
Thanks
Greg