ghjhg" s} {dfgdfg " "
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Text; | |
namespace MyExtensions | |
{ | |
public static class DateTimeExtensions | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Text; | |
using Excel = Microsoft.Office.Interop.Excel; | |
using MyExtensions | |
namespace MyExtensions | |
{ | |
public static class ExcelExtensions |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Text; | |
using Excel = Microsoft.Office.Interop.Excel; | |
namespace AnalysisSuite.Extensions | |
{ | |
public static class ObjectExtensions | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//dataRow is the class that Salesforce applies to all data rows, but you could equally use this in a non Salesforce context | |
$(".dataRow").click(function(event) | |
{ | |
//Ignore link and checkbox clicks, otherwise find the row's checkbox and click it | |
if(event.target.type!=="checkbox" && !$(event.target).is('a')) { | |
$(this).find($("input:checkbox")).click(); | |
} | |
}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Adapted from http://boards.developerforce.com/t5/Apex-Code-Development/Detect-a-required-field-in-Apex/td-p/129693 | |
Map<String, Schema.SObjectField> describeFields = Schema.SObjectType.Bank__c.fields.getMap(); | |
//CREATE A MAP WITH FIELD NAME AS KEY AND A BOOLEAN (Required) AS VALUE | |
Map<String, Boolean> fieldIsRequired = new Map<String, Boolean>(); | |
Map<String, Schema.DisplayType> fieldsTypes = new Map<String, Schema.DisplayType>(); | |
for(String field : describeFields.keyset()){ | |
Schema.DescribeFieldResult desribeResult = describeFields.get(field).getDescribe(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static Map<String, String> ISO3166_1_Alpha2_CountryToCode = new Map<String,String> { | |
'AFGHANISTAN'=>'AF', | |
'ÅLAND ISLANDS'=>'AX', | |
'ALBANIA'=>'AL', | |
'ALGERIA'=>'DZ', | |
'AMERICAN SAMOA'=>'AS', | |
'ANDORRA'=>'AD', | |
'ANGOLA'=>'AO', | |
'ANGUILLA'=>'AI', | |
'ANTARCTICA'=>'AQ', |
NewerOlder