Hi, When you want to display related list on visualforce page, you can use <apex:relatedList> tag, and it is very easy for ex: <apex:page standardController="MyMasterObject__c"> <apex:relatedList list="MyChildObjects__r" /> </apex:page> but this will display all the columns from related list including “Action” column and many times we don’t want to...
Custom Send Email button on custom Objects
Hi, If you want to add a custom button to send email on custom object then follow below mentioned steps: 1. Create Custom button on custom object; 2. in the content source, select URL; 3. in the value section, add following url {!Estimate__c.Bill_To_NameId__c}&rtype=003&doc_id=00Pi0000000OluX&retURL=/{!Estimate__c.Id}?srPos=0&srKp=00T where Estimate__c.BillToNameId__c is the...
java.lang.OutOfMemoryError: Java heap space
add line to catalina.sh or catalina.bat: export CATALINA_OPTS=”-Xms512M -Xmx1024M” a) The -Xmx argument defines the max memory size that the heap can reach for the JVM. A low value can cause OutOfMemoryExceptions or a very poor performance if your program’s heap memory is reaching the maximum heap size. b) The -Xms argument sets the initial heap memory size for the JVM. This...
java.security.AccessControlException: access denied (java.net.SocketPermission host connect,resolve)
The Simple solution is :search catalina.policy file and edit green line as // Precompiled JSPs need access to this system property. permission java.util.PropertyPermission”org.apache.jasper.runtime.BodyContentImpl.LIMIT_BUFFER”,”read”; permission java.net.SocketPermission “*”, “connect”; permission java.net.SocketPermission “*”...
Learning The Many Advantages of PHP
PHP, which is short for Hypertext Preprocessor, is an open source server side programming language available at free of cost that can be easily obtained from the market. It has a coding style that is quiet and easy to understand and is usually very proficient on multi-platforms like Windows, Linux, and UNIX and other more. Today, PHP is one of the most popular server side scripting languages...
Display Facebook likes / Shares PHP function
The Code Below is a super simple function that retrieves a JSON feed of comments, likes and shares for any URL you provide. function facebook_shares($url){ $fql = “SELECT url, normalized_url, share_count, like_count, comment_count, “; $fql .= “total_count, commentsbox_count, comments_fbid, click_count FROM “; $fql .= “link_stat WHERE url = ‘”.$url...
Show Google Plus’s – PHP function
It’s worth pointing out you must have CURL enabled on your web server, I believe it’s enabled by default on PHP5 setups. Also the Key below Isn’t a unique API key you must leave the key as is to ensure the code works properly. function gplus_shares($url){ // G+ DATA $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, “;); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch...
Voice Recording in Android
Put below code into your main Activity. private static final String AUDIO_RECORDER_FILE_EXT_3GP = ".3gp"; private static final String AUDIO_RECORDER_FILE_EXT_MP4 = ".mp4"; private static final String AUDIO_RECORDER_FOLDER = "AudioRecorder"; private MediaRecorder recorder = null; private int currentFormat = 0; private int output_formats[] = { MediaRecorder.OutputFormat.MPEG_4, MediaRecorder...
How to Add Smiley/Emojis in Edittext?
Emoji.java :- package com.android.emoji; import android.app.Activity; import android.content.Intent; import android.content.SharedPreferences; import android.graphics.drawable.Drawable; import android.os.Bundle; import android.text.Html; import android.text.Html.ImageGetter; import android.view.View; import android.view.View.OnClickListener; import android.widget.Button; import android...
Draw flexible lines on touches Moved in iphone View Based application
// .h ———File CGPoint lastPoint; UIImageView *drawImage; BOOL mouseSwiped; int mouseMoved; //.m ———File – (void)viewDidLoad { [super viewDidLoad]; drawImage = [[UIImageView alloc] initWithImage:nil]; drawImage.frame = self.view.frame; [self.view addSubview:drawImage]; self.view.backgroundColor = [UIColor yellowColor]; } – (void)touchesBegan:(NSSet...