salesforce - Call visualforce Page through scheduled apex -
I have a scheduled class that I would like to work in such a way that it is called a visible page that does things for the record is . At present the user has to click the button on separate records which call the visible page. I want to run it and execute it for scheduled Apex. Here is what I have so far. I named the visualforce page as a place holder for now. Any guidance would be very commendable!
Global Level LastLoginUpdate's Implementable {Global Zero Execution (Scheduled Consultant SC) {List & lt; Case & gt; CASE = [SELECT ID, STATUS, Qi_FROCIVICICCC, from where the status = 'be billed']; (Case C: Case) {if (C.Stats == 'To be billed') {// Call CreateTraccInvoice; }} Updated cases; Instead of calling the page,
}}
In the controller class, the action method must be executed which is responsible for that page. If you look at the page you are mentioning, you can see the & lt; Apex: page controller = "myController" ...
where myController is the name of the
category containing the logic for that page as long as you were talking about that button , It is a standard action (such as Save or Delete), that is a custom action defined in that controller class and it is linked to the button you specify action = "..."
Now that you know the controller action that is responsible for handling a button click, you have to make an example of that controller in your set square, To begin with the case ID and call that action programmers. / P>
In order to make PS solutions and future proofs and to reuse the existing action and execute the DML statement for each individual case rather than to avoid the borders of the governor, your scheduled class Repeat the argument of the action function in the revision, then consider revising it so that it can handle the list of cases as an input.
Comments
Post a Comment