Learning Salesforce Visual Workflow - Rakesh Gupta - E-Book

Learning Salesforce Visual Workflow E-Book

Rakesh Gupta

0,0
39,59 €

-100%
Sammeln Sie Punkte in unserem Gutscheinprogramm und kaufen Sie E-Books und Hörbücher mit bis zu 100% Rabatt.
Mehr erfahren.
Beschreibung

Learning Salesforce Visual Workflow is intended for those who want to use Flows to automate their business requirements by click not code. Salesforce maintains an incredibly user-friendly interface; no previous experience in computer coding or programming is required.

Das E-Book können Sie in Legimi-Apps oder einer beliebigen App lesen, die das folgende Format unterstützen:

EPUB
MOBI

Seitenzahl: 278

Veröffentlichungsjahr: 2015

Bewertungen
0,0
0
0
0
0
0
Mehr Informationen
Mehr Informationen
Legimi prüft nicht, ob Rezensionen von Nutzern stammen, die den betreffenden Titel tatsächlich gekauft oder gelesen/gehört haben. Wir entfernen aber gefälschte Rezensionen.



Table of Contents

Learning Salesforce Visual Workflow
Credits
Foreword
About the Author
About the Reviewers
www.PacktPub.com
Support files, eBooks, discount offers, and more
Why subscribe?
Free access for Packt account holders
Preface
What this book covers
What you need for this book
Who this book is for
Conventions
Reader feedback
Customer support
Downloading the example code
Errata
Piracy
Questions
1. Getting Started with Visual Workflow
Business problems
Business use case 1
Solution 1 – using an Apex trigger
Solution 2 – a combination of Visual Workflow and Process Builder
Business use case 2
Solution 1 – using Apex
Solution 2 – a combination of Visual Workflow and Process Builder
The benefits of Visual Workflow
System requirements for using Visual Workflow
An overview of the Visual Workflow lifecycle
An overview of the Cloud Flow Designer
An overview of the building blocks of Visual Workflow
Flow elements
Flow resources
Flow connectors
The various ways to invoke a Flow
Summary
2. Creating Flow through Point and Click
Creating the building blocks of Flow
Creating a variable
Creating a collection variable
Adding values to a collection variable
Creating an SObject Variable
Creating an SObject Collection Variable
Designing the Flow
Creating a Salesforce Developer account
Logging in to Salesforce.com
Hands on 1 – displaying logged-in user ID
Creating a Screen element
Adding fields to the Screen element
Removing fields from the Screen element
Setting the Start element in a Flow
Saving a Flow
Running a Flow
Hands on 2 – real estate commission calculator
Connecting the Flow elements
Hands on 3 – displaying a feedback form based on conditions
Adding a Decision element
Adding a choice to a Flow
Hands on 4 – displaying related records based on search functionality
Adding a dynamic choice to a Flow
A few points to remember
Exercises
Summary
3. Manipulating Records in Visual Workflow
Creating the building blocks of a Flow
Creating a Constant
Creating a Text Template
Manipulating the data
Hands on 1 – creating leads
Adding the Record Create element to a Flow
Hands on 2 – adding leads to a campaign
Adding a record to a parent
Activating a version of a Flow
Passing values to Flow variables through a URL
Setting the finish location or redirecting the URL for a Flow
Hands on 3 – quickly update an account record
Adding Record Update elements to a Flow
Hands on 4 – cleaning Chatter group feed
Adding the Record Delete element to a Flow
Hands on 5 – adding Flow to the home page layout
Saving Flow as a different version
Adding the Record Lookup element to a Flow
Hands on 6 – adding an image to Display Text
Hands on 7 – saving data from a feedback form
Hands on 8 – sending an e-mail
Hands on 9 – creating a custom error message
Hands on 10 – conditional execution of a Flow with JavaScript
A few points to remember
Exercises
Summary
4. Debugging and New Ways to Call a Flow
Debugging your Flow
Onscreen debugging
Inbuilt debugging tools
Using debug screens
Debug log
Setting the debug log filter
Who can run the Flow and how
Debugging insufficient privileges on the custom button/link
Embed a Flow into a Visualforce page
Invoke a Flow using Process Builder
Automating your business process
Hands on 1 – copying the record followers
Adding the Fast Lookup element to a Flow
Adding the Loop element to a Flow
Adding an Assignment element to a Flow
Adding the Fast Create element to a Flow
Hands on 2 – open a Flow for unauthenticated access
Customizing the Flow user interface
Hands on 3 – setting the finish behavior in the Visualforce page
Using the URLFOR function
Using the $Page variable
Using a controller
Hands on 4 – accessing a Flow through Salesforce1
Through the Salesforce1 navigation menu
Through publisher actions
Hands on 5 – setting the Flow variables value from a Visualforce page
Without a controller
With the standard controller
With the custom controller
Call a Flow using the custom controller
Hands on 6 – invoking a Flow using an Inline Visualforce page
Hands on 7 – using a Flow to save the data from the Visualforce page
A few points to remember
Exercises
Summary
5. Developing Applications with Process Builder
An overview of Process Builder
Business problems
An overview of the Process Builder user interface
Actions available in Process Builder
Differences between Process Builder and other tools
Creating applications with Process Builder
Hands on 1 – autocreate a child record
Creating a Process
Adding an object and evaluation criteria
Adding Process criteria
Adding an action to a Process
Activating a Process
Deactivating a Process
Deleting a Process
Hands on 2 – auto update child records
Hands on 3 – cloning a Process
Adding an Apex plugin to your Process
Hands on 4 – posting opportunity details to the Chatter group
Hands on 5 – sending an e-mail to the opportunity owner
Hands on 6 – checking time-dependent actions from Process Builder
Hands on 7 – submitting a record to the Approval Process
Hands on 8 – calling a Flow from Process Builder
A few points to remember
Exercises
Summary
6. Building Applications without Code
Distributing or deploying Flows and Processes
Hands on 1 – deploying using Change Sets
Creating an unmanaged Package
Viewing the Flow created by Process Builder
Hands on 2 – displaying messages after login
Adding a Login Flow
Hands on 3 – setting the Login Flow finish behavior
Hands on 4 – understanding Subflow and the Wait Element
Creating a master Flow
Adding a Subflow element to a Flow
Hands on 5 – adding a Wait element to a Flow
Launching the Flow from Process Builder
Hands on 6 – using custom settings in a Flow
Launching the Flow from Process Builder
Hands on 7 – creating schedule jobs using a Flow
Hands on 8 – creating a recurring job using time-dependent workflow and Process Builder
Hands on 9 – queuing a job for the next day
A few points to remember
Exercises
Summary
Index

Learning Salesforce Visual Workflow

Learning Salesforce Visual Workflow

Copyright © 2015 Packt Publishing

All rights reserved. No part of this book may be reproduced, stored in a retrieval system, or transmitted in any form or by any means, without the prior written permission of the publisher, except in the case of brief quotations embedded in critical articles or reviews.

Every effort has been made in the preparation of this book to ensure the accuracy of the information presented. However, the information contained in this book is sold without warranty, either express or implied. Neither the author, nor Packt Publishing, and its dealers and distributors will be held liable for any damages caused or alleged to be caused directly or indirectly by this book.

Packt Publishing has endeavored to provide trademark information about all of the companies and products mentioned in this book by the appropriate use of capitals. However, Packt Publishing cannot guarantee the accuracy of this information.

First published: April 2015

Production reference: 1240415

Published by Packt Publishing Ltd.

Livery Place

35 Livery Street

Birmingham B3 2PB, UK.

ISBN 978-1-78528-983-5

www.packtpub.com

Credits

Author

Rakesh Gupta

Reviewers

Chris Edwards

Michael Gill

Jeff May

Commissioning Editor

Priya Singh

Acquisition Editor

Tushar Gupta

Content Development Editor

Gaurav Sharma

Technical Editor

Siddhi Rane

Copy Editors

Merilyn Pereira

Vikrant Phadke

Aarti Saldanha

Project Coordinator

Harshal Ved

Proofreaders

Bridget Braund

Safis Editing

Maria Gould

Indexer

Monica Ajmera Mehta

Production Coordinator

Conidon Miranda

Cover Work

Conidon Miranda

Foreword

One of the undeniable trends of the 21st century has been "data is king". Our ability to collect and store data is reaching new heights every year. In 2000, companies knew who their customers were and how to contact them by phone, fax, or e-mail. In 2015, we have the technology to not only know who our customers are, but what each customer is doing with our products. Customers can submit feedback and help with requests with the click of a button, and there are "service needed" alerts built into products and equipment in nearly all industries. The "Internet of Things" allows a level of data collection that far exceeds our ability to review and respond.

Successful businesses know that the only thing worse than not knowing what your customers and products need is knowing but not doing anything about it. Data interpretation and response are just as important as collection and analysis. One of the most effective ways to ensure an appropriate and timely response is to let our business technology systems react to the data using the same business rules we would apply if we had the time to review the data ourselves.

This book, Learning Salesforce Visual Workflow, teaches Salesforce administrators how to use the business process automation features available in Salesforce to do just that—detect and react to data as it's being collected by your employees, your customers, and your products. These powerful tools can be configured by admins (no development teams and custom coding needed), maintained by admins, and be quickly modified to meet the ongoing needs of your business.

Salesforce, a leading global business technology platform, knows that the key to their customers' success is the ability to understand and interact with data. With three releases each year, Salesforce consistently adds and enhances features that help maximize the value of each piece of data and customer contact. The Spring '15 release was no exception. Enhancements to Visual Flow and the introduction of the powerful new Process Builder put even complex business process automation into the hands of non-programming system administrators.

The author, Rakesh Gupta, is a long-time veteran of the IT industry and has been part of the evolution, from raw data collection to information analysis. His previous books explain how to collect and share data using the Salesforce platform and also how to report and analyze that data. With this book, Rakesh adds another key piece to the data–to-information cycle: data interpretation and response.

Using the techniques explained in this book, Salesforce administrators will be able to provide truly responsive business processes to their operational teams—putting data in the right format, in front of the right people, and at the right time—all without developing custom code.

Jeff May

Salesforce MVP and Partner @ Miss The Iceberg

About the Author

Rakesh Gupta is a Salesforce MVP, evangelist, trainer, blogger, and an independent Salesforce consultant. He is from Katihar, Bihar, and lives in Mumbai. He has been working on the Force.com platform since 2011. Currently, he is working as a Salesforce consultant and is a regular contributor to the Salesforce Success Community. He is the coauthor of Developing Applications with Salesforce Chatter and Salesforce.com Customization Handbook, both by Packt Publishing, and he is also a technical reviewer of Learning Force.com Application Development, Packt Publishing. He has written over 70 articles on Flow and Process Builder to show how someone can use them to minimize code usage. He is one of the Flow experts in the industry. He is very passionate about Force.com and shares information through various channels, including his blog at http://rakeshistom.wordpress.com.

He has trained almost 200+ professionals around the globe and conducted corporate trainings. He has 5x certifications in Salesforce. He works on all aspects of Salesforce and is an expert in data migration, integration, configuration, and customization. He is the leader of the Navi Mumbai and Nashik developer user groups in India. He is also the initiator of the Mumbai Salesforce User Group. He organizes meetups at regular intervals for the groups he is part of.

He can be reached at <[email protected]>, or you can follow him on Twitter at @rakeshistom.

I would like to thank my parents, Kedar Nath Gupta and Madhuri Gupta, and my sister, Sarika Gupta, for supporting me in every step of my life. I would like to thank Packt Publishing for giving me this opportunity to share my knowledge via this book. I would also like to thank my friend Meenakshi Kalra for taking care of me while I was writing this book. A special thanks to all my well-wishers and friends. I would also like to thank Jeff May (Salesforce MVP), Chris Edwards (Salesforce MVP), and Michael Gill (Salesforce MVP) for reviewing the book and for providing valuable suggestions.

About the Reviewers

Chris Edwards is a Salesforce MVP and an experienced system administrator and consultant. He has been working on the Salesforce platform for 5 years and in that time has earned the following certifications: Administrator, Advanced Administrator, Developer, Sales Cloud Consultant, and Service Cloud Consultant. He is an organizer of the London Admin User Group and coauthors the popular blog, http://www.salesforceweek.ly/.

Chris has worked for end users in a variety of industries, and is also a freelance consultant helping businesses to implement, customize, and extend their use of Salesforce.

I'd like to thank my wife, Natalie, for her infinite patience and for keeping our lives on track while I had my head stuck in a laptop.

Michael Gill has spent a decade consulting in Cloud, helping customers adopt and use platforms such as NetSuite and Salesforce.com. He has been focused on Salesforce.com since 2009 and holds these Salesforce certifications: Administrator, Advanced Administrator, Sales Cloud, Service Cloud, and Developer. Michael was awarded Salesforce MVP Winter '15 for his exceptional leadership, knowledge, and ongoing contributions to the ecosystem. He co-writes the highly popular Salesforceweek.ly (http://www.salesforceweek.ly/) blog dedicated to all things Salesforce. He is incredibly active across the Salesforce community, co-organizing the London Salesforce Admin User Group as well as solving problems on the Success Community and developer boards. He has worked with a range of companies and Salesforce platinum partners and is currently working with FireEye on a global Salesforce implementation.

I'd like to give special thanks to my wife, Asha, who has tirelessly continued to supported me throughout my Salesforce journey.

Jeff May is an independent consultant and Salesforce MVP specializing in small business deployments and adoption of Salesforce.com and related business processes. His clients rely on his 25-year software engineering and business background to help them clarify their business goals, identify technology needs, and then design and deploy effective and scalable Salesforce configurations to support those goals. When he's not working with clients, you can find Jeff on the Salesforce Success Community, collaborating with other admins and users. You can learn more about Jeff and his business at http://misstheiceberg.com/.

www.PacktPub.com

Support files, eBooks, discount offers, and more

For support files and downloads related to your book, please visit www.PacktPub.com.

Did you know that Packt offers eBook versions of every book published, with PDF and ePub files available? You can upgrade to the eBook version at www.PacktPub.com and as a print book customer, you are entitled to a discount on the eBook copy. Get in touch with us at <[email protected]> for more details.

At www.PacktPub.com, you can also read a collection of free technical articles, sign up for a range of free newsletters and receive exclusive discounts and offers on Packt books and eBooks.

https://www2.packtpub.com/books/subscription/packtlib

Do you need instant solutions to your IT questions? PacktLib is Packt's online digital book library. Here, you can search, access, and read Packt's entire library of books.

Why subscribe?

Fully searchable across every book published by PacktCopy and paste, print, and bookmark contentOn demand and accessible via a web browser

Free access for Packt account holders

If you have an account with Packt at www.PacktPub.com, you can use this to access PacktLib today and view 9 entirely free books. Simply use your login credentials for immediate access.

Preface

We wrote this book for Salesforce developers, administrators, customers, and partners to get started with Salesforce Visual Workflow and Process Builder. Salesforce Management System is an information system used in CRM to automate business processes such as sales and marketing. Visual Workflow is another way to develop applications in Salesforce using click not code. This is a powerful tool developed by Salesforce to automate business processes by creating applications (also called Flows). This book will act as both a reference for the administrator and a configuration guide for the newbie customer who wants to develop applications in Salesforce without code, using Process Builder and Flow.

This book covers all the possible features of Flow and Process Builder in Salesforce. We have used a hands-on approach in a real-time scenario so that you get a full overview of those topics. At the end of every chapter, you will find key points and exercises for practice. Salesforce CRM is a service by Salesforce.com, which is available commercially, but all the material in this book is developed using its Developer Edition. This book covers features till the Spring '15 release.

What this book covers

Chapter 1, Getting Started with Visual Workflow, gives basic knowledge of Salesforce Visual Workflow. We will pick up a few business examples and see how to use a Flow instead of Apex code to solve it, and we will also discuss the benefits of using Salesforce Visual Workflow. We will also have an overview of the Flow canvas and its elements.

Chapter 2, Creating Flow through Point and Click, describes the various variables available in the Flow. We will then proceed towards designing the Flow using the Screen, Wait, Assignment, and Decision elements.

Chapter 3, Manipulating Records in Visual Workflow, discusses the Constant and Text Template in the Flow. We will then proceed towards the manipulation of data using Record elements, and we will also see how to send an e-mail from the Flow. We will also cover various ways to access the Flow.

Chapter 4, Debugging and New Ways to Call a Flow, serves as the climax to the book, where you will gain knowledge of how to debug and launch a Flow. We will also cover various ways to set the Flow variable using Visualforce pages and Apex.

Chapter 5, Developing Applications with Process Builder, enables you to gain a complete understanding of the Process Builder designer and all available actions inside it.

Chapter 6, Building Applications without Code, gives you the enough idea how you can develop complex applications using Flow. We will also cover key elements such as Login Flow, using the Wait element in the Flow. We will also cover how you can use custom settings in the Flow and create a scheduled job that will run on a daily basis.

What you need for this book

Visual Workflow is available in Enterprise, Performance, Unlimited, and Developer Editions. The requirements are as follows:

Windows Internet Explorer versions 8 through 11 (6 and 7 are not supported), Google Chrome, or Mozilla FirefoxAdobe Flash Player Version 10.1 and later, the minimum version required to run the Cloud Flow Designer is 10.0A minimum browser resolution of 1024 x 768

Who this book is for

The book is written for anyone who is a newbie or an experienced professional in the Salesforce arena and wants to learn about or explore the various tools available in Salesforce to automate business processes by using click not code.

Reader feedback

Feedback from our readers is always welcome. Let us know what you think about this book—what you liked or disliked. Reader feedback is important for us as it helps us develop titles that you will really get the most out of.

To send us general feedback, simply e-mail <[email protected]>, and mention the book's title in the subject of your message.

If there is a topic that you have expertise in and you are interested in either writing or contributing to a book, see our author guide at www.packtpub.com/authors.

Customer support

Now that you are the proud owner of a Packt book, we have a number of things to help you to get the most from your purchase.

Downloading the example code

You can download the example code files from your account at http://www.packtpub.com for all the Packt Publishing books you have purchased. If you purchased this book elsewhere, you can visit http://www.packtpub.com/support and register to have the files e-mailed directly to you.

Errata

Although we have taken every care to ensure the accuracy of our content, mistakes do happen. If you find a mistake in one of our books—maybe a mistake in the text or the code—we would be grateful if you could report this to us. By doing so, you can save other readers from frustration and help us improve subsequent versions of this book. If you find any errata, please report them by visiting http://www.packtpub.com/submit-errata, selecting your book, clicking on the Errata Submission Form link, and entering the details of your errata. Once your errata are verified, your submission will be accepted and the errata will be uploaded to our website or added to any list of existing errata under the Errata section of that title.

To view the previously submitted errata, go to https://www.packtpub.com/books/content/support and enter the name of the book in the search field. The required information will appear under the Errata section.

Piracy

Piracy of copyrighted material on the Internet is an ongoing problem across all media. At Packt, we take the protection of our copyright and licenses very seriously. If you come across any illegal copies of our works in any form on the Internet, please provide us with the location address or website name immediately so that we can pursue a remedy.

Please contact us at <[email protected]> with a link to the suspected pirated material.

We appreciate your help in protecting our authors and our ability to bring you valuable content.

Questions

If you have a problem with any aspect of this book, you can contact us at <[email protected]>, and we will do our best to address the problem.

The benefits of Visual Workflow

There are certain benefits of using Visual Workflow. They are as follows:

It allows you to create an automated business process using click not code.Visual Workflow does not require coding, and even if you do not know Apex code you can still develop business processes.Using screens, fields, and choices, you can implement complex business processes to make sure that your users are entering data in the right format.Through Visual Workflow, you can manipulate data for certain objects that are not available for the Workflow rule. For example, when a "contact role" is created or updated as primary for an opportunity then create a new task.It allows you to auto submit records for approval.You can post messages on Chatter. For example, if opportunity status gets Closed Won, post a message on Chatter group.It allows you to embed the Flow into the Visualforce page and using the Force.com Site you can expose it for unauthenticated access.Once you embed your Flow into the Visualforce page, it allows you to use HTML, CSS, JavaScript, and other Visualforce components.It can be easily maintained by non-developers.Since it is not code, you don't need to write test classes.You can make changes directly to your production organization, just like other configuration changes.Every time unhandled processes fail or an error occurs in the Flow, the author will get an e-mail from Salesforce with the error details.Using the debug log you can debug your Flow. Visual Workflow also has a built-in debugging tool. To open the debug window, press Ctrl + Shift + M (on PC) or command + shift + M (on Mac).It allows you to invoke the Apex class that implements the Process.Plugin interface.

System requirements for using Visual Workflow

Visual Workflow are available for Enterprise, Performance, Unlimited, and Developer Editions. You can access Flow on any platform. The requirements are as follows:

Windows Internet Explorer versions 8 through 11 (6 and 7 are not supported), Google Chrome, or Mozilla Firefox.Adobe Flash Player Version 10.1 and later. The minimum version required to run the Cloud Flow Designer is 10.0.A minimum browser resolution of 1024 x 768.

An overview of the Visual Workflow lifecycle

The Cloud Flow Designer is a tool to create Flows, configure screens, and define business logic for your Flows without writing a single line of code. Visual Workflow has three different parts, these are as follows:

Design: This allows you to create the Flows using the Flow Designer, which has a drag and drop user interface that allows you to draw the Flow structure and configure how it runs, without writing a single line of code.Administration: Once you have created a Flow, you can manage it, edit its properties, activate, deactivate, delete, save as a new version or new Flow, or run it as well.Runtime: A Flow user can run the active Flow from a custom button, link, Visualforce page or directly from the Flow URL. If it is autolaunch Flow, then systems can run active Flows through Process Builder or an Apex class.

An overview of the Cloud Flow Designer

The Cloud Flow Designer is a tool that allows you to implement business requirements by constructing Flows (without any code); this is a way to collect, update, edit, and create data in Salesforce. The Cloud Flow Designer user interface has different functional parts.

These functional parts are as follows:

The button bar: You can use Save, Save As, Run, Run with Latest, Close, undo, and redo changes to run or view properties of your Flow buttons available in the button bar. The status indicator marked in the red rectangle on the right-hand side of the bar shows the status (Active or Inactive) of your Flow.
Save: Use this option to save/quick save your Flow.Save As: If you want to clone the Flow you are working on or save as a new version, then use this option.Run: This runs the most recent version of the Flow you are working in. If the Flow comprises subflow elements, then each subflow