• RonakPatel.ce
  • NEWBIE
  • 75 Points
  • Member since 2012

  • Chatter
    Feed
  • 3
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 4
    Questions
  • 31
    Replies

Hi,

I am a new person for this platform, plese explain me

 

1. How to create session in apex ?

2. How to store values in session ?

3.How to retrive values from session ?

 

Thanks

Im creating trigger , inside this i want to add condition if i am manipulating record is from apex data load or from user interface. how can i  achieved this without creating field that will act as a flag that will set to true if coming from data load. thanks

Hi,

 

is the order of values I pass to a multi select picklist of importance? For example, there is a multi select picklist field whose values are defined in the order of "A;B;C;D" in SFDC Setup. If I want to update that field via web service API do I have to pass the values in the defined order or can I pass it like "B;C;A"?

 

Thanks in advance,

René

  • February 08, 2012
  • Like
  • 0

Hi,

 

Can anybody tell me that

How many trigger we can make on one object ? 

Hi,

 

I have used the SOQL OFFSET clause in one Query my Developer Account but it will give error 

 "SOQL OFFSET clause is not supported in this organization"

 

I want to know more about it ...

 

Anybody knows..?


Hi,

 

i  have to remove '(' and ')' Character from the String
for that i used  string.replaceall('(','');

but i got error Regex invalid :Unclosed Group near index 1(^

 

Can anybody tell me how to solve this problem?

or Any other way to remove ( and ) from the string..

hi,

 

i import data though csv file but when data is more than 1000 then it gives me Error

 

 

System.LimitException: Regex too complicated

 

Can anybody give me Explanation ?

hi everyone

 

i have one trigger senario like:

 

trigger FFTrigger on FF__c (after insert,after update,before delete) {

//ff object
   if(ff != null && Trigger.isDelete)
        {
        
         System.debug('TriggerDelete=:'+ff.Id);
         WebServiceRequestBuilder.HttpResult(ff.Opportunity__c,ff.Id,'delete'); 

        }

        
    }

 

i just want to know that in trigger .isdelete i want ot send the id of that record in webrequest as mention above. so i want to confrim that is i gt id in this case .if not what can be proper way to handle this.

 

 

please help me

 

thanks
  

I have a wrapper class with a getter/setter string, a selectOptions list, and a method to be executed after the getter string is populated. I can't get the string setter to work with a selectList when I have a list of the wrapper.  If I use a single wrapper element the code works fine. I have tried using a PARAM statement without success. I would appreciate any assistance.  Thank you.

 

 

public with sharing class tClass
{
List <wClass> wClassList {get;set;}
wClass testWClass {get;set;}
string leftSelected {get;set;}

 public tClass() { testWClass = new wClass(new Account(name="Test Account 0')); wClassList = new List<wClass>(); wClassList.add(new Account(name='Test Account 1)); wClassList.add(new Account(name='Test Account 2')); } public class wClass { public Account a {get;set;} public string leftSelected {get;set;} public list<selectOption> leftSelectOptionList {get;set;} public wClass(Account a){this.a = a; ….code to build leftSelectOptionList} public pageReference selectClick(){String s = leftSelected; LEFTSELECTED IS SET TO NULL WHEN I CHECK WITH DEBUG STATEMENTS WHEN THERE ARE A LIST OF WRAPPER ELEMENTS} } } VF Page <apex:repeat value="{!wClassList}" var="PCOI"> <apex:selectList styleClass="inputText" value="{!PCOI.leftSelected}" size="3"> <apex:actionSupport event="onclick" action="{!PCOI.selectClick}" reRender="Form"> <!-- <apex:param assignTo="{!PCOI.leftSelected}" value="{!leftSelected}" name="left"/> --> </apex:actionSupport> <apex:selectOptions value="{!PCOI.leftSelectOptionList}"/> </apex:selectList> <apex:repeat >

VF PAGE WORKS FINE IF I REMOVE THE REPEAT AND USE testWClass.

 

 

  • April 27, 2012
  • Like
  • 0

Hi,

 

    I have a very strange problem ..I have a button on my Page when i click on that button it is not calling the method ,after that when i click on it again then its calling the method ...............

 

 

Can anyone suggest me what is the actual problem.Please help.....

 

 

 

 

 

Thanks in advanced.

  • April 24, 2012
  • Like
  • 0

Hi,

 

How can i have coverage on get methods in a controller?

 

	public List<SelectOption> Listtype
	{
		get
		{
			List<SelectOption> Val = new List<SelectOption>();
                        Val.add(new SelectOption('First', 'One'));
                        Val.add(new SelectOption('second', 'two'));
                        Val.add(new SelectOption('Third', 'three'));
                        return Val;
			
			}
}

 Any pointers

Hi,

 

I have a input textbox and a command button in a page. When the user enters some text and clicks on the button i am invoking a method in Apex class.

 

The same functionality should be performed even when the user enters some text and clicks enter key.

 

I think this can be achieved using accessKey property of commandButton. I tried but it didn't worked.

 

Can someone please help me on this.

Is there a way to read in a static file into a unit test?  

 

I am trying to unit test a large data set coming back in a JSON format from our webservice call and would like to load a sample text file for my unit tests.

 

The overall objective of the unit tests it to test the governor limits on batch inserting a large number of leads.

 

Hi ,

 

I am following the the code below for google map rendition in VF page in Account page layout yet it is coming blank. Please help

 

 

http://salesforce.phollaio.com/2010/03/18/inline_google_maps_using_visualforce/

 

Regards

 

Prazon

  • February 29, 2012
  • Like
  • 0

This is trigger:

 

trigger placement_enddate on AVTRRT__Placement__c (before insert) {

for(AVTRRT__Placement__c plc:trigger.new)
 {
AVTRRT__Job_Applicant__c japp=[select AVTRRT__Job__r.AVTRRT__Estimated_Close_Date__c from AVTRRT__Job_Applicant__c where id=:plc.AVTRRT__Job_Applicant__c ];
plc.AVTRRT__End_Date__c =japp.AVTRRT__Job__r.AVTRRT__Estimated_Close_Date__c;

}
}

 

 

Here Is the Testcase below:

 

@isTest
private class placement_enddate_TC
{

static testMethod void myUnitTest()
{

Profile p = [select id from profile where name='Standard User'];

User u = new User(alias = 'standt', email='standarduser@testorg.com',

emailencodingkey='UTF-8', lastname='Testing', languagelocalekey='en_US',

localesidkey='en_US', profileid = p.Id,

timezonesidkey='America/Los_Angeles', username='standarduser@testorg.com');


account acct=new account();
acct.Name='Test account';
insert acct;

 

AVTRRT__Job__c jb=new AVTRRT__Job__c();
jb.AVTRRT__Job_Title__c='Test Functional';

jb.AVTRRT__Start_Date__c=date.ValueOf('2012-03-16');
insert jb;    // Showing error here while running the testcase!!!

 

contact ct=new contact();
ct.RecordType.id = '012D0000000hW06';
ct.LastName='test candidate';
insert ct;


AVTRRT__Job_Applicant__c ja=new AVTRRT__Job_Applicant__c();
ja.AVTRRT__Job__c=jb.id;
ja.AVTRRT__Contact_Candidate__c=ct.id;
insert ja;

AVTRRT__Placement__c a=new AVTRRT__Placement__c();
a.AVTRRT__Start_Date__c=date.ValueOf('2012-03-16');
insert a;
}}

 

Method NameTotal Time (ms)MessageStack Trace

placement_enddate_TC.myUnitTest234.0System.DmlException: Insert failed. First exception on row 0; first error: CANNOT_INSERT_UPDATE_ACTIVATE_ENTITY, AVTRRT.Trigger_Job: execution of BeforeInsert caused by: System.NullPointerException: Attempt to de-reference a null object (AVTRRT): []Class.placement_enddate_TC.myUnitTest: line 28, column 1
  • February 24, 2012
  • Like
  • 0

Hi,

I am a new person for this platform, plese explain me

 

1. How to create session in apex ?

2. How to store values in session ?

3.How to retrive values from session ?

 

Thanks

Hey all,

 

I'm trying to download the Force IDE as a stand alone application, the Windows 64bit version (from http://wiki.developerforce.com/page/Force.com_IDE_Installation).   I have tried about 10 times total now and tried to my desktop as well as my laptop and get the same issue on both. The download just randomly stops and I get the error:

 

"Windows cannot open the folder.

 

The compressed(zipped) folder

c:\blah\blah\blah\blah\force.com-ide-installer-win64.zip is invalid"

 

I think the furthest it has gotten is 8%.  Anyone know what the problem is and how I can get the IDE downloaded?  Also, I do have the Java JRE installed.  Thanks in advance

Hi All

 

I am trying to access a single aggregate result as in the follows (this is not meant to be  a group of results!)

 

decimal totaldebitorder = [select sum(amount__c) tot from Debit_Order_Transaction__c where Credit_agreement_No__c=:ca.id ].tot;

 

I am getting Invalid field tot for SObject AggregateResult error.

 

Please help?

 

thanks in advance

Ross

 

  • February 23, 2012
  • Like
  • 0

Im creating trigger , inside this i want to add condition if i am manipulating record is from apex data load or from user interface. how can i  achieved this without creating field that will act as a flag that will set to true if coming from data load. thanks

I have a trigger that creates a lead record from a custom object record that meets the criteria.  The trigger works fine if I insert the custom object record via the standard user interface.  If I try to insert the record via a VF page, the trigger fails with an Invalid Parameter error.  

 

When I look at the debug logs, it's capturing the information on the vf page, but when it inserts, it's failing. I can't tell if it's failing on insert of the custom object record or the   

 

If I turn the trigger off, I can insert the custom object record via the VF page, if I turn it back on, it fails.  

 

I'm completely confused by this.  Any ideas?  I went through all of through all of the fields to be sure they matched in type and size because I couldn't think of anything I could troubleshoot?  

 

 

SFclouds is glad to announce great suppoert through Skyvva for SAP Integration with Salesforce.com
Please get in touch for any assistance at hina.gupta@sfclouds.com( skpe id hina.sfclouds)

Hi,

 

I am having decimal number like this : 4.77080

 

but i want only 77 after decimal point notation.

 

How can i achieve this?

 

Any kind of help will be greatly appriciated.

 

Thanks in advance..

 

Vishal.