Author: Webner
How to add multiple modules and controllers in angularjs
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: var App1 = angular.module(App1, []); mySampleApp.controller(productController, function($scope) {}); var
Java | Method overriding and exceptions
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
Salesforce | ALL ROWS
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
ASP .NET | InvalidOperationException: An asynchronous module or handler completed while an asynchronous operation was still pending
[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
CakePHP 3.x | How to change URL of your website to hide controller/action name
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
Javascript | How to call ajax in DevExtreme component using angularjs
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: ” ”;
Salesforce: Execute flow from Process Builder
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
Selenium | Find a particular window and close it via code
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();
Ubuntu | Remove sendmail completely
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 to uninstall it completely
