function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
CloudGeekCloudGeek 

need input for a pop-up onclick button from Account Detail screen

Hi,

I need input on how to start with for the pop-up screen attached here.

I need to show a pop-up on a button click from an account detail page as shown in snapshot
User-added image


instead of showing any other page as pop-up, would like to create this purely in javascript/jQuery.
Thanks in advance!
Best Answer chosen by CloudGeek
ManojjenaManojjena
hi ,

try with below code it will help !!
{!REQUIRESCRIPT('//ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js')}
{!REQUIRESCRIPT('//ajax.googleapis.com/ajax/libs/jqueryui/1.10.3/jquery-ui.min.js')}
jQuery(function() {
jQuery('head').append('<link rel="stylesheet" href="//ajax.googleapis.com/ajax/libs/jqueryui/1.10.3/themes/start/jquery-ui.css" type="text/css" />');
var html ='<div id="dialog" title="Enter Comment"> <textarea id="txtn" rows="4" cols="30" id="rsn"></textarea></div>';
if(!jQuery('[id=dialog]').size()){
jQuery('body').append(html);
}
jQuery( "#dialog" ).dialog({
autoOpen: true,
modal: true,
show: {
effect: "explode",
duration: 2000
},
hide: {
effect: "explode",
duration: 2000
},
buttons: {
"Ok": function() {
var comnt = $('#txtn').val();
alert(comnt);
jQuery( this ).dialog( "close" );
},
Cancel: function() {
jQuery( this ).dialog( "close" );
}
}
});
});
Let me know if it help !!
Thanks
Manoj