官术网_书友最值得收藏!

Solution 1 - using Apex

We can't achieve this goal by the Workflow rule. For this, we have to write an Apex class that implements the Schedulable interface for the class and then use Schedule Apex to run it on a regular basis. The following is the code for this Apex class:

global class SendChatterEmail implements Schedulable 
{
global SendChatterEmail (){
// Batch Constructor
}

// Start Method
global Database.QueryLocator start(){
/* Use SOQL query to get the records you want to operate upon
select Id, fullPhotoUrl from User where isactive = true AND FullPhotoUrl like '%photo/005%'*/
}

// Execute Logic
global void execute(){
// perform the operation

}

global void finish(){
// Logic which we want to execute at finish
}
}
主站蜘蛛池模板: 桐乡市| 三亚市| 永寿县| 永定县| 泸溪县| 错那县| 台东县| 葵青区| 普定县| 彭山县| 仙桃市| 丰台区| 韶关市| 南康市| 吉林市| 洛南县| 始兴县| 平乡县| 昭觉县| 衡阳市| 无锡市| 阿尔山市| 石河子市| 眉山市| 大化| 盐源县| 垫江县| 晋江市| 宝鸡市| 清水县| 如东县| 罗田县| 定结县| 班戈县| 麦盖提县| 通州区| 阿瓦提县| 龙胜| 秀山| 三江| 日喀则市|