自动化提示示例
- Updated: 2025/09/17
Co-Pilot for Automators (Co-Pilot) 在输入以下有关自动化开发中常见趋势的示例提示时,可创建最佳输出。
考虑复制以下列表中的提示,并修改个别细节,以便根据自己的自动化需求定制输出。
Bot editor 中的提示示例
-
Open a folder. Loop through each file. Copy the file names and add it in an excel file.
-
Connect to database using myname/mytoken account.
-
Connect to Salesforce using the ConnectionName Control Room OAuth connection.
注: 确保您已在 Control Room 连接中成功配置并保存此连接。 -
Open browser google.com
-
Create a bot that sends email to $EmailTo$, CC $EmailCC$, from $EmailFrom$, subject 'Bot Started', message 'The bot has now started.'
-
Run excel macro "TestMacro" on C:\Temp\MacroFile.xls. Then switch to excel Main worksheet and get all cells.
-
Prompt for the user to select the folderpath. Loop through the selected folder including subfolders. If any excel file is found, then check for the worksheet ‘Main’. If available save it as a PDF in the same folder.
-
此示例呈现出一种自动化,该自动化分析 Salesforce 中的记录,并将每条 Salesforce 记录的数据添加到现有数据库中。 当记录包含电子邮件时,自动化将发送电子邮件;当记录没有电子邮件时,自动化将添加注释。 此外,如果在运行时发生错误,自动化将显示一条消息。
Get records from Salesforce. For each Salesforce record, insert a record into the database. If the record contains an email, send an email. If not, add a comment. If an error occurs when the bot performs these operations show a message box.
为清晰起见,将多个操作分开: 此示例展示了一个复杂的场景,其中详细介绍了不同的操作,以表达数据的协调性。 有序数字有助于指定顺序,并指示 Co-Pilot 在渲染时按顺序排列这些操作。
Add try catch action. 1. Add SAP connect action with connectivity type as SAP SSO. 2. Send enter as SAP vertual key. 3. Add Delay of 3 ms. 4. Enter the delivery number 858484 by adding the SAP set text action. Field path is wou/tur. 5. Send F7 as SAP virtual key. 6. If window does not exist, update the 'status' column in the excel workbook as 'Invalid' by using Set cell action, else store the Invoice number to the variable using SAP get text action for from field path xyz/abc.
-
此示例查找符合指定条件的电子邮件,并将这些电子邮件移动到现有的指定文件夹。
Move all emails to 'Finance' folder if attachments have any PDF file and the sender is 'finance@aai.com'.
-
此示例呈现一种自动化,该自动化使用电子邮件软件包连接并保存由已建立的 Salesforce 联系人专门发送的电子邮件。 此提示指定使用电子邮件软件包,而不是 Outlook 软件包,并依赖于该用户电子邮件账户中已有的 Salesforce 列表。
Connect to Outlook with email package, save any email to 'c:\temp\MyEmails' if the sender matches the email of any contact in the Salesforce list.
-
此示例查找符合指定条件的电子邮件,并将电子邮件保存在指定路径,然后从电子邮件文件夹中删除这些电子邮件。
Backup all emails from HR folder to c:\temp\ExternalEmails if the domain of the sender is 'chad@automationanywhere.com', then delete from the folder.
-
Authenticate sharepoint with Client ID as $ClientID$, Client Secret as $ClientSecret$, Tenant ID as $TenantID$.
-
Create sharepoint folder COPILOT at /SiteName/Folders/FA.
-
Upload file to Sharepoint.
-
If response is A, connect to database and read data. Else, send email to $EmailTo$.
-
If response is A, connect to database and read data. Else if response is B, open www.google.com. Else, send email to $EmailTo$.
-
Use Excel Advanced package to load the data from 'SalesData.xlsx' located in the 'C:\Reports' folder. Write this data into XYZ oracle database.
-
Prompt user for two folders. Loop first folder to find excel files and copy them to second folder.
-
Create a bot to copy data from a table in database to excel.
-
此示例呈现了一种自动化,该自动化基于目标列中的值自动创建一个新的 csv 文件,其中包含指定的两个 csv 文件中的所有匹配结果。
Combine two csv 'a.csv' and 'b.csv' from the folder at c:\temp by using the column AccountNo. Save only the matching result to 'c.csv'.
-
此示例呈现一种自动化,该自动化将指定供应商发送的 Excel 附件保存到指定文件夹。
Read emails from the vendor 'jsmith@aa.com' and save attachments of their emails to the folder c:\temp. Only include the files with .xlsx extension.
-
此示例根据目标列创建一个新的 csv 文件,其中包含 Excel 文件和 csv 文件中的所有值。
Combine the excel file 'a.xslx' and the csv 'b.csv' file from the folder at c:\temp by using the column AccountNo. Save all matched and unmatched results to 'c.csv'.
-
Copy the data from the excel file 'a.xlsx' into the excel file 'b.xlsx' for all the worksheets that have matching sheet name.
-
此示例呈现了一种自动化,该自动化为满足指定条件的每一行运行一个宏,而对于不满足条件的行,则将该数据复制到另一个指定的 excel 文件中。
Run macro 'UpdateVendorData' if B2 is 'Pending' in c:\VenderData.xlsx 'Info' tab. Otherwise copy all the data to c:\TodaysVendorData.xlsx.
-
Open excel C:\temp.xlsx. When error occurs, send an email tome@myorg.com.
-
Open excel C:\temp.xlsx and get all rows. If error occurs when performing these operations, send an email.
-
Add try-catch.
-
Add error handler.
Process Composer 中的提示示例
-
Create a new customer profile in the CRM system. The name, email address, and phone number will be provided by a user via a form.
-
Read the list of automotive parts from a pdf using a document automation task, use a bot to search these parts in a website, and email the collected information.
-
Start with a form to enter patient information. Then filter out patients that are 75 years old and older. Finally, add a bot to save the information in an excel spreadsheet.
-
Get data from an invoice. If the name starts with "new", check the price. If the price is above 1000, send an email and If the price is below 500, then go to the first task. Otherwise, save the data to Excel file. If the invoice doesn't start with new, validate the document.
-
Add a form task for EntryForm.
-
Add a bot task for botInput.