Visualforce PDF Rendering Considerations and Limitations
OR
RenderasPDF considerations in visualforce
Limitations of the Visualforce PDF rendering service include:
PDF is the only supported rendering service.
Rendering a Visualforce page as a PDF is intended for pages designed and optimized for print.
Standard components that aren’t easily formatted for print, or form elements like inputs, buttons, or any component that requires JavaScript to be formatted, shouldn’t be used. This includes, but isn’t limited to, any component that requires a form element.
PDF rendering doesn’t support JavaScript-rendered content.
Font used on the page must be available on the Visualforce PDF rendering service. Web fonts...
Friday, January 30, 2015
Thursday, January 29, 2015
What are @Featuremethod Considerations?
What are @Featuremethod Considerations?
Methods with the future annotation must be static methods, and can only return a void type. The specified parameters must be primitive data types, arrays of primitive data types, or collections of primitive data types. Methods with the future annotation cannot take sObjects or objects as arguments.
Specify (callout=true) to allow callouts in a future method.
Specify (callout=false) to prevent a method from making callouts.
@future (callout=true)
public static void doCalloutFromFuture() {
//Add code to perform callout
}
Remember that any method using the future annotation requires special consideration because the method does not necessarily execute in the same order it is called.
Methods with the future...
Wednesday, January 28, 2015
What is difference between Action function and remote function?
What is difference between Action function and remote function?
1. Using action
function, you can call only same class function.
2. Remote Action returns the results from the class in Javascript.
3. Action function submit the page, Remote action doesn't
Remote
Action in Visual force page:
JavaScript
remoting in Visualforce provides support for some methods in Apex controllers
to be called via JavaScript.
•
namespace is your organization's namespace. This is only required if the class
comes from an installed packaged.
•
controller is the name of your Apex controller- MyJSControllers
•
method is the name of the Apex method you're calling- getAccount
•
params is comma–separated list of parameters that your method takes-accountNameJS
•
callbackFunction is the name of the...
Monday, January 26, 2015
Pros and Cons of Choosing Pagination in Salesforce.
Pros and Cons of Choosing Pagination in Salesforce.
Visualforce StandardSetController
The
StandardSetController is an extremely powerful tool with built-in functionality
that you can use to greatly simplify the custom code in your Visualforce pages.
Because the server returns only the data for the page being requested, the
StandardSetController can significantly reduce view state, especially compared
to the view state you would get while using SOQL.
Pros
· Manages data sets on the server, which reduces page state and
increases performance
· Allows you to paginate over large data sets that have up to
10,000 records
· Includes built-in functionality such as next, previous, first,
last, getResultSize, and other methods that can simplify your page
· Allows...
Sunday, January 25, 2015
How to Use Apex:enhancedList tag in Visualforce Page?

How to Use Apex:enhancedList tag in Visualforce Page?
Enhanced list views on a Visualforce page
Enhanced lists are used when you want to display a specific list view
for a standard or custom object, rather than having all list views
available for the user to select.
This tag
supports following attributes.
Attribute Name
Description
customizable
A Boolean value that specifies whether the list can be customized by
the current user. If not specified, the default value is true. If this
attribute is set to false, the current user will not be able to edit the list
definition or change the list name,...
I have requirement fire the trigger when data is uploading through data loader. It should not execute when record saved from User interface? How to achieve that?
I have requirement fire the trigger when data is uploading through data loader. It should not execute when record saved from User interface? How to achieve that?
You could add a custom checkbox field
which is hidden from the pagelayout.
· This field could be mapped to always
insert as "true" with dataloader.
· Make your after insert trigger only
execute conditionally on this field to be true.
· Optionally have your trigger set the
field to false, or you could keep it as true to see that these records were
imported through data loader.
...
How to Use Apex:listViews tag in Visualforce Page?

How to Use Apex:listViews tag in Visualforce Page?
The
list view picklist for an object, including its associated list of
records for the currently selected view. In standard Salesforce
applications this component is displayed on the main tab for a
particular object.
This tag
supports following attributes.
Attribute Name
Description
id
An identifier that allows the listViews component to be referenced by
other components in the page.
rendered
A Boolean value that specifies whether the component is
rendered on the page. If not specified, this value defaults to true.
...
How to Use Apex:relatedList tag in Visualforce Page?

How to Use Apex:relatedList tag in Visualforce Page?
It is going to display a list of Salesforce records that are related to a parent record with a lookup or master-detail relationship.
This tag
supports following attributes.
Attribute Name
Description
id
An identifier that allows the relatedList component to be referenced
by other components in the page.
list
The related list to display. This does not need to be on
an object's page layout. To specify this value, use the name of the child
relationship to the related object. For example, to display the Contacts
related list...
How to Use Apex:SectionHeader tag in Visualforce Page?

How to Use Apex:SectionHeader tag in Visualforce Page?
A title bar for a page. In a standard Salesforce page, the title bar is a colored header displayed directly under the tab bar.
This component supports HTML pass-through attributes using the "html-" prefix. Pass-through attributes are attached to the generated container <div> tag.
This tag
supports following attributes.
Attribute Name
Description
description
Descriptive text for the page that displays just under the colored
title bar.
help
A Boolean value that specifies whether the component is
rendered on the page....