A proprietary Java-like programming language for the Force.com Platform.

learn more… | top users | synonyms (1)

1
vote
0answers
14 views

Code Coverage in one big class vs multiple smaller classes

I'm having a very odd issue pop up wherein if I put all 75 of my account testMethods in one class, I get less than stellar coverage (maybe 70%) but if I split those testMethods up into 8-10 smaller ...
0
votes
2answers
6 views

Error: Compile Error: Method does not exist or incorrect signature when attempting to use a method from a class?

I'm attempting to build my first test, which is for a trigger I am trying to push to production and running into a large number of issues. The first an foremost being that the trigger at the beginning ...
4
votes
3answers
15 views

Why does the value of Static variables in batch context reset for each transaction

As part of the batch context, the static variables get reset at each transaction irrespective of Stateful/Stateless. class batch_test implements database.batchable, database.stateful () { static ...
1
vote
0answers
13 views

Test Method for callout in Future method

I have a trigger on Account. On Account insert, I am sending a callout through future method. I am trying to write a test class for this but I am getting either of these two errors - 1) You have ...
1
vote
1answer
7 views

Unable to make web callout even after Database.rollback

Savepoint sp = Database.setSavepoint(); insert new Campaign(Name='test'); Database.rollback(sp); HttpRequest req = new HttpRequest(); req.setEndpoint('http://google.com'); req.setMethod('GET'); Http ...
0
votes
1answer
13 views

Rating content from apex/visualforce [on hold]

How would I go about rating (thumbs up/thumbs down) a content item (Library) from a Visualforce page?
0
votes
0answers
29 views

Need help creating trigger for junction object

I am helping a local non-profit and created a SalesForce system for them. The organization does training and need to be able to generate rosters from Contacts. I added two custom fields to the ...
1
vote
2answers
23 views

How to synchronize asynchronous Apex

There are different ways to offload long-running processes to asynchronous apex: we got future calls, scheduled Apex, batch Apex and, more recently, Queueable Apex. They are all good to launch "fire ...
3
votes
1answer
26 views

Developing a Realtime Integration pipeline between Salesforce to Salesforce

I plan to develop an integration pipeline between two salesforce dev orgs for the following use case. Use Case : Send a custom object record (having two string fields only) from Salesforce ...
0
votes
1answer
28 views

Visualforce Error System.ListException: List index out of bounds: 0

Can any one help me out with this Error ??I have records created in the object.Any help is much appreciated Visualforce Error System.ListException: List index out of bounds: 0 ...
4
votes
1answer
58 views

Is it possible to copy the Contact ->'Login in to Portal as User' functionality on a Visualforce custom button?

On the Contact detail page there is a Manage External User -> Login As Portal User button when the Customer Portal is enabled. Is it possible to replicate that link's functionality on a custom button ...
2
votes
1answer
36 views

How to show the None Value in the multiselect component

I have used the below component and I would like to show the "--None--". if the left side and right getting the no values. as a standard picklist feature. Reference: How do I build a multi-select ...
0
votes
1answer
13 views

The PDF rendering is run first before data update

Not sure is the title is correct or not but this is my scenario.I have one controller to send email with pdf attachment to the user.Before it render the pdf file, it will update the user input first. ...
0
votes
1answer
13 views

Add an String value to a Integer SelectOption list - convert String to Integer

I got the following list of integer SelectOptions, and I want to add a String value to the SelectOption list. How can I convert String to Integer to add the String value? 'recordLimit' is an integer ...
1
vote
1answer
83 views

Email Services : Short Email Alias

I have created a custom email service class for creating custom object records from email requests. The salesforce generated email address (shown below) a) Is quite long..like 100 chrs ...
0
votes
0answers
28 views

Visual force Error-System.TypeException: Invalid decimal

i have written code in apex while saving the Geo location in my detail page. While doing this an error is coming on this particular line.It throw an error on my particular this code ...
-1
votes
2answers
28 views

Can Salesforce help if you're a ISO 9001 cetrified company?

we're a ISO 9001:2008 certified company (50+ SF-users), and I was wondering if there were ideas / apps who could help to do are 'registering' our complaints from customers, and automatically have the ...
0
votes
0answers
10 views

How to set the bar-series(VF Page) start value.?

I want to start the initial value/range from 0.Right its automatic depending on the value.Is it possible to always start from 0.??? Right now its starting from 400..This is VF page... Please help
0
votes
0answers
19 views

How to show past ,present and future years data in a visual force page in PDF Format [duplicate]

Can any one help me out .How to show past ,present and future years data in visual force page pdf format .Based on the query i get the data retrived for the current year (2014 )and When i add the ...
3
votes
2answers
55 views

Null pointer exception while handling DMLException

I have a batch job that tries to handle any DML exceptions and write them to a separate Custom object called Feed_Log__c. I have sometimes getting a Null pointer exception after trying to handle a ...
1
vote
1answer
43 views

Using apex value retrived from Visualforce page in SOQL Query

Please help me figure out a way on how to solve this. The below query gives me error : Error: Compile Error: Didn't understand relationship 'contactData' in field path. If you are attempting to ...
1
vote
2answers
38 views

Creating custom object for class roster that would pull a list from contacts

I am helping a local non-profit organization that does leadership training. They need to create a roster that will pull a list of contacts for the roster, and also store few topics that they worked ...
3
votes
1answer
29 views

Calculating date/time x working hours from now

I need to trigger an email notification 9 working hours after a particular field is changed in Salesforce. So if the field is changed on a Friday at 4pm, I need to calculate now() + 7 hours + an extra ...
2
votes
1answer
31 views

How to access force.com Rest Api from Site.com? [duplicate]

I need to call an authenticated Apex Rest API from Site.com page. The way I am trying is using Username-Password Oauth authorization flow, to get access token. Below is the javascript code I am ...
1
vote
2answers
13 views

Sending an email to a User defined from a lookup?

I have a lookup field on our Opportunities, that pulls a User in our Organization. I need to be able to email that specific user when the opportunity changes. I can already figure out how to make a ...
1
vote
1answer
26 views

Recursively displaying a map of lists on a Visualforce page

I'm trying to create a customized version of the campaign hierarchy page, allowing for the display of additional data other than just campaign names. I have a Map<ID, List<Campaign>> keyed ...
2
votes
1answer
28 views

Mapping function for apex sharing

So I'm trying to create a function that allows you to create a sharing rule through Apex with any Object. Is there a way to generalize this so I don't have repeating code? From what I understand the ...
1
vote
0answers
10 views

How can I upload/change user's profile image programatically or via API?

I know, that there is no way to mass-upload these images via dataloader as described here can I upload user's profile image via data loader ...
1
vote
2answers
29 views

Lead conversion unit tests throw errors for validation rules that use custom settings

I'm running into an odd issue with some of my unit tests & can't seem to find out what exactly is causing it the problem. Several of my unit tests revolve around converting a lead to an account ...
0
votes
0answers
10 views

How can I display a Case feed for our Supports Tickets?

I've been working on a Web-to-Case full suite for my company and I've hit a roadblock. I don't particularly understand the relationship between Case, CaseFeed, and FeedItem. I can already get a ...
-1
votes
1answer
26 views

ANSWERED: SOQL Returned Sets Inside Of Cells - Not Sure What To Do Next With Apex

I am working with 3 SalesForce objects: Enrollment_New__c, Application_Checklist__c, and Opportunity. Application_Checklist__c and Opportunity are both in a "child" relationship to the parent ...
0
votes
1answer
12 views

Getting View state error on multiple Bulk uploading of list of attachments from VF page

I have a requirement to Upload List of attachments from VF page in one click but iam getting a view state error on uploading a bulk data. so I tried using "Remoting" even in remoting there are some ...
1
vote
1answer
8 views

How to show a related list custom button on Salesforce 1 mobile app

I have a requirement where I have to redirect to the custom visualforce page via URL. We have 1 Account record and it has Case related list. In the Case related list we have 1 custom button "Ceate ...
0
votes
1answer
24 views

Compare 2 var incremented by differents loop in a VF page

I have a VF page which display letters. In the first part I have the display of letters with a first apex:repeat In the second part, I display a summary (name of letters) with a second apex:repeat. ...
2
votes
2answers
40 views

File Attachment Upload - Maximum File Size limit exceeded (135MB)

I have used simple code to upload File. Now My page is not giving me the following error: Maximum File Size limit exceeded (135MB) But My page is simply coming back to its previous stage ...
0
votes
2answers
41 views

Trigger checkbox when Insert/Update

I would like to update the checkbox field 'New' to false when there's a new record inserted or updated when the colID is more than the previous colID. For instance: My record as shown: ProdID = 1 ...
0
votes
0answers
9 views

SingleEmailMessage with public sites user throwing error

is anyone using a public site and sending an email with this public sites user through an apex class with the SingleEmailMessage Method. It always worked very well but since some time i get the error ...
0
votes
0answers
7 views

Accessing Access Token Via Google Auth Provider

I have setup Google as an Auth Provider successfully. Using the Auth provider users are able to login into salesforce via Google. But when i try to access Access token via Auth.AuthToken class in ...
0
votes
0answers
9 views

Show selected file to upload as link [on hold]

I have multiple file upload page. Here I need to show the selected files attached as link before upload button is hit even. Can someone help me here? ...
0
votes
1answer
13 views

How to reset salesforce community password when SSO is enabled

I created a salesforce community using Partner community licence. I enabled some contacts as community user. so a corresponding user is created for them. Now i want to reset the password for them. My ...
1
vote
0answers
21 views

Attachment Parentid population

I have two VF Pages. Say V1 , V2 where V1 is my parent page and V2 is included in it. Here in V1 an instance of a custom object (Call) is created and in DML insert it gets into the system. In V2 ...
2
votes
1answer
21 views

Map: Group by common field value

Is it possible to group by a common field value? There is no aggregate integer, just simply a shared value in a custom field. For example: SELECT Franchise_Account__c, Id, FROM Account WHERE ...
0
votes
1answer
21 views

Updating custom lookup value from controller

I have been struggling with this problem for awhile and appreciate any help or suggestions to resolve this In my ORDERS I have added a custom field "ClassTeacher_c", this is a custom lookup field ...
1
vote
1answer
20 views

Can we Access Multi-Currency Values from Custom Setting using Apex Trigger

I have a Standard Object "Opportunity" I want to access a custom-setting with multiple currency I have multi-currency enabled in my org. Generally a custom setting can be accessed like follows ...
5
votes
2answers
104 views

What is the best practice re: API Version of your Apex Classes?

I'm in the process of pushing some updates to some code I originally wrote 12-18 months ago, and the API Version is between 27.0 and 29.0 I know this is to protect the integrity of the test classes ...
1
vote
0answers
14 views

Do I need Trigger to display Read sign on email from cases?

I wanted to show that new email is arrived and read when it is received for any cases in salesforce. I tried workflow (Email Message: Is IncomingEQUALSTrue) AND (Email Message: StatusEQUALSNew) ...
2
votes
2answers
54 views

Relating a task when an opportunity is updated. Before or After Update trigger?

I am confused about using a Before or After Update trigger. The scenario is that I want to create a new task and relate it to an opportunity when it's updated with a Stage = 'Closed Won'. From what ...
-2
votes
0answers
17 views

How to know from which quarter we are getting the data in visualforce page

Can any one help me out ?Do we have an option to know from which quarter we are getting the data in visualforce page.I have a visual force page in PDF format .In the table it displays the value for ...
0
votes
1answer
29 views

Integer declaration

I have below method in a public with sharing class. In the method, I need to use an integer but unable to declare that. Can someone please help me in integer declaration here? Snippet: public with ...
0
votes
0answers
8 views

Create Multiple large attachment records for a custom object

I have a piece of code where I need to implement multiple large attachment records upload capability for a custom object(Call2_vod__c) record as it's parentid. Can someone help me here please? Page: ...