git grep "regex"
git branch -a
<!------------------------------------------------------------------------------------ | |
CreatePDFControllerExtension.cls | |
Example Apex code to create a button in Salesforce that will automate the PDF creation using the 'Account' standard bject | |
(c) Copyright 2014 HEWLETT-PACKARD COMPANY | |
DISCLAIMER: The sample code described herein is provided on an "as is" basis, without warrant of any | |
kind, to the fullest extent permitted by law. Both Hewlett-Packard Company and I do not warrant or |
options = { :body => | |
{ :username => 'my', | |
:password => 'password' | |
} | |
} | |
results = HTTParty.post("http://api.topcoder.com/v2/auth", options) | |
## | |
## example for post with papertrail and basic auth | |
## |
Integer classLines = 0; | |
Integer triggerLines = 0; | |
for(ApexClass a : [Select Body From ApexClass]){ | |
List<String> lines = a.Body.split('\n'); | |
classLines += lines.size(); | |
} | |
for(ApexTrigger a : [Select Body From ApexTrigger]){ | |
List<String> lines = a.Body.split('\n'); |
Afghanistan | |
Albania | |
Algeria | |
Andorra | |
Angola | |
Antigua & Deps | |
Argentina | |
Armenia | |
Australia | |
Austria |
<apex:page> | |
<head> | |
<apex:includescript value="//code.jquery.com/jquery-1.11.1.min.js" / > | |
<apex:includescript value="//cdn.datatables.net/1.10.4/js/jquery.dataTables.min.js" /> | |
<apex:stylesheet value="//cdn.datatables.net/1.10.4/css/jquery.dataTables.css" /> | |
<!-- I have a static resource called famfamfam which is the zip file from http://www.famfamfam.com/lab/icons/silk/famfamfam_silk_icons_v013.zip --> | |
<style> |
<messaging:emailTemplate subject="Close Opportunity" | |
recipientType="User" | |
relatedToType="Opportunity"> | |
<messaging:htmlEmailBody > | |
<html> | |
<body> | |
Opportunity: <a href="https://test.salesforce.com/{!relatedTo.id}"><apex:outputText value="{!relatedTo.name}"/></a> | |
<br/> |
Apex Coding Standard | |
Introduction | |
------------- | |
Apex is a strongly-typed, object-oriented, proprietary programming language for the Force.com platform. | |
It lets you execute flow and transaction control statements in conjunction with calls to the Force.com API. | |
Apex borrows it's syntax from Java, and functions like a database stored procedure. | |
To learn more about Apex, read the developer documentation on the Force.com developer site. | |
[http://www.salesforce.com/us/developer/docs/apexcode/index.htm] |
This is an adaptation of Cody Sechelski's Create a Calendar View in Salesforce.com.
The main problem with his implementation was that it wasn't handling more than 2000 records. This was due to a Apex workaround, as it is reserves start and end variables, Cody made a repeat table and parsed that into JavaScript object. My solution creates JSON string in Apex and then uses string function to replace all startString and endString instances. A more sensible solution would involve recreating the object in JavaScript or simply editing the FullCalendar library to look for different variable names.
I have also simplified the code a bit so you can start working towards your personal implementation. As this is using JavaScript remoting, I hope this gives you a framework to work towards more advanced features like editing or optimizing request sizes (executing a request on next month load).
The page
<apex:page showHeader="fals
@isTest | |
private class TestDemoWebCallout { | |
static testMethod void testRestfulCallout() { | |
Lead l = new Lead(); | |
l.Status = 'Open'; | |
l.LastName = 'Owen'; | |
l.FirstName = 'Bob'; | |
l.Street = '1234 Sesame Street'; | |
l.City = 'Houston'; |