• DJ Rock your own style
  • NEWBIE
  • 25 Points
  • Member since 2012

  • Chatter
    Feed
  • 1
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 19
    Questions
  • 13
    Replies

Hi All,

 

We have implemented customer portal in our project. Portal Users have a login page, a defauld landing page (vf), a form (vf) which whn filled and clicked on submit creates a new record in salesforce.

 

This is working perfectly fine in qa but few users in production have complained to be constantly seeing the error message while submitting the form.

 

Error :Error occured while loading a visualforce page

 

Please email us if you need to get in touch.

 

 

I havent been able to replicate this issue in QA.

 

Can anyone please advice:

1. Why it happens for only a bunch of users?

2. Is this a problem on salesforce side?

 

PS: all profile access to the page, class etc have been given.

 

Regards,

Dave.

Hi All,

 

I have used an apex detail page for leads with inline edit functionality. When certain conditions are met, I am flipping the page layout to a different one. I am doing this using an extension class. I do not want to use workflows.

 

The behaviour is weird. The page layouts are not always changing. My condition is when a checkbox is checked, The record type should flip. The record type flips but correct fields and buttons are not properly displayed. The record type changes but the assigned page layout doesnt. However, when i refresh the page, correct values come up.

 

Does anyone have a solution to this or can suggest me what am i missing? Any help will be greatly appreciated.

 

Regards,

Dave

Hi, Is it possible to get a javascript prompt or something like that on click of save in standard page? I know it can be done by a vf but would like to have a customized save button or something of that sort which would prompt the user on satisfactory conditions. Thanks in advance, Dave

Dear all,

 

We have made a vf for opportunity which is called on click of a button in the opportunity related list. The problem is with performance wherein it takes much more time to load than expected.

 

We thought of the following solution:

 

In code where we are querying the opportunities to show on VFpage, we can use an external id field (indexed  field) to concatenate the fields on which we are making a filter (AND clauses)

 

Here is our query:

 

  lstOpportunity = [Select o.Id, o.Name, o.Status__c,o.Account.City_EFS_c__r.Name,o.Account.Pin_Code_EFS_c__r.Name,o.opportunity_status__c,o.Product_Name__r.name, o.Product_Name__r.category__c,
                              o.Account.Id, o.Account.Name, o.Account.LastName__c,o.Account.CIS_No_new__c,Loan_Amount__c 
                              From Opportunity  o where 
                              o.Status__c ='Active' and o.opportunity_status__c =''
                              and o.Product_Name__r.category__c =: strCategory 
                              and o.Product_Name__r.Name=:strProduct
                              and o.Account.City_EFS_c__r.Name =: strCity 
                              and o.Account.Pin_Code_EFS_c__r.Name =: strPincode 
                              and o.Id not in :lstOppWithAppsIds];

 

 

Is it possible to index a concatenated field?

 

Is the approach we are talking about achievable?

 

Please let us know if anyone has worked on it. Any help will be appreciated.

Hi,

 

I have an apex pageblock table inside an output panel. This panel has a field called target which has to be updated to true on click of a button in the same panel. Here is the piece of the code.

 

<apex:commandLink action="{!target}"  id="prospectbutton1" status="loadingstatus" rerender="StrategicTargetingBlock">

 

Here is the field inside the same output panel(ie: strategictargetingblock)

 

<apex:outputField id="T" value="{!e.c.T__c}"/>

 

This field is not being updated on click of the commandlink. But when i refresh the entire page by f5, the update is reflected. Seems like the value is refreshed only on client UI but not from the server.

Please help out.

 

Thanks and regards,

Dave.

Hi,

 

Is it possible to export attachments for only a particular object in dataloader? I ve been trying this but no luck as yet. It is exporting all attachments available in the instance irrespective of which object record it is associated with. Tried for the following queries also but didnt help:

 

SELECT Id, Parentid from attachment where parentid like 'a0v%' (a0v is the object id I need to export from)

or

SELECT Id, Parentid from attachment where parentid like '%a0v%'

or

SELECT Id, Parentid from attachment where parentid like :'a0v%'

 

Please help me out.

 

Thanks and regards,

Dave

Hi All,

 

I have an inline vf in a record detail page. I would like to hide some attributes of the record detail (say notes and attachments) by calling a javascript from the inline. Below is the snippet:

 

<script>
    
    var previousOnload = window.onload;        
    window.parent.onload = function() {
        if (previousOnload) {
            previousOnload();
        }
document.getElementsByClassName('listRelatedObject Custom78Block')[0].style.display = 'none'
    }

</script>

 

Here i ve got the class name by inspecting the element in browser. But when i try to run this, i get an error in the error console as: Permission denied to access property onload......

 

Is there any workaround for this?

 

Thanks in advance,

 

Dave.

Hi All,

 

I have a requirement of removing the notes and attachment related list from the record detail page of an object but making the notes and attachment link on the top of the page to be visible where the user can hover the mouse to see the details.

 

It is not a vf page but a standard one. Please let me know how to proceed with this.

 

Thanks in advance,

 

Dave

Hi All,

 

I have developed an inline vf for notes and attachment which displayes all the notes and attachments related to the master object record and the related child objects too. It is working fine but i need to display in cloud console view. I have never worked on the same before. Please help. Here is my code:

 

 

<apex:page standardController="Deal__c" extensions="Dealext" showHeader="false">

<script>
function refresh() {
confirm('Do you want to Delete?');
window.top.location='/{!dl.id}';
}
</script>

<apex:form >

<apex:pageblock mode="edit">

<apex:pageblockbuttons location="top">
<apex:commandbutton value="New Note" onclick ="window.top.location='/002/e?parent_id='+'{!theid}'+'&retURL=/'+'{!dl.id}'"/>
<apex:commandbutton value="Attach File" onclick="window.top.location='/p/attach/NoteAttach?pid='+'{!dl.id}'+'&retURL=/'+'{!dl.id}'"/>
<apex:commandbutton value="View All" id="viewall" rendered="{!nextpage}" onclick="commentOpenSubtab(); return false"/>
</apex:pageblockbuttons>
<apex:pageBlockTable value="{!notesandattchlist}" var="a" rows="5" >
<apex:column >
<apex:facet name="header">Action</apex:facet>
<apex:outputLink onclick= "window.top.location= '/{!IF(a.type,a.n.id,a.a.id)}/e?retURL=/{!dl.id}'" style=" text-decoration:none; color:#236FBD">Edit&nbsp;</apex:outputLink>
<apex:outputLink onclick= "window.top.location= '/servlet/servlet.FileDownload?file={!a.a.id}'" rendered="{!NOT(a.type)}" style="text-decoration:none; color:#236FBD" >| View&nbsp;</apex:outputLink>
<apex:commandlink onclick="return refresh();" style="text-decoration:none; color:#236FBD" action="{!del}" value="| Del">
<apex:param name="did" value="{!IF(a.type,a.n.id,a.a.id)}"/>
</apex:commandlink>

</apex:column>
<apex:column headervalue="Title" >
<a href="#">
<apex:outputLink onclick="window.top.location='/{!a.n.id}'" rendered="{!a.type}"> {!a.title} </apex:outputLink></a>
<a href="#">
<apex:outputLink onclick="window.top.location='/{!a.a.id}'" rendered="{!NOT(a.type)}">{!a.title} </apex:outputLink></a>
</apex:column>


<apex:column >
<apex:facet name="header">Related to</apex:facet>
<apex:outputfield value="{!a.n.parentid}" rendered="{!a.type}"></apex:outputfield>
<apex:outputlink value="/{!a.a.parentid}" rendered="{!NOT(a.type)}" > {!a.parentname}</apex:outputlink>
</apex:column>

<apex:column >
<apex:facet name="header">Last Modified</apex:facet>
<apex:outputfield value="{!a.n.LastModifiedDate}" rendered="{!a.type}" />
<apex:outputfield value="{!a.a.LastModifiedDate}" rendered="{!NOT(a.type)}" />
</apex:column>

<apex:column >
<apex:facet name="header">Created by</apex:facet>
<apex:outputfield value="{!a.n.CreatedById}" rendered="{!a.type}" />
<apex:outputfield value="{!a.a.CreatedById}" rendered="{!NOT(a.type)}" />
</apex:column>

</apex:pageBlockTable>

</apex:pageblock>
<apex:commandLink value="Show more>>" rendered = "{!nextpage}" onclick="window.top.location='/apex/Deal_view_all?id='+'{!dl.id}'+'&retURL=/'+'{!dl.id}'"/>
</apex:form>


</apex:page>

Hi All,

 

I have a requirement of having apex:commandlink on a hover window.

 

I have an outputlink on my main vf page. Requirement is,when i hover my mouse on that link, a window should pop up(Like salesforce standard functionality) with few commandlinks on that hover window which i can define. Can someone help me out on this?

 

Thanks in advance,

 

Dave.

Hi Guys,

 

A small requirement has come up here. I need to have a link in my vf page saying  "Email this page". Onclick, it should open microsoft outlook and that particular page will be as an attachment. FYI, the page would contain an image file. Right now am using the following code which opens outlook but i have no idea how to attach the file.

 

<A href="mailto:?SUBJECT='(Re: Profile report)''"> Email this page </A>

 

Thanks and regards,

 

Dave

Hi,

 

I ve created a vf page with pagination. To prevent the view state error, i ve included the keyword Transient in the standard set controller. Page loads fine but the following error is thrown on click of the links Next and last (for next page and last page):

 

Attempt to de-reference a null object.

 

Any suggestions??

 

 

Thanks n advance,

 

Dave.

Hi All, I have created a list of all contacts in a vf page and an edit and save button beside each name in the list, Can someone please help me out with the class (WITHOUT STANDARD CONTROLLER) for edit and save, such that once i click EDIT, only that particular contact in the list should be editable, and once i click SAVE, only that contact should be updated. Thanks, Dave

Hi All,

 

I have creted a visual force page listing all the contact records. I have enabled inline edit and defined a save button.

In the class, i have queried for the contact list.  The problem is, when i am updating the list, not only the specific contact but the entire contact list is updated. Hence the last modified by field of all the contact records changes.

 

Can anyone please help?

 

Thanks,

Dave.

Hi all,

 

I have created a custom mobile link in a formula field in contact object. This link should redirect to a visual force page when clicked. It is working fine with blackberry but doesnt redirect to the visualforce page in iphone everytime. The link is used in the formula field as shown below:

 

"visualforce:///apex/Contactpage?id=" &Id

 

Please help me out.

 

Thanks,

Dave.

Hi all,

 

I have created a custom mobile link in a formula field in contact object. This link should redirect to a visual force page when clicked. It is working fine with blackberry but doesnt redirect to the visualforce page in iphone everytime. The link is used in the formula field as shown below:

 

"visualforce:///apex/Contactpage?id=" &Id

 

Please help me out.

 

Thanks,

Dave.

Hi,

 

I have created a custom mobile link in a formula field and added it in a section of contact detail page. The code is mentioned as follows:

 

"visualforce:///apex/contact1?id=" & Id

 

The link is sometimes visible in I phone and sometimes not. Cant understand the problem. Please help out.

 

Thanks,

 

Dave.

Hi All,

 

Can anyone please suggest how to display inline visual force pages in  Salesforce Mobile? I have created an inline page but it is not visible in i phone using salesforce mobile app.

 

Thanks,

 

Dave.

Hi All,

 

I am trying to achieve inline editing feature for a requirement.

 

I have a sample code as below :

 

<apex:page standardController="Contact">  
 <apex:form >  
 <apex:pageBlock mode="inlineEdit">  
     <apex:pageBlockButtons >  
     <apex:commandButton action="{!edit}" id="editButton" value="Edit"/>  
     <apex:commandButton action="{!save}" id="saveButton" value="Save"/>  
     <apex:commandButton onclick="resetInlineEdit()" id="cancelButton" value="Cancel"/>  
     </apex:pageBlockButtons>  
 <apex:pageBlockSection >  
     <apex:outputField value="{!contact.lastname}">  
         <apex:inlineEditSupport showOnEdit="saveButton, cancelButton"  
             hideOnEdit="editButton" event="ondblclick"  
             changedStyleClass="myBoldClass" resetFunction="resetInlineEdit"/>  
     </apex:outputField>  
     <apex:outputField value="{!contact.accountId}"/>  
     <apex:outputField value="{!contact.phone}"/>  
 </apex:pageBlockSection>  
 </apex:pageBlock>  
 </apex:form>  
 </apex:page>

 

The only thing that i have a problem is that in order to change a contact i have to append the url everytime with a contact id.

 

That works only in case of one record.


I have a visual force page, which displays a lot of contact records in a pageblocksection. How would i pass the id for the record i am editing and saving to this, as i would have many records.

 

I do not want to implement "REPEAT TAG" in my code.

 

Could you please help me out with this requirement

 

Thanks,

Dave.

Hi, Is it possible to get a javascript prompt or something like that on click of save in standard page? I know it can be done by a vf but would like to have a customized save button or something of that sort which would prompt the user on satisfactory conditions. Thanks in advance, Dave

Dear all,

 

We have made a vf for opportunity which is called on click of a button in the opportunity related list. The problem is with performance wherein it takes much more time to load than expected.

 

We thought of the following solution:

 

In code where we are querying the opportunities to show on VFpage, we can use an external id field (indexed  field) to concatenate the fields on which we are making a filter (AND clauses)

 

Here is our query:

 

  lstOpportunity = [Select o.Id, o.Name, o.Status__c,o.Account.City_EFS_c__r.Name,o.Account.Pin_Code_EFS_c__r.Name,o.opportunity_status__c,o.Product_Name__r.name, o.Product_Name__r.category__c,
                              o.Account.Id, o.Account.Name, o.Account.LastName__c,o.Account.CIS_No_new__c,Loan_Amount__c 
                              From Opportunity  o where 
                              o.Status__c ='Active' and o.opportunity_status__c =''
                              and o.Product_Name__r.category__c =: strCategory 
                              and o.Product_Name__r.Name=:strProduct
                              and o.Account.City_EFS_c__r.Name =: strCity 
                              and o.Account.Pin_Code_EFS_c__r.Name =: strPincode 
                              and o.Id not in :lstOppWithAppsIds];

 

 

Is it possible to index a concatenated field?

 

Is the approach we are talking about achievable?

 

Please let us know if anyone has worked on it. Any help will be appreciated.

Hi ,

I have one javascript button , Go with the any record and when we click on button one popup window came 

i.e VF page window.. 

Add one field and click on save button on that widow it should be save and close...

 

Javascript button code is this,

{!REQUIRESCRIPT("/soap/ajax/8.0/connection.js")}
{!REQUIRESCRIPT("/soap/ajax/15.0/apex.js")}

 

var url="/apex/commentspage?&id= {!Contact.Id}";

newWin=window.open(url, 'Popup','height=500,width=600,left=150,top=150,resizable=yes,scrollbars=no,toolbar=no,status=no');

if (newWin.focus())
{
newWin.focus();

}

 

 

After creation of button.

Go with contact record, there is one button available right,

Then click on that button one VF page popup window came.

The VF page is.. 

<apex:page controller="commentspage" showHeader="false" sidebar="false" showChat="false" standardStylesheets="false" >

<script type="text/javascript">
function closeWin(){
self.close();
}
</script>

<apex:form > <br/><br/>
<div align="center">
<apex:inputTextarea value="{!CommentText}"/><br/><br/>
<apex:commandButton oncomplete="closeWin" action="{!save}" value="Save" id="theButton"/>
</div>
</apex:form>
</apex:page>

 

 

The Action performed on controller...

Please solve my problm...

Hi,

 

I have an apex pageblock table inside an output panel. This panel has a field called target which has to be updated to true on click of a button in the same panel. Here is the piece of the code.

 

<apex:commandLink action="{!target}"  id="prospectbutton1" status="loadingstatus" rerender="StrategicTargetingBlock">

 

Here is the field inside the same output panel(ie: strategictargetingblock)

 

<apex:outputField id="T" value="{!e.c.T__c}"/>

 

This field is not being updated on click of the commandlink. But when i refresh the entire page by f5, the update is reflected. Seems like the value is refreshed only on client UI but not from the server.

Please help out.

 

Thanks and regards,

Dave.

Hi All,

 

I have an inline vf in a record detail page. I would like to hide some attributes of the record detail (say notes and attachments) by calling a javascript from the inline. Below is the snippet:

 

<script>
    
    var previousOnload = window.onload;        
    window.parent.onload = function() {
        if (previousOnload) {
            previousOnload();
        }
document.getElementsByClassName('listRelatedObject Custom78Block')[0].style.display = 'none'
    }

</script>

 

Here i ve got the class name by inspecting the element in browser. But when i try to run this, i get an error in the error console as: Permission denied to access property onload......

 

Is there any workaround for this?

 

Thanks in advance,

 

Dave.

Hi All,

 

I have developed an inline vf for notes and attachment which displayes all the notes and attachments related to the master object record and the related child objects too. It is working fine but i need to display in cloud console view. I have never worked on the same before. Please help. Here is my code:

 

 

<apex:page standardController="Deal__c" extensions="Dealext" showHeader="false">

<script>
function refresh() {
confirm('Do you want to Delete?');
window.top.location='/{!dl.id}';
}
</script>

<apex:form >

<apex:pageblock mode="edit">

<apex:pageblockbuttons location="top">
<apex:commandbutton value="New Note" onclick ="window.top.location='/002/e?parent_id='+'{!theid}'+'&retURL=/'+'{!dl.id}'"/>
<apex:commandbutton value="Attach File" onclick="window.top.location='/p/attach/NoteAttach?pid='+'{!dl.id}'+'&retURL=/'+'{!dl.id}'"/>
<apex:commandbutton value="View All" id="viewall" rendered="{!nextpage}" onclick="commentOpenSubtab(); return false"/>
</apex:pageblockbuttons>
<apex:pageBlockTable value="{!notesandattchlist}" var="a" rows="5" >
<apex:column >
<apex:facet name="header">Action</apex:facet>
<apex:outputLink onclick= "window.top.location= '/{!IF(a.type,a.n.id,a.a.id)}/e?retURL=/{!dl.id}'" style=" text-decoration:none; color:#236FBD">Edit&nbsp;</apex:outputLink>
<apex:outputLink onclick= "window.top.location= '/servlet/servlet.FileDownload?file={!a.a.id}'" rendered="{!NOT(a.type)}" style="text-decoration:none; color:#236FBD" >| View&nbsp;</apex:outputLink>
<apex:commandlink onclick="return refresh();" style="text-decoration:none; color:#236FBD" action="{!del}" value="| Del">
<apex:param name="did" value="{!IF(a.type,a.n.id,a.a.id)}"/>
</apex:commandlink>

</apex:column>
<apex:column headervalue="Title" >
<a href="#">
<apex:outputLink onclick="window.top.location='/{!a.n.id}'" rendered="{!a.type}"> {!a.title} </apex:outputLink></a>
<a href="#">
<apex:outputLink onclick="window.top.location='/{!a.a.id}'" rendered="{!NOT(a.type)}">{!a.title} </apex:outputLink></a>
</apex:column>


<apex:column >
<apex:facet name="header">Related to</apex:facet>
<apex:outputfield value="{!a.n.parentid}" rendered="{!a.type}"></apex:outputfield>
<apex:outputlink value="/{!a.a.parentid}" rendered="{!NOT(a.type)}" > {!a.parentname}</apex:outputlink>
</apex:column>

<apex:column >
<apex:facet name="header">Last Modified</apex:facet>
<apex:outputfield value="{!a.n.LastModifiedDate}" rendered="{!a.type}" />
<apex:outputfield value="{!a.a.LastModifiedDate}" rendered="{!NOT(a.type)}" />
</apex:column>

<apex:column >
<apex:facet name="header">Created by</apex:facet>
<apex:outputfield value="{!a.n.CreatedById}" rendered="{!a.type}" />
<apex:outputfield value="{!a.a.CreatedById}" rendered="{!NOT(a.type)}" />
</apex:column>

</apex:pageBlockTable>

</apex:pageblock>
<apex:commandLink value="Show more>>" rendered = "{!nextpage}" onclick="window.top.location='/apex/Deal_view_all?id='+'{!dl.id}'+'&retURL=/'+'{!dl.id}'"/>
</apex:form>


</apex:page>

Hi All,

 

I have a requirement of having apex:commandlink on a hover window.

 

I have an outputlink on my main vf page. Requirement is,when i hover my mouse on that link, a window should pop up(Like salesforce standard functionality) with few commandlinks on that hover window which i can define. Can someone help me out on this?

 

Thanks in advance,

 

Dave.

I'm using a formula field on the Accounts with a HYPERLINK function with some merged fields and it works fine on a desktop but when I use the mobile app it shows the whole field of characters with no link.  Is there a way to link and merge an account to an external website within the mobile app?

Hello.

 

I'm having trouble with a very simple VF page using the standard Contact controller. The code is below:

 

 

<apex:page standardController="Contact">
	<apex:form >
		<apex:detail subject="{!contact}" inlineEdit="true"/>
	</apex:form>
</apex:page>

When I inline edit a field and click the Save button, the buttons switch to "Saving..." and then the page just sits. It never refreshes. My complete VF page does contain additional code, but even when simplifying it to the simple code above, it still does not work. Inline editing works on the standard Contact page, which leads me to believe that it's not a trigger issue.

 

The identical code for the Account object, as seen below, works fine, leading me to believe it's not a browser issue (I've tested in Chrome, IE and Firefox):

 

<apex:page standardController="Account">
	<apex:form >
		<apex:detail subject="{!account}" inlineEdit="true"/>
	</apex:form>
</apex:page>

 

 

This appears to be bug, unless there's another explanation. Please advise. Thank you.

 

-Greg

 

 

Hi,

Is there a way to disable the Edit buttoni n the Enhanced list view? Thank you much.

 

Paul

 

  • August 13, 2009
  • Like
  • 0