I am using the login flow which has been released as part of Winter'15 release. I would like to pass the geolocation of the logged in person (using javascript HTML5 Geolocation API) to visual flow as two variables, one for longitude and one for latitude. Based on the location of the logged in person, I would like to default a custom object based select list with the nearest store.

Would like to seek your guidance if we can pass two javascript parameters into visual flow ("login flow").



See Global Variables in the Visual Workflow Guide. You can access $User, $Profile, etc from within a flow. That information can be passed to the log-in controller and presumably into your flow.

If you use js remoting, it would be available in the controller from your javascript. To the best of my knowledge, latitude and longitude aren't currently standard fields on User, so you'd need to create custom fields to hold them in order to pass them into your flow.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.