• ptran123
  • NEWBIE
  • 0 Points
  • Member since 2013

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 3
    Questions
  • 2
    Replies

I looks like Messaging.SingleEmailMessage provides both of these methods.  I was wondering if I can set both the plain text and the html for this email.  Then, depending on the recipient's email configuration, one's email reader will choose the appropriate content.  Thanks in advance.

Baffling, I don't think I am doing anything wrong since I've created PDFs like this before.  Based on the code below, the div should pick up the style.  Not the case.

 

<apex:page renderAs="pdf">
<html>
  <head>
    <style>
      #message {
        color: red;
      }
    </style>
</head>

  <div id="message">Should display in red</div>
</html>
</apex:page>

 

I have other PDF pages that render out correctly.  I copied that code over to this new VF page.  Same issue as stated.  I've tried with recreated a new VF page. No success.  I am stumped.  Any help is appreciated.

I don't know what I am doing wrong.  I am try to create a Contact, then link it with an Account.  Here is the gist of it.

 

 

Account a = new Account();
a.Name = 'account1';
insert a;

Contact c = new Contact();
c.Account__c = a;         // is this the right way to link them together?
insert c;

 

Contact cc = [ select name, Account.Name from Contact ];
System.debug(cc.Account);    // Account is null here.  Why?

 

Much appreciated if someone figures this out.  I am stumped.  

I looks like Messaging.SingleEmailMessage provides both of these methods.  I was wondering if I can set both the plain text and the html for this email.  Then, depending on the recipient's email configuration, one's email reader will choose the appropriate content.  Thanks in advance.

Baffling, I don't think I am doing anything wrong since I've created PDFs like this before.  Based on the code below, the div should pick up the style.  Not the case.

 

<apex:page renderAs="pdf">
<html>
  <head>
    <style>
      #message {
        color: red;
      }
    </style>
</head>

  <div id="message">Should display in red</div>
</html>
</apex:page>

 

I have other PDF pages that render out correctly.  I copied that code over to this new VF page.  Same issue as stated.  I've tried with recreated a new VF page. No success.  I am stumped.  Any help is appreciated.