-
ChatterFeed
-
1Best Answers
-
0Likes Received
-
0Likes Given
-
40Questions
-
34Replies
Inline editing in Visualforce page
-
- moniferlo
- May 26, 2008
- Like
- 0
- Continue reading or reply
Custom Formula To Detect Child Cases
Anyone know how I can create a formula that will return True if a given case has child cases and False if not?
Thanks!
-
- Adrian-E
- January 04, 2010
- Like
- 0
- Continue reading or reply
Custom Visual Force Page Layouts
Thanks
-
- Adrian-E
- June 07, 2009
- Like
- 0
- Continue reading or reply
Type is not visible error message on Visualforce page
I am getting the following error on a custom Visualforce page:
Type is not visible: test
Vforce Page:
<apex:page controller="EditCases" tabstyle="Case"> <apex:sectionHeader title="Edit Cases" subtitle="Bug Meeting Mass Update" /> <apex:form > <apex:pageBlock mode="edit" title="Mass Update Cases"> <p><apex:outputText value="{!headerMessage}" /></p> <h3>Report Criteria: </h3> <p></p> <table style="width: 100%"> <tr> <td rowspan="3" width="50px" height="50px"><img src="https://ssl.salesforce.com/servlet/servlet.ImageServer?id=01500000000crMo&oid=00D00000000hZTB&lastMod=1235399976000"></img></td> <td>Sub Status contains <i>bug</i> </td> </tr> <tr> <td>ETA is <i>NULL</i></td> </tr> <tr> <td>Status is <i>Pending</i> or <i>Suspended</i></td> </tr> </table> <br /> <apex:pageblockSection id="Cases" columns="1" title="Bug Meeting Cases" rendered="{!canEdit}"> <apex:pageblocktable align="center" value="{!Cases}" var="Case" title="Cases" width="100%"> <apex:column headerValue="Case Number" width="10%"><apex:outputLink value="/{!Case.ID}">{!Case.CaseNumber}</apex:outputlink></apex:column> <apex:column headerValue="Account" width="15%"><apex:outputLink value="/{!Case.Account.ID}">{!Case.Account.Name}</apex:outputlink></apex:column> <apex:column headerValue="Bug ID" width="50%"><apex:inputField value="{!Case.Bug_ID__c}" /></apex:column> <apex:column headerValue="Subject" width="50%"><apex:inputField value="{!Case.Subject}"/></apex:column> <apex:column headerValue="Bug Description" width="50%"><apex:inputField value="{!Case.Bug_Description__c}" /></apex:column> <apex:column headerValue="Summary" width="50%"><apex:inputField value="{!Case.Bug_Meeting_Summary__c}" /></apex:column> <apex:column headerValue="ETA" width="50%"><apex:inputField value="{!Case.ETA_version__c}" /></apex:column> <apex:column headerValue="Assigned To" width="50%"><apex:inputField value="{!Case.Bug_Assigned__c}" /></apex:column> <apex:column headerValue="Status" width="15%"><apex:inputField value="{!Case.Status}"/></apex:column> <apex:column headerValue="Sub Status" width="15%"><apex:inputField value="{!Case.Sub_Condition__c}"/></apex:column> </apex:pageblockTable> </apex:pageblockSection> <p/> <apex:pageBlockButtons > <apex:commandButton action="{!save}" value="Save Cases" rendered="{!canEdit}" /> <apex:commandButton action="{!cancel}" value="Cancel" /> </apex:pageblockButtons> </apex:pageBlock> </apex:form> </apex:page>
Apex Class+Test:
public class EditCases { List<Case> cases; String headerMessage; Boolean canEdit = true; public EditCases() { cases = getcases();+ headerMessage = getHeaderMessage(); canEdit = getCanEdit(); } public List<Case> getCases() { if (cases == null) { cases = [ select Id, CaseNumber, Priority, Status, Subject, Case.Account.ID,Case.Account.Name,Case.Bug_ID__c,Case.Bug_Description__c,Case.Bug_Meeting_Summary__c,Case.ETA_version__c, CreatedDate,Sub_Condition__c, Bug_Assigned__c from Case where sub_condition__C like '%Bug%' and ETA_version__C = null and (Status = 'Pending' or Status = 'Suspended') order by CaseNumber]; return cases; } else { return cases; } } public String getHeaderMessage() { String message = ''; if (cases.size() == 0) { message = 'There are no cases to edit.'; canEdit = false; } else { canEdit = true; } return message; } public Boolean getCanEdit() { return canEdit; } // Action that is executed if Save button is clicked public PageReference save() { // Return to Cases tab page after editing PageReference returnPage = new PageReference('/500/o'); // Save all changes update cases; return returnPage; } // Action that is executed if Cancel button is clicked. public PageReference cancel() { // Return to Cases tab page after editing PageReference returnPage = new PageReference('/500/o'); return returnPage; } public static testMethod void tesEditCases() { // Create the necessary records to test automatic order creation // Create a case // This assumes that the pick list values used exist for // - Priority (High) // - Status (New) // - Origin (Phone) Case testCase = new Case( Priority = 'High', Subject = 'Test Subject', Status = 'Pending', LPTicket__c = 'LTK12345X', sub_condition__C = 'Bug Meeting', // ETA_version__C = '8.4', // Bug_ID__C = '1234', Origin = 'Phone'); insert testCase; //************************** // Test EditCases controller //************************** PageReference pageRef = Page.EditCases; Test.setCurrentPage(pageRef); // Create an instance of the controller EditCases editCasesController = new EditCases(); // Get the list of cases from the controller List<Case> casesToEdit = editCasesController.getCases(); // Verify that there is at least one case to edit system.assertEquals(casesToEdit.size() > 0, true); // Retrieve the header message String editCasesMessage = editCasesController.getHeaderMessage(); // Verify that the header message is blank system.assertEquals(editCasesMessage, ''); // Check the Cancel action String canceleditCasesPage = editCasesController.cancel().getUrl(); // Check the save action String editCasesPage = editCasesController.save().getUrl(); } }
Nothing has changed in my environment or in my apex class and Vforce pages. Any help or suggestions welcome.
-
- Adrian-E
- April 25, 2009
- Like
- 0
- Continue reading or reply
Calculate Rollup of Child Accounts
We have parent child account relationships. I currently calculate the RMR rollup on child accounts.
I want the parent account to also display of all RMR rollups on child accounts.
How can I achieve this?
Thanks
-
- Adrian-E
- April 23, 2009
- Like
- 0
- Continue reading or reply
Field Dependancy
-
- Adrian-E
- April 22, 2009
- Like
- 0
- Continue reading or reply
Passing Line Breaks in URL
Hi,
I know I can pass spaces in a URL using %20. I was wondering if it is possible to pass line breaks as well?
Any ideas?
-
- Adrian-E
- April 20, 2009
- Like
- 0
- Continue reading or reply
Need Help with Apex Trigger Calulcating Wait times for Departments on Cases
Hi,
I have a field called sub status which tracks the different departments who handle cases.
My trigger sums time between each status change in new custom fields on the case object (in hours). My problem is, that if a case is assigned a sub_status of Deployment and then resolve (closed) with the same sub_status, it doest count the time.
Can anyone take a quick look and see what I should change? I dont know how make sure that it sums the time between statuses when the case is closed, even if the sub_status didnt change
-
- Adrian-E
- March 11, 2009
- Like
- 0
- Continue reading or reply
Conditional visualforce Page Display
ii,
I have two Vforce pages.
I want to show page X if the case is high priority and show page Y if it is not.
How can I do this within Vforce?
-
- Adrian-E
- March 09, 2009
- Like
- 0
- Continue reading or reply
Apex Reopen Case and Copy Previous Comments
-
- Adrian-E
- February 27, 2009
- Like
- 0
- Continue reading or reply
Apex trigger to copy from Parent to Child account
-
- Adrian-E
- February 26, 2009
- Like
- 0
- Continue reading or reply
Copy Account Teams from Parent Account to Child
we have account hierarchies: parent and child accounts.
The parent account has an account team assigned. Can I reference account team members in custom fields on the child levels?
If not, is there any way with apex triggers to make sure that the parent team is copie to the child team each time an update is administered?
-
- Adrian-E
- February 26, 2009
- Like
- 0
- Continue reading or reply
Duplicate Value Alert - Prompt User to continue
I would like to customize the following trigger to PROMPT the user when a duplicate value is found and ask if he wants to continue. If he clicks yes, then it should save the value
trigger ContactDuplicateTrigger on Contact (before insert) { for (Contact c : Trigger.new){ Contact[] contacts= [select id from Contact where Email = :c.Email]; if (contacts.size() > 0) { c.LastName.addError('Contact cannot be created - Contact already exists'); } }}
-
- Adrian-E
- February 24, 2009
- Like
- 0
- Continue reading or reply
Inline Editing in Visuaforce
Hi,
I was wondering whether there was any attribute for creating inline editable fields.
I am particulalry looking for the same experience as the standard inline editing option in Salesforce = Doubleclicking on the field allows you to edit it.
Nothing found in the documentation.
-
- Adrian-E
- February 24, 2009
- Like
- 0
- Continue reading or reply
What is the syntax for SWITCH or CASE conditions?
How do I convert these conditions into SWITCH or CASE format:
if (oldCase.Sub_Condition__c == 'Support - 2nd Tier') { updatedCase.Time_With_Tier2__c += timeSinceLastStatus; } else { if (oldCase.Sub_Condition__c == 'Support - 3rd Tier') { updatedCase.Time_With_Tier3__c += timeSinceLastStatus; } else { if (oldCase.Sub_Condition__c == 'Customer - Confirmation of Fix')...
-
- Adrian-E
- February 21, 2009
- Like
- 0
- Continue reading or reply
Custom Formula to Populate Value from Picklis
I have a picklist on a parent field with dropdown options from 1 through 50.
I want to have a formula on the child account which copies the same selection from the parent.
I have tried combinations of CASE, ISPICKLIST, OR and evrey other option to no avail.
Any suggestions?
-
- Adrian-E
- February 19, 2009
- Like
- 0
- Continue reading or reply
Calculate Time spent in custom field
We have a custom field called WAITING_FOR on the case level with 4 options:
SUPPORT
DEVELOPMENT
PRODUCTION
CUSTOMER
We'd like to populate 4 additional fields on the case level indicating the time spent in each status in days.
How can we achieve this with triggers?
-
- Adrian-E
- February 18, 2009
- Like
- 0
- Continue reading or reply
Reporting Inquiries
I use account hierarchies and have PARENT accounts which have multiple CHILD accounts.
The PARENT account contains a custom field which is only displayed on the parent level. How can I pull this field into the CHILD accounts to be displayed?
Also, is there any way to include this field in any of the reports for CHILD accounts?
-
- Adrian-E
- February 03, 2009
- Like
- 0
- Continue reading or reply
Check if picklist contains certain string
Can I create a validation rule which checks if a value in a picklist object in contains a certain strong?
I have a picklist of the following
SMB_Phone
SMB_Email
ENT_Phone
ENT_Email
I dont want to reference each value individually - how can I achieve this?
-
- Adrian-E
- January 22, 2009
- Like
- 0
- Continue reading or reply
Problems with Packaging Visualforce Project
My sandbox package uses custom fields in the test scenario and my production account keeps alerting me that the fields already exist when I try import the package.
I need the custom fields in the test scenarios and I cannot afford to remove the custom fields from the Production account.
What can I do?
Which edition of Salesforce will allow me to edit apex classes in a production account?
-
- Adrian-E
- October 12, 2008
- Like
- 0
- Continue reading or reply
Custom Controller Help
I would like display all open cases where priority = "high" on one page with the "subject" field already open for editing.
Can anyone help me by showing me what the custom controller would look like and how the page would be built?
PS: This is more like a report but with the fields all open for editing. I would then make the changes to each field and hit "submit" to post all changes at once
-
- Adrian-E
- September 27, 2008
- Like
- 0
- Continue reading or reply
Unable to fetch organization details
Hi,
I am getting " Unable to fetch organization details " error. I have verified the userid, password and security key. I am using the Production/Developer Editiion with a trial account.
My environment is MyEclipse. Could someone give me some pointers to debug and resolve this??
Thank You.
- NewForce2009
- April 09, 2009
- Like
- 0
- Continue reading or reply
Need Help with Apex Trigger Calulcating Wait times for Departments on Cases
Hi,
I have a field called sub status which tracks the different departments who handle cases.
My trigger sums time between each status change in new custom fields on the case object (in hours). My problem is, that if a case is assigned a sub_status of Deployment and then resolve (closed) with the same sub_status, it doest count the time.
Can anyone take a quick look and see what I should change? I dont know how make sure that it sums the time between statuses when the case is closed, even if the sub_status didnt change
- Adrian-E
- March 11, 2009
- Like
- 0
- Continue reading or reply
Duplicate Value Alert - Prompt User to continue
I would like to customize the following trigger to PROMPT the user when a duplicate value is found and ask if he wants to continue. If he clicks yes, then it should save the value
trigger ContactDuplicateTrigger on Contact (before insert) { for (Contact c : Trigger.new){ Contact[] contacts= [select id from Contact where Email = :c.Email]; if (contacts.size() > 0) { c.LastName.addError('Contact cannot be created - Contact already exists'); } }}
- Adrian-E
- February 24, 2009
- Like
- 0
- Continue reading or reply
Inline Editing in Visuaforce
Hi,
I was wondering whether there was any attribute for creating inline editable fields.
I am particulalry looking for the same experience as the standard inline editing option in Salesforce = Doubleclicking on the field allows you to edit it.
Nothing found in the documentation.
- Adrian-E
- February 24, 2009
- Like
- 0
- Continue reading or reply
Custom Formula to Populate Value from Picklis
I have a picklist on a parent field with dropdown options from 1 through 50.
I want to have a formula on the child account which copies the same selection from the parent.
I have tried combinations of CASE, ISPICKLIST, OR and evrey other option to no avail.
Any suggestions?
- Adrian-E
- February 19, 2009
- Like
- 0
- Continue reading or reply
Adding new fields to Duplicate Lead
- DaveLP
- February 17, 2009
- Like
- 0
- Continue reading or reply
Reporting Inquiries
I use account hierarchies and have PARENT accounts which have multiple CHILD accounts.
The PARENT account contains a custom field which is only displayed on the parent level. How can I pull this field into the CHILD accounts to be displayed?
Also, is there any way to include this field in any of the reports for CHILD accounts?
- Adrian-E
- February 03, 2009
- Like
- 0
- Continue reading or reply
Tabbed Record & Inline Editing
- Buell
- November 14, 2008
- Like
- 0
- Continue reading or reply
Custom Controller Help
I would like display all open cases where priority = "high" on one page with the "subject" field already open for editing.
Can anyone help me by showing me what the custom controller would look like and how the page would be built?
PS: This is more like a report but with the fields all open for editing. I would then make the changes to each field and hit "submit" to post all changes at once
- Adrian-E
- September 27, 2008
- Like
- 0
- Continue reading or reply
Parent Account data in case
All child accounts of the parent do not contain this field.
I open cases under contacts belonging to the parent account, how can I bring the TotalFees of the parent account into a page within the case? So far I have only managed to bring in the parent account name... but that's all...
- Adrian-E
- August 26, 2008
- Like
- 0
- Continue reading or reply
Inline editing in Visualforce page
- moniferlo
- May 26, 2008
- Like
- 0
- Continue reading or reply
Existing Salesforce URL Variables
I could not find any answers on Salesforce help forums
- Adrian-E
- May 13, 2008
- Like
- 0
- Continue reading or reply
Inline Editing gets disabled after overriding New/Edit buttons
I have enabled inline editing feature in my SFDC instance which works fine for all the objects. I tried overriding New/Edit button on Opportunity which calls an S-Control and takes back to the Opportuinty Layout after processing. Once the S-Control moves back to the Opportunity, Inline Editing feature gets disabled for that opportunity and it doesnt works.
Should we pass on some hidden parameter to the opportunity page while transfering control to the opportunity which keeps that inline editing feture enabled?
Please suggest..
Thanks in advance.
Message Edited by GreatG on 12-20-2007 03:03 AM
- Middha
- December 20, 2007
- Like
- 0
- Continue reading or reply