Salesforce | Editing a task assigned to another user by task owner

Author - Kiran Preet
|
0 Comments
|

Problem: Task owner was not able to edit the task which is assigned to other user. I have a situation where a system admin assigns a standard user as an owner of the lead.

Like in my case Abc is system admin who assigns John as lead owner Read more…

Salesforce | Fetch all the tasks related to an sfobject

Author - Webner
|
0 Comments
|

Description: I have a situation where I want to fetch all the tasks related to the account object.

Solution: You get all the task records which belong to any of SF object using single SQL query.

For Single object:
For Example, I want to Read more…

PHP | Only first word showing in textbox from assigned sentence

Author - Webner
|
0 Comments
|

Problem: After the first space in the string no data appears in the input field.

There is an issue when a string contains words with spaces and we want to display the whole string in an input field but after the first space, no data is displayed in Read more…

Adding custom merge tags to the Gravity forms

Author - Komal

Merge Tags in gravity forms are the tags that are used to dynamically populate the field values in the form content in gravity forms like IP address, browser name, logged in user name etc . There are many merge tags available in the gravity forms by default.

But sometimes there may Read more…

WordPress | How to retrieve query variables in plugins

Author - Harleen Kaur
|
0 Comments
|

Suppose the URL contains query string for example www.mywebsite.com/sme_page?q=12
then the value of query variable can be retrieved in PHP using the get method such as:
<?php
echo $_GET[‘q’];  
?>
While creating a plugin for WordPress, to retrieve a value of query variables Read more…

Postgresql | Querying over local and remote database together

Author - Kailash
|
0 Comments
|

You can create a dblink to a remote database in postgresql and query both local and remote together. Steps and an example below:

1. Enable dblink in postgresql
CREATE EXTENSION dblink;

2. Create connection with database server
SELECT dblink_connect(‘dbname=abc port=1234 host=abc user=abc password=abc’);

3 Read more…

Jquery | Perform dynamic operation on load of Datatable

Author - Neha Mishra
|
0 Comments
|

Functionality needed : Once the datatable is completely loaded using ajax, I want to show second column only if role of the logged-in user is admin, else hide it.

What we need to do is, call API “initComplete” in datatable’s callback .
Do something like below :

$(document).ready(function() {

$(‘#example Read more…

How to add multiple modules and controllers in angularjs

Author - Neelam
|
0 Comments
|

If we have multiple modules and controller in single page i.e. :
<div id=”id1” ng-app=”App1″ ng-controller=”productController”> </div>
<div id=”id2” ng-app=”app2″ ng-controller=”orderController”> </div>
We need to add angular.bootstrap after adding the controllers Read more…

CakePhp 3.x | Send Email using SMTP

Author - Parminder Kaur
|
1 Comment
|

To send an email in cakephp use Email class of Cakephp 3. In app.php under config folder, add a new entry in the table EmailTransport.

For example here ‘mail’. Specify host, port, username and password in it:
‘EmailTransport’ => [
‘default’ => [
‘className’ => ‘Mail’,
// The following keys are used Read more…

Java | Method overriding and exceptions

Author - Rita
|
0 Comments
|

Problem: Suppose you have a method M1 in class A that throws exception E1 and you override this method in class B (B extends A). Are there any rules about exceptions when methods are overridden?

Solution:

There are following rules for overriding method if it is throwing exceptions:

If a Read more…

Salesforce | ALL ROWS

Author - Webner
|
0 Comments
|

How to get all records of sfobject including records in recycle bin of salesforce and undelete the records?

List objlst = [select id,isdeleted from sfobject ALL ROWS]; //Just add ALL ROWS at the end of SOQL, it retrieves all the records including deleted records in recycle bin:
System.debug(‘objlst Read more…

ASP .NET | InvalidOperationException: An asynchronous module or handler completed while an asynchronous operation was still pending

Author - Neha Mishra
|
0 Comments
|

[InvalidOperationException: An asynchronous module or handler completed while an asynchronous operation was still pending]

Error : Asp.net Web API – parent method executes itself before the child asynchronous method is completed.

Description : I have a public method that calls an asynchronous method. This asynchronous method returns void. See below :

Code :

public Read more…

CakePHP 3.x | How to change URL of your website to hide controller/action name

Author - Richa
|
0 Comments
|

Requirement: While running the website in browser, the url path shows controller name followed by the action name and parameters list. In that case the url looks like:

www.xyz.com/User/showDetails/

We may come across two types of requirements.

Displaying only the action name without showing Read more…

Javascript | How to call ajax in DevExtreme component using angularjs

Author - Neelam
|
0 Comments
|

var folderApp = angular.module(“folder”, [“dx”]);
folderApp.controller(“folderController”, [“$scope”, “$http”, function($scope, $http) {

$scope.gridSettings = {

columns: [{
dataField: “myObjectName”,
caption: “Name”,
} {
dataField: “myObjectEmail”,
caption: “Email”,
}],

dataSource: new DevExpress.data.CustomStore({
load: function(loadOptions) {
return $http({
method: “GET”,
url: ” ”;
headers: {},
}).then(function(data) {
return {
data: data.data,
totalCount: data.data.length Read more…

Salesforce: Execute flow from Process Builder

Author - Webner
|
0 Comments
|

How to execute flow from Process Builder in salesforce?
Sometime it is very useful to execute flow from the Process Builder. We can execute as many flows as we want. Flow can be used to create record, update record or send any alert or email to the user. In this Read more…

Selenium | Find a particular window and close it via code

Author - Webner

If multiple browser windows are opened, then find a particular window and close it by using web driver.

We can do so by using the following function:

public static void switchControlToSpecifiedWindow(WebDriver driver) {
Iterator < String > windows = driver.getWindowHandles().iterator();
while (windows.next()) {
driver.switchTo().window(windows.next());
String title = driver Read more…

Ubuntu | Remove sendmail completely

Author - Ishpreet Kaur

Problem: I installed sendmail in my ubuntu system with the help of link http://lukepeters.me/blog/getting-the-php-mail-function-to-work-on-ubuntu. I installed it to test php mail functionality on localhost for my project. It was working slow, therefore, after testing, I wanted Read more…

Microsoft Azure | Deploy ASP.NET Web Project on Microsoft Azure

Author - Neha Mishra
|
0 Comments
|

1.Go to Server Explorer. Right- click on Azure and click on Connect to Microsoft Azure subscription.

A login screen will appear. Enter valid credentials with at least one subscription and sign-in.

2. Now expand Azure. Right click on App Service and create a new web App. See below Read more…

PDFtk | View PDF field information from command line

Author - Kiran Preet
|
0 Comments
|

Solution: If you have a pdf and you do not know the names of the fields used in the pdf just follow these steps:

1.   Install pdftk (search online).
2.   Open the command prompt, run the command:
pdftk YourPdf.pdf dump_data_fields

Using Above command you will get information Read more…

Java | Hibernate best practices

Author - Rita
|
0 Comments
|

1.  Always define hashCode() and equals() methods in your Persistent classes.
2.  Persistent class method’s equals() and hashCode() must access its fields through getter methods. It is a good practice to use accessor methods instead of direct instance variable access.
3.  Always Implement Serialization with your entity classes. It Read more…

‹ Prev page1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 Next page ›
Send your message