• SnehalC
  • NEWBIE
  • 40 Points
  • Member since 2013

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 9
    Questions
  • 5
    Replies
Hi,

I need to hide/show fields based on picklist. I have used actionsupport for this. when picklist value is 'urgent'; i need to show two fields (one is picklist and one is long text area). When picklist value is 'Non-Urgent'; I need to hide these two fields. My code is like below:

<apex:outputPanel id="UrgentFields" rendered="{!NOT(ISNULL(Vendor_Mgmnt__c.name))}">  
                 <apex:pageblocksection title="Urgency" showheader="true" columns="1">
                 <apex:pageBlockSectionItem >
                        <apex:outputLabel value="{!$ObjectType.Vendor_Mgmnt__c.fields.Urgency__c.label}" for="Urgency"/>
                        <apex:actionRegion immediate="true">                  
                            <apex:inputfield id="Urgency"  value="{!Vendor_Mgmnt__c.Urgency__c}" required="true">
                            <apex:actionSupport event="onchange" rerender="UrgentFields"/>
                            </apex:inputfield>
                        </apex:actionRegion>
                    </apex:pageBlockSectionItem>
      
                   <apex:pageBlockSectionItem rendered="{!Vendor_Mgmnt__c.Urgency__c=='Urgent'}" >
                        <apex:outputLabel value="{!$ObjectType.Vendor_Mgmnt__c.fields.Impact__c.label}" for="Impact"/>
                        <apex:inputfield id="Impact" value="{!Vendor_Mgmnt__c.Impact__c}"  required="true"/>
                   </apex:pageBlockSectionItem>
                   <apex:pageBlockSectionItem rendered="{!Vendor_Mgmnt__c.Urgency__c=='Urgent'}" >
                        <apex:outputLabel value="{!$ObjectType.Vendor_Mgmnt__c.fields.Reason__c.label}" for="Reason"/>
                        <apex:inputfield id="Reason" value="{!Vendor_Mgmnt__c.Reason__c}" style="width:550px" required="true"/>            
                   </apex:pageBlockSectionItem>             
                 </apex:pageblocksection>
            </apex:outputPanel>

The rendering of the fields is working exactly as expected. But the problem is rendering is slow. So what happens is when user selects picklist value as 'Non-Urgent' and quickly hits on save button then 'Mandatory field' validation error appears for the 'Impact' and 'Reason' fields because they are mandatory fields. Actually, these fields should have been hidden. So, I think validation happens before my ajax request complets. Any idea how can I solve this?
Hi,

I have a custom status picklist field, the value of which changes at every approval step. This is achived through field update for all the 5 approval steps. I have one more picklist field for which I want it's value to be changed automatically whenever status field value changes. I am thinking of workflow rules but I will have to create so many (at least 7). Is there any better solution? or workflow rule is best option?
Hi,

I have standard approval process with 5 approval steps. I want to set up an approver in 4th step which should be manager of a approver from 1st step. How should I achieve this? I dont have this user present in current record but I have approver user from 1st step in a lookup field. I am thinking of creating a field (hidden) which will be filled automatically from apex controller using user.manager where user is approver from 1st step. Then I can use this field in approval step. Is my approach correct? If yes, will every record creator have access to user.manager so that the field will be properly filled. Thanks!
Hi,

I want to collect all the values for a particular field from a multiple lookup records and add it to a field in parent record. Individual values should be comma separated. How should I acieve this through trigger? Thanks in advance!
Hi,

I have two objects A & B. I have 4 lookup fields on object A with object B. When I select lookup field value in first field; I want all the other 3 lookup fields to be autopopulated. (All the three are user fields on object B which are looked up in object A). How to accomplish this? Thanks in advance!
I want to populate some lookup fields based on selection of value in other lookup fields...
I tried to autopopulate lookup field (some person name) based on some other lookup field... this is the formula... Apps__r.Business_person__c
But in the detail page it displays values like: ythhWFv12GD... why so? It should display person name..
Hi,

I am in the process of creating document/template which can be referred by technical reviewer in our Force.com development project. Can you please help me on this on what are the things I should include in the template, what can be the checklist before providing technical review approval etc. I am looking for things like what should be checked for testing impact of the code, security review of the code, standards and guidelines followed, design review etc.
Thank you!
Hi,

I am about to implement SVN for my SFDC instance. I have created a 'trunk' folder in SVN repo where I have metadata from production. I have created a 'branches' folder under which I have 'CSNProject' folder. I have asked all the developers who are working on this 'CSNproject ' to checkout this from svn repo and create a project for themselves on their individual eclipse instance.
My question is: All the developers will be working from their individual dev editions and when they create project in eclipse, how will they give force.com nature to their project? I know that they can goive their own dev edition credential and do save to server. But the problem is their dev edition will not have all the metadata from production org. And I do not want to deploy this metadata from prod to their individual dev edition usinf ant or any other tool because of company policy etc. Also, they don't want all the metadata but just few apex classes and objects. In that case how they will checkout only the things needed from SVN and use their own dev edition. Step-by-step illustration would be great. I am going to use Jenkins to pull changes from svn repo to production/test sandbox later. Thank you!
Can you please explain a team development scenario if everyone is using single developer sandbox for the development and not individual dev orgs. I mean this is what is practical where we have support team supporting a particular force.com app and each developer is assigned to a bug/fix or more than one developer is assigned to particular bug. In that case how source control (my case is SVN) works.
Will this work practically? What do you recommend?
Hi,

I have standard approval process with 5 approval steps. I want to set up an approver in 4th step which should be manager of a approver from 1st step. How should I achieve this? I dont have this user present in current record but I have approver user from 1st step in a lookup field. I am thinking of creating a field (hidden) which will be filled automatically from apex controller using user.manager where user is approver from 1st step. Then I can use this field in approval step. Is my approach correct? If yes, will every record creator have access to user.manager so that the field will be properly filled. Thanks!
Hi,

I want to collect all the values for a particular field from a multiple lookup records and add it to a field in parent record. Individual values should be comma separated. How should I acieve this through trigger? Thanks in advance!
Hi,

I have two objects A & B. I have 4 lookup fields on object A with object B. When I select lookup field value in first field; I want all the other 3 lookup fields to be autopopulated. (All the three are user fields on object B which are looked up in object A). How to accomplish this? Thanks in advance!
I want to populate some lookup fields based on selection of value in other lookup fields...
I tried to autopopulate lookup field (some person name) based on some other lookup field... this is the formula... Apps__r.Business_person__c
But in the detail page it displays values like: ythhWFv12GD... why so? It should display person name..

Hi there,

 

In my custom object, I'm trying to auto-populate a Contact Email field based on the Contact selected in a loopkup field on the same page.

 

Can anyone please provide an example of how this is accomplished?

 

 

Thanks so much!