• lil_ranger
  • NEWBIE
  • 25 Points
  • Member since 2011

  • Chatter
    Feed
  • 1
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 36
    Questions
  • 31
    Replies
Is it possible to update a case status based on whether a knowledge base article has been attached to a case?   Since a KB article can be attached to multiple cases and there is no direct relationship I could not do this via a normal workflow.  I did not know if a trigger would be the solution.
AND( 
ISPICKVAL(StageName, 'Closed Won'), 
ISBLANK( DiscountReasons__c), 
AND( 
OR( 
$RecordType.Name = "Partner Opportunity", 
$RecordType.Name = "End User Opportunity",
AND(
OR(
ISBLANK(MaxDiscountRequested__c)=FALSE,
MaxDiscountRequested__c > 0%
)))))

 Hi,

 

I need help creating a validation rule.  The MaxDiscountRequested__c is a formula (percent) field.  I'm trying to get it to display the error message, when that field is blank or greater than 1%.  Is this possible with a formula field?

 

Any help is greatly appreciated.

 

Thanks!

<td width="35%" valign="top" style="font-size: 12px;">
     {!Order__r.Company__c}<br />
     {!Order__r.Attention__c}<br />
     {!Order__r.StreetLine1__c}<br />
<apex:outputtext value="{!Order__r.StreetLine2__c}" rendered="!IF(NOT(ISBLANK(Order__r..StreetLine2__c)))}" /></apex:outputtext><br />
<apex:outputtext value="{!Order__r.StreetLine3__c}" rendered="{!IF(NOT(ISBLANK(Order__r.StreetLine3__c)))}" /></apex:outputtext><br />
     {!Order__r.City__c}, {!Order__r.State__c} {!Order__r.PostalCode__c}<br />
     {!Order__r.Country__c}<br />
</td>

I am getting this error: The element type "td" must be terminated by the matching end-tag "</td>  

I'm not sure why since I do have the end tag in there.

 

 

I have 3 survey questions that are ranked 1-5.  I'm trying to create a percentage formula field that will give me the overall percentage of the 3 questions.  

 

survey_question1__c = 4

survey_question2__c = 5

survey_question3__c = 5

 

Any help would be greatly appreciated.

I can't seem to get this date function to work.  I need the survey date to be null or to not be anything within 30 days

 

AND( 
NOT(CONTAINS(Contact.Email, 'yahoo.com')), 
Contact.Do_Not_Survey__c = false, 
ISPICKVAL(Status, 'Resolved'), 
CONTAINS($UserRole.Name, 'Tech'), 
$RecordType.Name = 'Support Ticket', 
AND( 
OR( 
ISNULL(Survey_Date__c), 
NOT(Survey_Date__c < TODAY () + 30) 
)))

 Any help would be greatly appreciated.  Thanks!

I am rendering a VF page as a word doc and I ran into 1 issue that I can't seem to fix.  I'd like this section to only appear if the "Training Site Address" checkbox is not checked, but it's displaying it when it is checked. Any help would be greatly appreciated.

 

<div style = "{!IF(Contract.Training_Site_Address__c == false,'','display:none;')}"> 
<table border="1" width="100%" cellspacing="0" cellpadding="0">
<tr>
<td><b>Company:</b> {!Contract.Training_Site_Company__c}</td>
<td></td>
</tr>
<tr>
<td><b>Attn:</b> {!Contract.Training_Site_POC__c}</td>
<td></td>
</tr>
<tr>
<td><b>Address:</b> {!Contract.Training_Site_Street_Address__c}</td>
<td></td>
</tr>
<tr>
<td width="75%"><b>City:</b> {!Contract.Training_Site_City__c}</td>
<td width="75%"><b>State:</b> {!Contract.Training_Site_State__c}</td>
</tr>
<tr>
<td width="75%"><b>Zip/Postal Code:</b> {!ROUND(Contract.Training_Site_Zip_Code__c,0)}</td>
<td width="75%"><b>Country:</b> {!Contract.Training_Site_Country__c}</td>
</tr>
</table>
</div>

 

Can Cloud Swarm allow a user to follow a specific record type of a custom object?

 

If so, should I be installed the managed or unmanaged app?

 

I am on the Enterprise version of SFDC

How would I update this formula field to display more than one choice?  The Type__c field is a multi-picklist, so I need this formula field to reflect that.  Any help would be greatly appreciated.  It currently only displays one choice even though the type field on the account I'm looking at displays 2.

 

IF(INCLUDES(Type__c,"Consultant"),"Consultant", 
IF(INCLUDES(Type__c,"Reseller"),"Reseller", 
IF(INCLUDES(Type__c,"End User"),"End User","")))

 

I have a VF page that renders as a pdf with images, tables, etc.  in rich text fields and they all display correctly in the pdf.

 

What I have to do now is render that same VF page as a Word document.  Problem is that even though the images show up on the SFDC page correctly they do not display in the Word document.  It displays a

 

How can I get whatever is in the rich text field when rendering as a word document?  Is this even possible?

 

Thanks!

AND(
Entitlement.EndDate < DATEVALUE(CreatedDate),
ISPICKVAL(Status, 'Open'),
$RecordType.Id = '0123000000008xP'
)

 I'm trying to write a validation rule to not allow a ticket to be created if the entitlement end date is less than the created date of the ticket.   Any ideas on what I did incorrectly?  

I'm trying to create a workflow the will notify the case owner when a case hasn't had any activtiy in the last 3 days.

I got this far and I'm stuck on the last activity date.   I was then going to create a task based off of the trigger date.

 

AND(
OR(
ISPICKVAL(Status, 'Open'),
ISPICKVAL(Status, 'Pending Support'),
AND(
$RecordType.Id = '0123000000009yN',
(NOW() - Last_Activity_Date__c)
))

 

 

<style type="text/css">
@page Section1 {
mso-footer:f1;
}
div.Section1{
page:Section1;
}
p.MsoFooter, li.MsoFooter, div.MsoFooter{
mso-pagination:widow-orphan;
tab-stops:center 216.0pt right 432.0pt;
}
</style>

 body of page

   <div style="mso-element:footer" id="f1">
<p class="MsoFooter">
<span style='mso-tab-count:2'></span>Page <span style='mso-field-code:" PAGE "'></span> of <span style='mso-field-code:" NUMPAGES "'></span></p>
</div>

 

I got the page number to appear at the footer, but on my last page it shows "Page  of ", which isn't in the footer.  Any ideas on how to remove this?

 

Thanks!

Is there a way to automatically open up the Word document with the "Print" layout instead of "Web" layout?

 

I am using Chrome, but some of the users use IE9.  Is there a way to open the Word document immediately, like it does when rendering as a pdf?  

I have a div statement that I can't seem to get to work properly.  If the checkbox isn't checked it is still displaying the table, but not "Estimated Labor Hours" line.   I'm sure it's something simple, but I can't seem to figure it out

 

<div style = "{!IF(Contract.Display_Labor_Hours_Table__c == true, '', 'display:none;')}">
<b>Estimated Labor Hours:</b><br />

<table border="1" width="100%" cellspacing="0" cellpadding="0">
<tr>
<th align="left"><b>Labor Category</b></th>
<th align="left"><b>Hours</b></th>
<th align="left"><b>Hourly Rate</b></th>
<th align="left"><b>Category</b></th>
</tr>
<tr>
<td>Architect</td>
<td>{!ROUND(Contract.Total_Estimated_Architect_Labor_Hrs__c,0)}</td>
<td><apex:outputField value="{!Contract.Architect_Hourly_Rate__c}"/></td>
<td><apex:outputField value="{!Contract.Total_Architect_Labor_Cost__c}"/></td>
</tr>
<tr>
<td>Consultant</td>
<td>{!ROUND(Contract.Total_Estimated_Consultant_Labor_Hrs__c,0)}</td>
<td><apex:outputField value="{!Contract.Consultant_Hourly_Rate__c}"/></td>
<td><apex:outputField value="{!Contract.Total_Consultant_Labor_Cost__c}"/></td>
</tr>
</table></div><br />

 

Is there a way to subtract 30 days from a date field in a Visualforce email template?  I have a close date that I want to subtract 30 days from.

 

Thanks!

I'm trying to update a text field based off of a checkbox. 

 

If checkbox a = true then update the text field to yes

If checkbox a = false then update the text field to no

 

Any help would be greatly appreciated.

Is it possible to create a formula for a field update to look at 2 different lookup fields and depending on which one is selected to populate a specfic text field?

 

Example: Product Owned (lookup) is blank but Asset (lookup) is not and pull in the product name text field based off of the selection.

 

IF(OR(
NOT(ISBLANK(Product_Owned__c)),Product_Owned__r.ProductName__c,
IF(
NOT(ISBLANK(Asset__c)),Asset__r.ProductName__c )))

 

Any info would be greatly appreciated.

<script>
   function defaultEmployeeTermForm(val) {
       var j$ = jQuery.noConflict();
   
       j$("input[id*='Status_Id']").attr("value", "Submitted By Manager");
   }
</script>

 Any ideas on what is wrong with this?  When the user saves the form I need the Status_Id to be updated to "Submitted By Manager".

 

 

AND(SUBSTITUTE(Assumptions__c , "~", "<br />"),
SUBSTITUTE(Assumptions__c, "^", "<li>"))

 Is it possible to have more than 1 substitute function in a field update?  I can get one of them to update, but not both. 

I'm trying to update a number field with field that is a text field  in another object.  Is this possible?

 

Field to Update: Contract Number

Field Data Type: Number

 

Update with: Entitlement.Contract_Number__c which is a text field

 

AND( 
ISPICKVAL(StageName, 'Closed Won'), 
ISBLANK( DiscountReasons__c), 
AND( 
OR( 
$RecordType.Name = "Partner Opportunity", 
$RecordType.Name = "End User Opportunity",
AND(
OR(
ISBLANK(MaxDiscountRequested__c)=FALSE,
MaxDiscountRequested__c > 0%
)))))

 Hi,

 

I need help creating a validation rule.  The MaxDiscountRequested__c is a formula (percent) field.  I'm trying to get it to display the error message, when that field is blank or greater than 1%.  Is this possible with a formula field?

 

Any help is greatly appreciated.

 

Thanks!

I have 3 survey questions that are ranked 1-5.  I'm trying to create a percentage formula field that will give me the overall percentage of the 3 questions.  

 

survey_question1__c = 4

survey_question2__c = 5

survey_question3__c = 5

 

Any help would be greatly appreciated.

I can't seem to get this date function to work.  I need the survey date to be null or to not be anything within 30 days

 

AND( 
NOT(CONTAINS(Contact.Email, 'yahoo.com')), 
Contact.Do_Not_Survey__c = false, 
ISPICKVAL(Status, 'Resolved'), 
CONTAINS($UserRole.Name, 'Tech'), 
$RecordType.Name = 'Support Ticket', 
AND( 
OR( 
ISNULL(Survey_Date__c), 
NOT(Survey_Date__c < TODAY () + 30) 
)))

 Any help would be greatly appreciated.  Thanks!

I am rendering a VF page as a word doc and I ran into 1 issue that I can't seem to fix.  I'd like this section to only appear if the "Training Site Address" checkbox is not checked, but it's displaying it when it is checked. Any help would be greatly appreciated.

 

<div style = "{!IF(Contract.Training_Site_Address__c == false,'','display:none;')}"> 
<table border="1" width="100%" cellspacing="0" cellpadding="0">
<tr>
<td><b>Company:</b> {!Contract.Training_Site_Company__c}</td>
<td></td>
</tr>
<tr>
<td><b>Attn:</b> {!Contract.Training_Site_POC__c}</td>
<td></td>
</tr>
<tr>
<td><b>Address:</b> {!Contract.Training_Site_Street_Address__c}</td>
<td></td>
</tr>
<tr>
<td width="75%"><b>City:</b> {!Contract.Training_Site_City__c}</td>
<td width="75%"><b>State:</b> {!Contract.Training_Site_State__c}</td>
</tr>
<tr>
<td width="75%"><b>Zip/Postal Code:</b> {!ROUND(Contract.Training_Site_Zip_Code__c,0)}</td>
<td width="75%"><b>Country:</b> {!Contract.Training_Site_Country__c}</td>
</tr>
</table>
</div>

 

AND(
Entitlement.EndDate < DATEVALUE(CreatedDate),
ISPICKVAL(Status, 'Open'),
$RecordType.Id = '0123000000008xP'
)

 I'm trying to write a validation rule to not allow a ticket to be created if the entitlement end date is less than the created date of the ticket.   Any ideas on what I did incorrectly?  

I'm trying to create a workflow the will notify the case owner when a case hasn't had any activtiy in the last 3 days.

I got this far and I'm stuck on the last activity date.   I was then going to create a task based off of the trigger date.

 

AND(
OR(
ISPICKVAL(Status, 'Open'),
ISPICKVAL(Status, 'Pending Support'),
AND(
$RecordType.Id = '0123000000009yN',
(NOW() - Last_Activity_Date__c)
))

 

 

I have a div statement that I can't seem to get to work properly.  If the checkbox isn't checked it is still displaying the table, but not "Estimated Labor Hours" line.   I'm sure it's something simple, but I can't seem to figure it out

 

<div style = "{!IF(Contract.Display_Labor_Hours_Table__c == true, '', 'display:none;')}">
<b>Estimated Labor Hours:</b><br />

<table border="1" width="100%" cellspacing="0" cellpadding="0">
<tr>
<th align="left"><b>Labor Category</b></th>
<th align="left"><b>Hours</b></th>
<th align="left"><b>Hourly Rate</b></th>
<th align="left"><b>Category</b></th>
</tr>
<tr>
<td>Architect</td>
<td>{!ROUND(Contract.Total_Estimated_Architect_Labor_Hrs__c,0)}</td>
<td><apex:outputField value="{!Contract.Architect_Hourly_Rate__c}"/></td>
<td><apex:outputField value="{!Contract.Total_Architect_Labor_Cost__c}"/></td>
</tr>
<tr>
<td>Consultant</td>
<td>{!ROUND(Contract.Total_Estimated_Consultant_Labor_Hrs__c,0)}</td>
<td><apex:outputField value="{!Contract.Consultant_Hourly_Rate__c}"/></td>
<td><apex:outputField value="{!Contract.Total_Consultant_Labor_Cost__c}"/></td>
</tr>
</table></div><br />

 

Is it possible to create a formula for a field update to look at 2 different lookup fields and depending on which one is selected to populate a specfic text field?

 

Example: Product Owned (lookup) is blank but Asset (lookup) is not and pull in the product name text field based off of the selection.

 

IF(OR(
NOT(ISBLANK(Product_Owned__c)),Product_Owned__r.ProductName__c,
IF(
NOT(ISBLANK(Asset__c)),Asset__r.ProductName__c )))

 

Any info would be greatly appreciated.

AND(SUBSTITUTE(Assumptions__c , "~", "<br />"),
SUBSTITUTE(Assumptions__c, "^", "<li>"))

 Is it possible to have more than 1 substitute function in a field update?  I can get one of them to update, but not both. 

I'm trying to update a number field with field that is a text field  in another object.  Is this possible?

 

Field to Update: Contract Number

Field Data Type: Number

 

Update with: Entitlement.Contract_Number__c which is a text field

 

I'm trying to add the equivalent of {!ApprovalRequest.Internal_URL} on my VF email template.

  • February 16, 2012
  • Like
  • 0
IF( 
NOT(ISBLANK(Contact_1__c)), 
ISBLANK(Text(Welcome_Letter_Email_Template_1__c)), 
AND( 
ISPICKVAL(Type, "Integration Oppty Net New Partner"), 
ISPICKVAL(StageName, "Closed Won")
))

My rule isn't working as intended.  I tried testing it out, by putting in a name in the contact_1__c field, and nothing in the welcome letter template field, the stagename is suspect and I'm recieving an error to select a welcome letter template.  I don't want this rule to take effect until the stagename is closed won.

 

Any help would be greatly appreciated.

Hello, im here to ask a little question about Visualforce rendering into Word Document.

 

What i want to do, is render it as Word document on "Print Layout" view and add the page numbers to the footer.

 

How can i do this?

<div style = "{!IF(Contract.Training_Start_Date__c != null,'','display:none;')}">
<tr>
<th><b><u>Date(s) of Service</u></b></th>
</tr>
<tr>
<td>Start: <apex:outputText value="{0, date, MMMM d, yyyy}">  <apex:param value="{!Contract.Training_Start_Date__c}"/></apex:outputText><br />
End: <apex:outputText value="{0, date, MMMM d, yyyy}"> <apex:param value="{!Contract.Training_End_Date__c}"/></apex:outputText></td>
</tr>
</div>

 Can someone tell me why the Start and End dates will not display in my page when they are not null?

AND(
ISPICKVAL(Type, 'New Partner'), 
ISPICKVAL(StageName, 'Closed Won'), 
NOT(Verified__c),
RecordTypeId = '000000000'
)

 I thought I got this right, but it's not working like I thought.  I'm trying to create a rule if the check box is not checked.  It will work if I just have NOT(Verified__c) and nothing else, but when I add in the record type and picklists it saves w/o requiring the checkbox to be checked