• Karthik TathiReddy
  • NEWBIE
  • 5 Points
  • Member since 2012

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 20
    Questions
  • 18
    Replies
Hi All,

I have installed Gantt Chart application from AppExchange but when I am trying to access getting the issue like  "[Invalid key value "[object Object]" in [object:vm undefined (44)]. Key must be a string or number.]"
Please suggest or help to me to overcome this issue.

Regards,
Aparna
Trailhead Module 3:  Create a formula field that determines the number of days between today and the last activity date for a case's account.
Your support team has asked for improved visibility on account activity level at the time they’re helping with customer issues. Specifically, when they’re looking at a case, they’d like to see an at-a-glance view of the number of days since the case’s related account was last active. Create the formula using these requirements.The formula should be on the Case object.
The formula should be of return type Number.
The formula should be named 'Days Since Last Update' and have a resulting API Name of 'Days_Since_Last_Update__c'.
The formula should return the number of days between the account’s Last Activity Date and today.

I created the following:

I created a new custom formula field with return type number and called Days Since Last Update.
I created this formula: Account.LastActivityDate - TODAY()

I get this error message:

Challenge not yet complete... here's what's wrong: 
The 'Days_Since_Last_Update__c' formula field did not return the correct number of days between an Account’s Last Activity Date and today

Can you please assist what I did wrong?  I'm not sure if my formula is even correct with the challenge.  Please help!

Thank you.

Please help me. Becuase im very new to sales force. how i can solve this problem

global with sharing class SaveExpenditureWebService {

webservice static Expenditure__c createExpenditure(Decimal amount,String expName, String paidByName )
{

Expenditure__c c = new Expenditure__c();
Person__c p = [Select p.Name From Person__c p Where Name = :paidByName limit 1];
c.Amount__c = amount;
c.Name__c = expName;
c.Exp_Date__c = Date.today();
c.Paid_By__c = p.Id;
insert c;
return c;
}

}

Hi,

I am using a check box and passing many param id's for the check box to the controller which is assigned to the multiple values corresponding to the different params. While I am using the assigned values in different methods in the controller, I am getting null values in the debug logs/ console.

 

Could any one help with your ideas how do I use them in different methods through out the controller....

<apex:outputPanel id="repeatList">
           <apex:repeat var="vw" value="{!VenuesWrapper}">
	<!-- Accordion Start -->			
	 <div class="accorden_bdr">
                    <h3 class="ui-accordion-header ui-helper-reset ui-state-default ui-corner-all ui-accordion-icons" role="tab" id="ui-accordion-2-header-3" aria-controls="ui-accordion-2-panel-3" aria-selected="false" tabindex="-1">{!vw.venue.MD_Locations_Serviced__r.name}<apex:outputPanel id="recomendationcreatedStatus" rendered="{!IF(vw.isRequestSent,'true','false')}">
                            <div class="refferal_color bold tab_pad">Referral Sent</div></apex:outputPanel> </h3>
                    <div class="ui-accordion-content ui-helper-reset ui-widget-content ui-corner-bottom" id="ui-accordion-2-panel-3" aria-labelledby="ui-accordion-2-header-3" role="tabpanel" aria-expanded="false" aria-hidden="true" style="display: none;">
                        <div class="refer_divm">
                            <div class="refer_couple" style="color: #d7666a;">Check "Refer to Couple" to send this pricing information with this Venue.>></div>

			 <div class="refer_chkbox">

			<!-- Outputpanel start for checkbox region -->                           
                                 <apex:outputPanel id="recomendationNotcreated" rendered="{!IF(AND(vw.venue.Recommendations__r !=null && vw.venue.Recommendations__r.size==0), 'true', 'false')}">
            					   <apex:form id="ReferToCouple">   
                                    <apex:outputLabel value="REFER TO COUPLE" for="referLabel"/>
                                     <apex:inputCheckbox value="{!vw.isReferCoupleRefered}" id="referLabel" styleClass="referLabel">
                                        <apex:actionSupport event="onclick" action="{!createRecomendation}" rerender="headerComponent,repeatList,recomendationcreated" status="loading">
                                          <apex:param name="vid" value="{!Venue_DB__c.id}" assignTo="{!venueRefId}"/>
                                          <apex:param name="venueRefd" value="{!vw.venue.id}" assignTo="{!venuePricingInfoRefId}"/>
                                          <apex:param name="locservice" id="locservice" value="{!vw.venue.MD_Locations_Serviced__c}" assignTo="{!locationServicedRefId}"/>
                                        </apex:actionSupport>
                                        <apex:actionStatus id="loading">
                                          <apex:facet name="start">
                                            <div class="loading lext"></div>
                                              <div class="innerBlock">
                                                <img class="waitingImage" src="/img/loading.gif" title="Please Wait..." />
                                              </div>
                                          </apex:facet>
                                        </apex:actionStatus>
                                     </apex:inputCheckbox>
                                  </apex:form>
                                </apex:outputPanel>
			<!-- Outputpanel end for checkbox region -->                           

                        <!-- Outputpanel start for Remove link region -->
                                 <apex:outputPanel id="recomendationcreated" rendered="{!IF(AND(vw.venue.Recommendations__r !=null && vw.venue.Recommendations__r.size!=0), 'true', 'false')}">
                                  <apex:form id="RemoveToCouple"> 
                                    <!--  Testing -->
                                    <!-- {!vw.venue.id} -->
                                    <!--  Testing -->
                                        <apex:commandLink styleClass="clearRefer Remove" value="Remove" action="{!deleteRecomendation}" rerender="headerComponent,repeatList" status="loadingStatus">
                                         <apex:param name="dvid" value="{!vw.venue.id}" assignTo="{!venueRefId}"/>
                                        </apex:commandLink>
                                        <apex:actionStatus id="loadingStatus" startText=" (loading...)" stopText="">
                                          <apex:facet name="start">
                                            <div class="loading lext"></div>
                                            <div class="innerBlock">
                                              <img class="waitingImage" src="/img/loading.gif" title="Please Wait..." />
                                            </div>
                                          </apex:facet>
                                        </apex:actionStatus>
                                  </apex:form>
                                </apex:outputPanel>
                        <!-- Outputpanel end for Remove link region -->

                            </div>
                          </div>
                        <div style="width:100%; float:left;">
         
                                  <div class="bold ceremony_start" style="margin-top: 13px;">Ceremony Starting Price Includes</div>
                                    <div class="number_div"><apex:outputPanel id="cerPriceIncludes" rendered="{!IF(vw.venue.Ceremony_Starting_Price_Includes__c==null || vw.venue.Ceremony_Starting_Price_Includes__c=='', true,false)}">n/a</apex:outputPanel><apex:outputField value="{!vw.venue.Ceremony_Starting_Price_Includes__c}"/></div>

                               <div class="bold" style="color:#50332A; width: 47%; float: left !important;">Price Description</div><br/>
                                <apex:outputPanel id="priceDescp" rendered="{!IF(vw.venue.Price_Description__c==null || vw.venue.Price_Description__c=='', true,false)}">n/a</apex:outputPanel><apex:outputField value="{!vw.venue.Price_Description__c}" />
                                 
                        </div>

                                <div class="padtop_mini bold" style="color:#50332A; padding-top: 10px;width: 100%;float: left;">Packages</div>
                  <table>
                  <tr>
                  <td><b><apex:outputPanel id="packOffered" rendered="{!IF(vw.venue.Packages_Offered__c==null || vw.venue.Packages_Offered__c=='', true,false)}">n/a</apex:outputPanel><apex:outputField value="{!vw.venue.Packages_Offered__c}" /></b></td>
                  <td>Packages Offered?</td>
                  </tr>
                  </table>
                    </div>
                   </div>

		<!-- Accordion End -->
           </apex:repeat>          </apex:outputPanel>

 

I have a check box written using stylesheets for displaying as accordions in a apex:repeat method. This would generate multiple accordions and the same checkbox for every accordion. The VF code is shown above...

 

I need to render the remove link section when I click on checkbox and need to render the checkbox region when clicked on remove link. The functionlity is working if I refresh the page when I Perform actions on the two regions.

I need to work the functionality when i click on the checkbox and remove link without manually refreshing the page.

Any ideas please post your comments....

 

HI,

I wrote onclick function for a span tag as below

<div class="property_in"><img src="'+hurl+'" width="210" height="138" /><div class="property_title">'+val1+'<br /><span class="property_remove"><p onclick="remove(\''+ivid+'\');" style="cursor: pointer;">Remove</p></span></div></div>

 

Onclick the image should remove from the page. But the above one is not working for Chrome and IE browsers. Please give some idea how to work this on chrome and IE as well...

Hi, I am not able to login to force.com com ide for my Sandbox org. I am able to login into my sandbox through browser with same credentials. Tried to login by resetting my security token also. But still couldnt get it.

 

The error getting shown is,

 

Unable to connect to hostname 'test.salesforce.com'

Inavlid username, password, security token; or user locked out.

Please verify and/or change your credentials.

Hi,

What is the https://c.cs14.visual.force.com represents for my salesforce organisation. What is its environment. Any why the domain url is changing to https://c.cs14.visual.force.com when I open any visualforce page.

Please let me know why is this changing and what exactly it denotes?

 

 

Thanks

 

 

-Shiva

Hi,

I created a visualforce standardcontroller page with extension controller.

Here I used Opportunity as the parent object and another custom object as child to the opportunity.

In the custom object I have a look up field. Whiile give the field values of custom object in visualforce page and saving it, It is not saving the value of lookup field.

The sample code in visualforce page is shown below.

Page:

<apex:inputField value="{!Opportunity.ChildObject__r.name}">

<apex:inputField value="{!Opportunity.ChildObject__r.email__c}">

<apex:inputField value="{!Opportunity.ChildObject__r.Contact__c}">(this is the lookup field)

<apex:commandButton value="Save" action="{!Save}">

Here after clicking the save button the contact lookup field is not saving...

Can you reply me how to get save the lookup field.

**************Controller*************
public with sharing class ProgramController {

     public Program__c Program;

     public List<Wrapper> wraplist{get;set;}
 
     public ProgramController(ApexPages.StandardController controller) {

       program = (Program__c) Controller.getRecord();
 
       wraplist = new List<Wrapper>();
        
       Set<string> titlestr = new set<string>();
    
       List<Title__c> PTLst = [SELECT id, name, Program__c FROM Title__c  where Program__c = :program.id];

       for(Title__c r : PTLst){

          titlestr.add(r.name);

         }

       List<Title__c>  t = [SELECT id,name,Program__c FROM Title__c  where Name not in :titlestr limit 20];

    // List<title__c> t = [SELECT id,name,Program__c FROM Title__c LIMIT 20];

      for(title__c t1 : t){

         wraplist.add( new wrapper(t1));

         }
 
       }

public class Wrapper{
    
    public Boolean Selected{get;set;}
    
    public title__c title{get;set;}
    
    public wrapper(Title__c ti){
    
       title = ti;
    
      }
   }

   public PageReference addTitle(){

      List<Title__c> newTitle = new List<Title__c>();
    
        for(Wrapper wrap :WrapList){
    
           if(Wrap.Selected == true){
    
             title__c newtitle1 = new title__c(Name = wrap.title.name, program__c=program.id);
    
             newTitle.add(newTitle1);
    
           upsert newtitle1;
    
           }
    
         }

      PageReference programPage = new ApexPages.StandardController(program).view();
    
      programPage.setRedirect(true);
    
      return programPage;

    }

}



******************VF Page*******************

<apex:page StandardController="Program__c" extensions="ProgramController">
<apex:form >
  <apex:pageBlock >
  <apex:pageBlockButtons >
  <apex:commandButton action="{!addTitle}" value="Add Title"/>
  </apex:pageBlockButtons>
  <apex:pageBlockSection >
  <apex:pageBlockTable value="{!WrapList}" var="w">
  <apex:column headerValue="Action">
  <apex:inputCheckbox value="{!w.Selected}"/>
  </apex:column>
  <apex:column value="{!w.title.name}"/>
  </apex:pageBlockTable>
  </apex:pageBlockSection>
  </apex:pageBlock>
  </apex:form>
</apex:page>

 The above visualforce page I created a button and assigned the VFpage to the buttonURL to the parent object Program__c. Title__c is the title object. The above code results in adding the selected records to the related list of a program__c record. In this process what ever the records I added from the Title object the same records creating again in the title object which resulting to duplicate records. Please help me out regarding this.