Hello,
I'm not sure if this does what you need, but you can run the request page separately like this:
OnRun()
Parameters := REPORT.RUNREQUESTPAGE(1);
MESSAGE(Parameters);
//(Parameters is a Text variable)
Then in the code you can afterwards decide whether to print or safeaspdf or some other action.
That's just one idea.