Solved

Can i create an event to restart print jobs in error?

  • 18 May 2020
  • 6 replies
  • 202 views

Userlevel 6
Badge +11

We have an issue with Crystal Web services which we are looking into, but I want to create an event that would fire when a print job goes into a status of ‘Error’ - the action being to ‘Restart’ the job (As you can do manually with an RMC.

Just want to automate this re-try for the time being.

I have created an event on the ‘Printjob’ logical unit, but not sure how to make it fire and perform the  restart action. Any tips??

Am trying to make this fire when the message ‘No PDF returned from Crystal Web Service’

Thanks

icon

Best answer by eqbstal 19 May 2020, 20:02

View original

6 replies

Userlevel 4
Badge +9

Alternativly you can likely create a scheduled database task which runs every x minutesfor a source data migration job that can identify which are in error and run the same command as the rightclick. 

Userlevel 6
Badge +11

Yep that sounds great, question is how can i set that up?

Userlevel 7
Badge +21

BLLBrucemo,

What might be a solution, in connection with what JULIAN correctly offered, is to fire the event on print_job. Based upon the status, you create a new row in a new conversion list. This conversion list can be prepared in the Data Migration basic data. In the old value the print_job_id can be inserted, the new value will contain what ever values you want to have from the print job information. If you store the values in field New value with delimiters, you can use those fields to prepare a where clause in the migration job. This reads the conversion list and only based upon the new value content the migration job is running. 

I think that I would generate a request to print the report (no idea how you would do that, but with some searching you will find your way).

The migration job can be scheduled and you will be able to delete the information processed from the conversion list, when you created a print request.

This is not for the faint harts. Success.

Hope this helps,

Steve

Userlevel 4
Badge +9

Yep that sounds great, question is how can i set that up?

As a start identify the data source. I.e. Make the select statement that gives you the lines which need to be restarted. 
also you need to find the function that runs when you manually right click and restart. (This you can likely find with the debugger).

 

after this there is setting up the migration job, and obce that works that can be sxheduled but suggest you start with the first two items. (Select statenent and function)

Userlevel 7
Badge +21

Pff, sounds to me that it is cheaper, easier to monitor frequently and restart manually. If I would have to prepare something like that I would say that it would take me roughly 4 days of which the testing will take the most time (as it seems that the report not always runs into an error).

Steve

Userlevel 6
Badge +11

Thank you all for your input - greatly appreciated. I think as you mention eqbstal - it could be more work than needed. Especially as the Crystal issue appears to be relatively in-frequent. I think I will just add a lobby element to monitor the jobs quickly.

Pleased its do-able though!

 

Thanks guys!

Reply