subesse
26th February 2019, 09:36
Hi,
Is it somehow possible to ask a question in a reportscript?
We do not have a developerslicense. And do a lot of scripting in the reportscript.
But now have to ask the user some value, like bookyear. Is it possible to ask this in reportscript, in for example BEFORE.PROGRAM?
tmannais
26th February 2019, 12:09
You should have asked the user in the session before printing the report.
Is it not suitable for your requirement?
günther
26th February 2019, 12:42
It is possible (took me 2 minutes to verify that). Why didn't you try it yourself?
And here is my solution that can also be used in a report script:
#pragma used dll ottdllinputstr
before.program:
long rc
string str(4)
rc = input.string("title", "year", 4, 4, str)
message("rc=%d str=%s", rc, str)
Regards
Günther
bdittmar
26th February 2019, 19:47
Hi,
Is it somehow possible to ask a question in a reportscript?
We do not have a developerslicense. And do a lot of scripting in the reportscript.
But now have to ask the user some value, like bookyear. Is it possible to ask this in reportscript, in for example BEFORE.PROGRAM?
Hello,
by using the SEARCH function for inputstring" in forum:
http://www.baanboard.com/baanboard/showthread.php?t=60818&highlight=inputstring
Regards
cmartin
4th March 2019, 14:09
Can you use Programmable dialogs?
In case you are using LN I would recommend you writing this dialog as an extension of session.
http://www.baanboard.com/programmers_manual_baanerp_help_functions_programmable_dialogs_synopsis
vamsi_gujjula
5th March 2019, 19:39
Programmable dialogs....I did that for one of the stadard report ... though field validation part of dialog box did not work .
The only issue on LNUI is if there is no record to be printed ( post filtering in the report script) killing the report hangs the LNUI process where as it works perfectly on becs / worktop..
cmartin
6th March 2019, 09:59
Programmable dialogs....I did that for one of the stadard report ... though field validation part of dialog box did not work .
The only issue on LNUI is if there is no record to be printed ( post filtering in the report script) killing the report hangs the LNUI process where as it works perfectly on becs / worktop..
How do you do the post filtering in report script?
Do you redefine r.write.seq.file() as described here http://www.baanboard.com/baanboard/showthread.php?t=9090 and just dont call ORIGINAL.FUNCTION() ?
vamsi_gujjula
6th March 2019, 16:47
depending on the dialog selection , as per the requirement we can suppress the layout. using predefined variable lattr.print set to false.
cmartin
8th March 2019, 11:13
depending on the dialog selection , as per the requirement we can suppress the layout. using predefined variable lattr.print set to false.
We got the same problem with LNUI stopps working when killing the report.
If you overwrite the function r.write.seq.file it will just disappear with the message "No data within selection".