• Sébastien Richard
  • NEWBIE
  • 35 Points
  • Member since 2014
  • Entrakt Conseil Sébastien Richard EIRL


  • Chatter
    Feed
  • 0
    Best Answers
  • 1
    Likes Received
  • 27
    Likes Given
  • 2
    Questions
  • 12
    Replies
Hi,
I use Flow to get information from a Custom Setting that stores in the field "ChatterGroupIds" --format type  text(255) -- a list of id separated by comma.
I would like parse this field and split it in a collection to Loop and call Quick Action "CollaborationGroup.NewGroupMember" for each id of the collection. Is it possible with a Flow ?
To workaround, I tried to create an APEX class with an @InvocableMethod with text field as input and list of id as output but it seems impossible.
Thanks a lot for your help.
Hi,

I translated tabs, labels and custom fields in french on the sandbox.
I created Outbound Change Sets and add 'language translation' component in french.
I uploaded in production but the translation doesn't work.
Thanks in advance for your help.
Sébastien.
Hi,

I translated tabs, labels and custom fields in french on the sandbox.
I created Outbound Change Sets and add 'language translation' component in french.
I uploaded in production but the translation doesn't work.
Thanks in advance for your help.
Sébastien.
Hi,

Within a visual flow, I'm wondering if I can populate a collection variable using semi-colon separated values (;) in a single input text box. For the use case, I'd like to append an ad-hoc Taskray Checklist to a Taskray Task using only the flow interface, but as the items are ad-hoc, I can't use a template for it.

For example, if I input this in ONE long text field:
Apples;
Bananas;
Carrots;


Can I pass it into a collection variable using a loop so it is [Apples, Bananas, Carrots]?

I have simulated this by using LEFT({!Checklist}, FIND(";", {!Checklist}) - 1) to get the first row and adding it to the collection variable, trimming it from {!Checklist} and doing it again for the second row, etc. This creates the collection var as long as I stick to the number of assignments I've used.

But the problem is I can't figure out how to build it into a loop to handle variable number of items. Is there any way to do this using only flow tools?

Thanks in advance :)




 
(If should be posted to the developers forum I apologize - let me know and I'll post there instead.)

I can't set up my flow to receive a return value from an invocablemethod. :(

I'm building an Apex class named Temp that contains an invocablemethod named performApproval.  It returns a return code and string message through a custom object:
global without sharing class Temp {
	
    @InvocableMethod
    public static List<Apex_Result__c> performApproval(List<MyInvocableVariables> myVariablesList) {
		List<Apex_Result__c> resultList = new List<Apex_Result__c>();
		Apex_Result__c result = new Apex_Result__c();
		result.Return_Code__c = 1;
		result.Message__c = 'Testing';    	
		resultList.Add(result);
		return resultList;
	}

	global class MyInvocableVariables {
		@InvocableVariable(label='Opp ID' required=true) 
		global Id oppID; 		
	}
}
I call the method from a flow, and I defined an SObject collection variable named Results to receive the results of the call. However, when I attempt to specify that the method's output should go into that variable I only get the option to create a new variable:

Screenshot showing I only see Create New

Can anyone explain why I can't select an existing variable?  Even if I create a new variable it doesn't use it or allow me to select it.
I am on the last module of the Build a Discount Calculator trail. I have verified the first 4 steps and received the 50 points (everything was configured correctly). Now, when I try to verify my last step I am getting the following error:

Challenge Not yet complete... here's what's wrong: 
The 'Calculate Discount' custom button doesn't exist or isn't properly configured. Check the instructions.

I've verfied the creation of the button, it's on the correct page layout and I've tested the button- it gives me the correct discount percentage and discounted amount.

Any other ideas on what I should check? I'm at a loss.
Hi,

I translated tabs, labels and custom fields in french on the sandbox.
I created Outbound Change Sets and add 'language translation' component in french.
I uploaded in production but the translation doesn't work.
Thanks in advance for your help.
Sébastien.
I am trying to develop something for our production Customer Community in a Developer org.  I need Customer Community licenses for testing.  How do I get them?
Hi,

Is there a way to make the columns in this visualforce page sortable?  It's simply a page that displays the open tasks owned by the current user.

controller:
 
public class tasksController{
    
    List<Task> tk; 
      // toggles the sorting of query from asc<-->desc


    public tasksController(ApexPages.StandardController Controller){
     }  
     
    public List<Task> getResults(){     
        return tk;
    }         
    public PageReference gettk(){
        String userId=UserInfo.getUserId();
        UserId=userId.Substring(0,15);
        tk=[Select Status, Subject, Priority, OwnerId, Owner.Name, WhatId, Response_Needed__c,What.Name, WhoId, Who.Name, ActivityDate from Task WHERE 
             Status != 'Completed' AND (ActivityDate = THIS_WEEK ) AND OwnerId =: UserId ORDER BY ActivityDate DESC LIMIT 25  ];
        return Null; 
    }
}



visualforce page:
 
<apex:page standardController="Task" extensions="tasksController" action="{!gettk}">
<apex:form >
    <html>
    &nbsp;&nbsp;<img src="/img/icon/home32.png"/>
    <font size="5">&nbsp;&nbsp;My Open Tasks Due This Week</font><br></br>

<apex:pageblock >


                    <apex:pageBlockTable value="{!results}" var="tsk">
                                <apex:column >
                                    <apex:outputlink value="/{!tsk.Id}">{!tsk.Subject}</apex:outputLink>
                                    <apex:facet name="header"> Subject </apex:facet>                                                                                                       
                                </apex:column>
                                <apex:column > 
                                    <apex:outputField value="{!tsk.Response_Needed__c}" />
                                    <apex:facet name="header"> Urgency                                      
                                    <span class="helpButton" id="example-title-_help">
                                    <img src="/s.gif" class="helpOrb"/>
                                      <script type="text/javascript">
                                        sfdcPage.setHelp('example-title', 'RED: Task is overdue by 1 day or more or has no due date.  YELLOW: Task is due today.  GREEN: Task is due on some day in the future. ');
                                      </script>
                                    </span>                                                                                                       
                                    </apex:facet>                                                                      
                                </apex:column>                                
                                <apex:column >
                                    <apex:outputLink value="/{!tsk.WhoId}">{!tsk.Who.Name}</apex:outputLink>
                                    <apex:facet name="header"> Name</apex:facet>
                                </apex:column> 
                                <apex:column >
                                    <apex:outputLink value="/{!tsk.OwnerId}">{!tsk.Owner.Name}</apex:outputLink>
                                    <apex:facet name="header"> Assigned To </apex:facet> 
                                </apex:column>
                                <apex:column value="{!tsk.ActivityDate}"/>                                                                                                                                                                                                   
                                <apex:column value="{!tsk.Status}"/>  
                    </apex:pageBlockTable> 
                    
                    
                    <br></br>                 
                    <apex:outputLink target="_blank" value="https://cs15.salesforce.com/00Oe0000000Ta99" id="theLink">View All My Open Tasks</apex:outputLink>

 </apex:pageblock>
                   


    </html>
    </apex:form>
</apex:page>

 
  • December 16, 2014
  • Like
  • 0
cloud you please give me help for this Question

I retrive the data from account(using custom controller) object and display that data in datatable(vf) format this one is good.
but  here column name for example: name,industry,type,rating.
here whenever i click the name or industry ior any other field name I want to display sort order depending on that field.

Thanks
Naveen
Hi

can any one give the steps to approach this 
Update the parent field value based on child field value using workflows?

Hi,

 

I am trying to build a custom page, that display "Bulk API Jobs" in a data grid. I am using the following statement :

 

List<AsyncApexJob> jobs = [SELECT Id FROM AsyncApexJob];

 but it does not return anything. And when i go the page "https://xxxx.salesforce.com/750?setupid=AsyncApiJobStatus" i see my job in status "Open". 

Is it possible to do this kind of query on Bulk Jobs ? If not, is there a way to embeded the "Bulk Jobs List" inside a custom apex page ?

 

Xavier

  • June 24, 2013
  • Like
  • 1

Hi,

 

I would like to know if we can sort a Map by Value. I have a Map like below.

 

Map<Id, Integer> accMap = new Map<Id, Integer>();

 

e.g I have values in the Map like below

 

accMap.put('Id1' , 2);

accMap.put('Id2' , 1);

accMap.put('Id3' , 4);

accMap.put('Id4' , 3);

accMap.put('Id5' , 5);

 

Now i want the Map to be sorted by the Integer value and my output should be like below

 

accMap.put('Id5' , 5);

accMap.put('Id3' , 4);

accMap.put('Id4' , 3);

accMap.put('Id1' , 2);

accMap.put('Id2' , 1);

 

 

Any help will be appriciated.

 

Thanks

 

Bramha

Hi,

 

I could't manage to figure out how (if its possible) to translate the Standard Object / Standard field labels ( eg, Account objct / "Account name" field)?

I tried to use the Translation Workbench, but there I can only change the custom field labels.

Multiple users are getting an error message when trying to save an Opportunity. The message reads "The record you were editing was modified by XYZ user during your edit session". I'm familiar with this error and why it fires when two people are actively editing a record (Collision Detection), but the odd thing is that the other Users were NOT actively editing the same record at the same time. I'm assuming that something in the background is causing this error (Workflow, Process Builder, Flow, etc.), but does anyone know the best way to check this? Is there a way to determine if one of these elements threw the error? Or is there a way to see that user's log history for that time period?

User-added image
 
Hi,

Within a visual flow, I'm wondering if I can populate a collection variable using semi-colon separated values (;) in a single input text box. For the use case, I'd like to append an ad-hoc Taskray Checklist to a Taskray Task using only the flow interface, but as the items are ad-hoc, I can't use a template for it.

For example, if I input this in ONE long text field:
Apples;
Bananas;
Carrots;


Can I pass it into a collection variable using a loop so it is [Apples, Bananas, Carrots]?

I have simulated this by using LEFT({!Checklist}, FIND(";", {!Checklist}) - 1) to get the first row and adding it to the collection variable, trimming it from {!Checklist} and doing it again for the second row, etc. This creates the collection var as long as I stick to the number of assignments I've used.

But the problem is I can't figure out how to build it into a loop to handle variable number of items. Is there any way to do this using only flow tools?

Thanks in advance :)




 

I am creating a process to dynamically apply a new owner to a Lead (and change the value of a Field in Lead) after it's created on a Web-to-Lead page (it's being entered with me and it needs to apply it to someone else, based on a record value in a custom object).  

I was thinking that the most efficient way to do this would be to use a flow and then invoke the flow from the process, triggered on the creation of the Lead. 

However, I am not sure how to pass the value of the Lead itself to the flow as the process invokes it. How will my flow know which Lead it's working with? 

I've seen this question asked elsewhere without an answer. Is this even possible?

Hi,

I've tried hiding both objects from my user permissions and also making sure that both objects are not "pinned" in Salesforce classic. However, I'm unable to remove the Peoples and Articles objects from displaying in my smart search section from the Salesforce1 mobile navigation menu. I have created a custom user profile, which hides all the objects that I do not wish to display.

I was able to successfully hide all other standard objects in the smart search, but it seems that only these two are stubbon. 

Is there something else I can try to hide them?
Hi All,

I have a requirement to populate the active contact record id in Account object. For this, i have taken a contact lookup in account object. whenever user updates the active field, i have written a trigger to update the contact lookup field in account.

If any user deactivates the contact, then the contact lookup in account object should become empty. I am not able to fulfill this scenario.

Can any one please help me for this requirement.

Code:
 
trigger sample on contact(after insert,after update){
List<Account> accList = new List<Account>();
        List<Account> accUpdateContactPerson = new List<Account>();
        List<Id> contactIdList = new List<Id>();
        Map<Id,Id> ContactAccountIdMap = new Map<Id,Id>();
        accUpdateContactPerson.clear();
        for(Contact con:cont){
            
            if(con.Active__C == true){
                contactIdList.add(con.Id);
                ContactAccountIdMap.put(con.AccountId,con.Id);
            }
            
        }
        accList = [select Id,Contact__c from Account where Id IN: ContactAccountIdMap.keySet()];

            for(Account acc:accList){
                if(contactAccountIdMap.get(acc.Id)!=null){
                    acc.Contact__c = contactAccountIdMap.get(acc.Id);
                }
                else{
                    acc.Contact__c = null; 
                }
                accUpdateContactPerson.add(acc);
            }
            update accUpdateContactPerson;
}

 
Hi,

Below is my trigger, its not counting the closed  Activity.
Need your help.
 
trigger AccountCounttask on task (after insert, after delete) {

  Set <Id> AccountIDs = new Set <Id> ();
  
  if(Trigger.isInsert ){
      for(Task tsk1: Trigger.new){
          if(tsk1.WhatId <> NULL && tsk1.WhatId.getSobjectType() == Account.getSObjectType()){
              AccountIDs .add(tsk1.WhatId);
          }
      }
  }
  if(Trigger.isDelete ){
      for(Task tsk1: Trigger.old){
         if(tsk1.WhatId <> NULL && tsk1.WhatId.getSobjectType() == Account.getSObjectType()){
              AccountIDs .add(tsk1.WhatId);
          }
      }  
  }
  if(AccountIDs.size()>0)
      ActivityTriggerHandler.UpdateActivityAccount(AccountIDs);
  
  // Recompute the Activities for Account
}
 
@future
       
         public static void UpdateActivityAccount(set<Id> AccountIDs ){
            MAP <Id,integer> AccountCntMap = new MAP <Id, integer>(); 
            integer count;
             for(ID id1: AccountIDs ){
                AccountCntMap .put(id1, 0);  
             }
             for(Task tsk1: [select WhatId, Id from Task where WhatId IN :AccountIDs ]){
                 count = AccountCntMap .get(tsk1.WhatId) + 1;
                 AccountCntMap .put(tsk1.WhatId, count);
             }
             for(Event ev1: [select WhatId, Id from Event where WhatId IN :AccountIDs ]){
                 count = AccountCntMap .get(ev1.WhatId) + 1;
                 AccountCntMap .put(ev1.WhatId, count);
             }
             LIST <Account> AccUpd = new LIST <Account>();
             for(Account Acc1: [SELECT Id, Count_of_Activity__c FROM Account WHERE Id IN :AccountIDs ]){
                count = AccountCntMap .get(Acc1.Id);
                Acc1.Count_of_Activity__c = count;
                 AccUpd .add(Acc1);
             }
             Database.update(AccUpd );
         }

 

I am working on a flow that would create a Contact when a new User (UserType = Standard) is created.

I am getting the following error:
An error occurred at element Create_Contact (FlowRecordCreate).
INSERT --- INSERT FAILED --- ERRORS : (MIXED_DML_OPERATION) DML operation on setup object is not permitted after you have updated a non-setup object (or vice versa): Contact, original object: User, 


I have researched and found out that this is a common error when trying to perform DML operations on non-setup (Contact) and setup (User) objects. The solution for those who encountered this error from a Trigger is to split DML operations into future and non future context (perform DML on Non-Setup object type, then perform DML on Setup object type in @future methods). 

How can I apply this logic to a Flow used in a Process? Any ideas? Thanks in advance for help!

Hello
 
My email administrator currently has set up some forwarding rules on our Exchange to allow Salesforce emails to be sent and received however due to recent tigher security controls with external email we now need to be able to enable Salesforce to send all email through our Authenticated SMTP server. This will mean all emails will be authenticated and will pass all basic checks. It would also mean that we can remove all of the bypass rules that have been put in-place for incoming emails from Salesforce.
 
Recently we have had occurrences whereby all the forwarding rules we have set up is blocking mail through our mail gateway from Salesforce as we do not have send from source or not.
 
For the external rules sending all email through our Authenticated SMTP server might be a way we can bypass having to setup all this forwarding, either by Salesforce checking an internal account, or by allowing the forwarding via Mimecast.
 
Is Email Relay Activation the way forward?
 
Can anyone help?
 
Many thanks
 
Sonya
The challenge is:

You've been given a requirement to keep Contact addresses in sync with the Account they belong to. Use Process Builder to create a new process that updates all child Contact addresses when the address of the Account record is updated. This process:Can have any name.
Must be activated.
Must update Contact mailing address fields (Street, City, State, Post Code, Country) when the parent Account shipping address field values are updated.

I start with Accounts when records is created or edited.
Filter criteria where accounts shipping address (street, city, state, zip code) is changed (used "or" logic).

I am stuck on the next step "add action".  I started with action type "Update Records".
On objects, I can't seem to change Accounts to Contacts.  Why?
HI All,
i am attaching files to an email that I send out form Apex code. I was reading the documentation of email file size limits and came across very conflicting statements. In the help section it is clearly written

"The size limit for multiple files attached to the same email is 25 MB, with a maximum size of 5 MB per file."
(https://help.salesforce.com/apex/HTViewHelpDoc?id=collab_files_size_limits.htm)

But then I also find this in a couple of places

"The max email message size for a complete email message including attachments is 10MB"
(https://developer.salesforce.com/page/Force.com_Email_Services_Size_Limitations)

"Email Services: Maximum Size of Email Message (Body and Attachments):10MB"
"Email services reject email messages and notify the sender if the email (combined body text, body HTML, and attachments) exceeds approximately 10 MB (varies depending on language and character set)."
(https://www.salesforce.com/us/developer/docs/apexcode/Content/apex_gov_limits.htm)
(https://www.salesforce.com/us/developer/docs/apexcode/index_Left.htm#CSHID=apex_classes_email_inbound_what_is.htm|StartTopic=Content%2Fapex_classes_email_inbound_what_is.htm|SkinName=webhelp)

My question is quite simple ... What limit should I care about if I intend to send attachments through email directly from the controller?
We have got data coming into Salesforce via Bulk API . After the import it created hundreds of job and its very hard to go through all the Job Id and look at the records which didn't process correctly or Error.

Is it possible to Query this Bulk Data Load Job page or Bulk Load tables in Salesforce?

Can any body help me what are the differences between SOAP API and REST API..?

Hi,

 

I am trying to build a custom page, that display "Bulk API Jobs" in a data grid. I am using the following statement :

 

List<AsyncApexJob> jobs = [SELECT Id FROM AsyncApexJob];

 but it does not return anything. And when i go the page "https://xxxx.salesforce.com/750?setupid=AsyncApiJobStatus" i see my job in status "Open". 

Is it possible to do this kind of query on Bulk Jobs ? If not, is there a way to embeded the "Bulk Jobs List" inside a custom apex page ?

 

Xavier

  • June 24, 2013
  • Like
  • 1

Hi i am new to VWF.

 

How can we display picklist values on screen input fields using dropdown list. I don't want to add them in flow instead i want to retrieve and display from object directly?

 

for ex:

 

i have 2 fields Account Name and Account Type.

 

when user reach this screen he should enter name and select a picklist value from type. and these values should come automatically from Standard Account Type.

 

Please help me.

Thanks in advance.

Can someone help me understand how to access a picklist values from a picklist on a custom object in the cloud flow designer? It looks like I have recreate the picklist choices as Choices in flow, which I do not want to do from an on going management perspecitve. When I try Dynamic Choices it brings back record values and not just the picklist options. Thanks!

Hi ,

I have badly stuck with the problem , I am getting User Image Url "https://c.cs12.content.force.com/profilephoto/005/T" but if image in not added to User Image a blank photo show but if I added photo the User Image and rendering the VF page on force.com site , The Image not showing its showing just like a burst images !

Hi,

I wanted to connect Dropbox REST API through Apex class.I was finding difficulty to access oAuth access token.

Kindly let me know the process.

 

Thanks.

Hi,

 

I would like to know if we can sort a Map by Value. I have a Map like below.

 

Map<Id, Integer> accMap = new Map<Id, Integer>();

 

e.g I have values in the Map like below

 

accMap.put('Id1' , 2);

accMap.put('Id2' , 1);

accMap.put('Id3' , 4);

accMap.put('Id4' , 3);

accMap.put('Id5' , 5);

 

Now i want the Map to be sorted by the Integer value and my output should be like below

 

accMap.put('Id5' , 5);

accMap.put('Id3' , 4);

accMap.put('Id4' , 3);

accMap.put('Id1' , 2);

accMap.put('Id2' , 1);

 

 

Any help will be appriciated.

 

Thanks

 

Bramha

Hi All,

 

I have a custom object, I need to make the record as read only based on the value of a particular custom picklist field..for a particular profile...

 

For Ex:

 

I have an Object says: Custom_Object__c

Custom Field is: Picklist__c

 

as i save the record with the Picklist__c='Changed' for a particular profile.. my complete record should become read only.. is that can be achieved...?

 

Thanks

Is there anyway to tell which Custom Reports are dependant on each Custom Report Type?
 
I need to delete some of our redundant report types, but need to be sure I'm not deleting any active reports in the process.
 
Thanks
  • November 24, 2008
  • Like
  • 1