Here you will find some thoughts, some tips and some notes that help me to remember or that I think would be nice to share.
quinta-feira, 28 de setembro de 2017
Salesforce - Delete list of Attachment
Developer Console >> Debug >> Open execute Anonymous Window
List<Attachment> ListAttachments =
[SELECT id from Attachment];
System.debug(
ListAttachments.size()
);
delete ListAttachments;
Deleting Cases and Contacts
List<Case> ListCases =
[SELECT id from Case];
System.debug(
ListCases.size()
);
delete ListCases;
List<Contact> ListContacts =
[SELECT id from Contact];
System.debug(
ListContacts.size()
);
delete ListContacts;
quarta-feira, 13 de setembro de 2017
Salesforce - Days Since Last Update is empty - Use Formula Fields
Today I was doing trailhead "Use Formula Fields" and I got stuck where the formula wasn't showing any result.
The issue was because I didn't have any Account with Last Activity. I just had to go to an Account and in the Activity History section I clicked on Log a call, and saved it. After that you are good to go, you should see one Case record with Days Since Last Update as empty.
The issue was because I didn't have any Account with Last Activity. I just had to go to an Account and in the Activity History section I clicked on Log a call, and saved it. After that you are good to go, you should see one Case record with Days Since Last Update as empty.
quinta-feira, 7 de setembro de 2017
Salesforce - Lightning - Redirect to a specif Page
From:
PageReference newpage = new PageReference('/apex/MyPage');
newpage.setRedirect(true); return newpage;
To: PageReference newpage = new PageReference('/one/one.app#/n/MyPage'); newpage.setRedirect(true);
return newpage;
function FF_GetVisualforcePageURL(pPage, pNamespace){
var vLightning = '';
if ((typeof sforce != 'undefined') && sforce && (!!sforce.one)) {
vLightning = '/one/one.app#/alohaRedirect'
}
return vLightning + '/apex/' + pNamespace + pPage
}
PageReference newpage = new PageReference('/apex/MyPage');
newpage.setRedirect(true); return newpage;
To: PageReference newpage = new PageReference('/one/one.app#/n/MyPage'); newpage.setRedirect(true);
return newpage;
function FF_GetVisualforcePageURL(pPage, pNamespace){
var vLightning = '';
if ((typeof sforce != 'undefined') && sforce && (!!sforce.one)) {
vLightning = '/one/one.app#/alohaRedirect'
}
return vLightning + '/apex/' + pNamespace + pPage
}
quarta-feira, 23 de agosto de 2017
Salesforce - Error when try to deploy - Invalid field:VERSION.TITLE in related
segunda-feira, 29 de agosto de 2016
iMIS - Force HTTP
iMIS - Force HTTPS
To force HTTP in all the pages, even if the user change the url, it will back to use HTTP in the page.terça-feira, 31 de maio de 2016
iMIS - C# - Creating an user credential
Here is a piece of code to create an user credential and update the Asp_membership table.
objContact.CreateUserSecurity("username01", "123456");
objContact.UserSecurity.ExpiresOn = DateTime.Parse("01/01/2050");
objContact.UserSecurity.Save();
objContact.Save();
//Don't forge to update the aspnet_membership table. - Otherwise the forget password doesn't work.
MembershipUser objMembership = Membership.GetUser(sEmail);
objMembership.Email = sEmail;
Membership.UpdateUser(objMembership);
iMIS Template - Advice
I will put here all the stuff that I think is important to remember when you create a new iMIS Template and App_Theme.
Importing fonts on iMIS.
Create a CSS file just for fonts that will be loaded as the first css.
10 - Fonts.css
@import url(https://fonts.googleapis.com/css?family=Lato);
20 - Lodon_Responsive.css
If you don't do that, if you add the font in the master page, it won't load when you open a popup such as Register Someone.
Assinar:
Postagens (Atom)
