How to Send Weekly Scheduled Emails of a Custom View

How to Send Weekly Scheduled Emails of a Custom View

Greetings,

We have a custom view called "All Employee View" for the Employee form.

We are able to manually export that view using the "Export" button:


However, we want to programmatically export this view as an XLS file each week and send it in an email attachment. For this, I tried the following Scheduler Deluge code, but the viewId part to get the data as in the custom view is not working.

  1. report = Map();
  2. report = zoho.people.getRecords("P_Employee",0,200,{"cvid":"<viewId from the URL>"});
  3. myfile = report.toFile("myfile.csv");
  4. sendmail
  5. [
  6. from :zoho.loginuserid
  7. to :"<myemail>"
  8. subject :"test"
  9. message :report
  10. Attachments :file:myfile
  11. ]

Please let me know if I am on the right track.

Thanks.

      Zoho Campaigns Resources


        • Desk Community Learning Series


        • Digest


        • Functions


        • Meetups


        • Kbase


        • Resources


        • Glossary


        • Desk Marketplace


        • MVP Corner


        • Word of the Day


        • Ask the Experts


          • Sticky Posts

          • Meet the Zoho People experts in your city!

            Dear users,   We are delighted to invite you to the Zoho People's user community meetup. We are stoked to visit our users in their cities and help them with all things Zoho People.   Join us for a day of insightful Zoho sessions, interactions with other

          Zoho CRM Plus Resources

            Zoho Books Resources


              Zoho Subscriptions Resources

                Zoho Projects Resources


                  Zoho Sprints Resources


                    Zoho Orchestly Resources


                      Zoho Creator Resources


                        Zoho WorkDrive Resources



                          Zoho CRM Resources

                          • CRM Community Learning Series

                            CRM Community Learning Series


                          • Tips

                            Tips

                          • Functions

                            Functions

                          • Meetups

                            Meetups

                          • Kbase

                            Kbase

                          • Resources

                            Resources

                          • Digest

                            Digest

                          • CRM Marketplace

                            CRM Marketplace

                          • MVP Corner

                            MVP Corner




                            Zoho Writer Writer

                            Get Started. Write Away!

                            Writer is a powerful online word processor, designed for collaborative work.

                              Zoho CRM コンテンツ



                                ご検討中の方