Showing posts from 2011

Displaying pop-up summaries on hover in visualforce

What if I want to make a summary pop-up window when a user hovers over a link in a visualforce page. This Feature is easy in standard salesforce pages, mostly because it happens automatically. But not in visualforce pages. I have seen most of example for pop-up in salesforce were created using the output panels with some embedded styles. Here I'm posting a pop-up example which show the details of a partuclar record on a mouseover using the Hover links similar to those used in standard Salesforce links.  /*visualforce page*/
<apex:page controller="PopupTest"> <apex:form > <apex:repeat value="{!accounts}" var="acc"> <br/> <a href="/{!acc.Id}" id="{!acc.Id}" onblur="LookupHoverDetail.getHover('{!acc.Id}').hide();" onfocus="LookupHoverDetail.getHover('{!acc.Id}', '/{!acc.Id}/m?retURL=%2F{!acc.Id}&isAjaxRequest=1').show();&qu…

Summer '11 New Features - part 1 (Javascript Remoting)

JavaScript remoting was released as a Developer Preview in Spring '11. In Summer '11, JavaScript remoting now supports additional return data types. Also, references to the same objects are no longer duplicated in the response. Javascript remoting is the process that provides support for some methods in APEX controllers to be called via Javascript.

This is an interesting feature and it'll be a good move to the interactive and fast user interface creation in visualforce. I have mentioned about javascript remoting one of my previous post. There is a nice example about Javascript Remoting.

Real-time sandbox environments in Salesforce

Parameter passing using Javascript+actionFunction in visualforce

In visualforce, there is a method for passing parameters from visualforce page to controller using javascript and actionFunction. Here is the example;
/*JavaScript*/<script type="text/javascript">
function doSave(date) {
/*Action Function*/<apex:actionFunction name="paraFunction" action="{!saveInterviewDate}" rerender="view">
<apex:param id="aname" name="interviewDate" value="" />
/*Call the javaScript from here*/<apex:commandLink onclick="doSave('{!$Component.interviewDate}');">
<apex:commandButton value="Save"/>
/*get the parameter in controller*/String interviewdate=Apexpages.currentPage().getParameters().get('interviewDate');

Javascript Remoting for APEX controller

Javascript remoting is the process that provides support for some methods in APEX controllers to be called via Javascript.The @RemoteAction annotation is currently available as a Developer preview.You have to contact support to enable this feature.To use Javascript remoting, your request must take the following form:

Javascript with Visualforce pages

Javascript is one of key browser technology on Visualforce pages. Javascript provides the framework for communication between other Javascript objects, HTML elements and visualforce controller. This example will explain how can we use javascripts in visualforce pages.


function changeFont(input, textid) {
if(input.checked) document.getElementById(textid).style.fontWeight = "bold";
else document.getElementById(textid).style.fontWeight = "normal";

<apex:outputPanel layout="block">
<label for="checkbox">Click this box to change text font: </label>
<input id="checkbox" type="checkbox"

<apex:outputPanel id="thePanel" layout="block">Change me!

'{!$Component.idName}' : This is the way of passing part…

Multi-Currency in

Basically the multi-currency feature is not available in your organization on salesforce. We have to log a case or contact salesforce support team for activate the multi-currency feature on your organization.This request can only be made by a System AdministratorPrior to converting your organization to multi-currency, some aspects of this feature that should be reviewed.The Multi-Currency functionality CANNOT be turned off once it is activated. support team also recommends testing the activation in a Sandbox environment. The process locks the org when turning on Multi Currency (preventing users from logging in), this can take 30 minutes or more depending on the size of the organization. After activate this feature on your organization, you will have a standard field called "CurrencyIsoCode" as picklist in ont only standard objects but also in custom objectsAnd You will have a place to manage your currencies in following path;Your Name-->Setup-->Administr…

Inline Editing in Visualforce page

Inline editing in Visualforce was introduced with the Spring'11. It has the ability to turn on inline editing within Visualforce, a handy bit of user friendliness which has been availability in the standard application interfaces for some time. Enabling inline editing is simple. My example is related with the Contact Standard object. But this feature will work with custom objects as well.
<apex:page standardController="Contact">
<apex:form >
<apex:pageBlock mode="inlineEdit">
<apex:pageBlockButtons >
<apex:commandButton action="{!edit}" id="editButton" value="Edit"/>
<apex:commandButton action="{!save}" id="saveButton" value="Save"/>
<apex:commandButton onclick="resetInlineEdit()" id="cancelButton" value="Cancel"/>
<apex:pageBlockSection >
<apex:outputField value="{!contact.lastn…

Save an attachment in APEX

What is Salesforce?

Salesforce CRM is a web-based Customer Relationship Management (CRM) service. It allows you to create a single view of your customers and leads, coordinate your sales, marketing and customer service activities and provides an overview into how your business is operating. You can generate, manage, and report on leads, opportunities and track results from first contact to won or lost business. You can see the results of your marketing campaigns and understand their impact using real-time analytics. It helps to improves efficiency, reduces administration time and lets you focus more on your business by reducing the time taken to search for information by providing a centralized service.Salesforce has several products and service categories such as Sales cloud, Service cloud, Data cloud, Collaboration Cloud (including Chatter) and Custom Cloud (

Cloud Computing

Cloud computing is a technology that uses the internet and central remote servers to maintain data and applications. Cloud computing allows consumers and businesses to use applications without installation and access their personal files at any computer with internet access. This technology allows for much more efficient computing by centralizing storage, memory, processing and bandwidth.

Cloud computing comes into focus only when you think about what IT always needs: a way to increase capacity or add capabilities on the fly without investing in new infrastructure, training new personnel, or licensing new software. Cloud computing encompasses any subscription-based or pay-per-use service that, in real time over the Internet, extends IT's existing capabilities.

Cloud computing is at an early stage, with a motley crew of providers large and small delivering a slew of cloud-based services, from full-blown applications to storage services to spam filtering. Yes, utility-s…