-
ChatterFeed
-
0Best Answers
-
0Likes Received
-
0Likes Given
-
5Questions
-
5Replies
i am not able to rerender outputPanel as well pageblock via actionFunction
My code is here
<apex:component controller="Type_Ahead_Component_Controller" >
<apex:stylesheet value="{!URLFOR($Resource.AutoComplete,'/jquery-ui.css')}"/>
<apex:includeScript value="{!URLFOR($Resource.AutoComplete,'/jquery-1.12.4.js')}"/>
<apex:includeScript value="{!URLFOR($Resource.AutoComplete,'/jquery-ui.js')}"/>
<apex:attribute name="sObj" type="String" description="sobject name"></apex:attribute>
<apex:attribute name="fields" type="String" description="SObject field name"></apex:attribute>
<apex:attribute name="index" type="string" description="SObject name as index" assignTo="{!objectName}" />
<apex:pageBlock >
<apex:pageBlockSection collapsible="false" title="{!objectName}">
<input id="{!index}objectSearch" value="{!searchTerm}"/>
</apex:pageBlockSection>
</apex:pageBlock>
<apex:outputPanel id="outerPanel">
<apex:outputPanel id="innerPanel">
<apex:pageBlock title="{!objectName} detail">
<apex:pageBlockTable value="{!sobjectWrapper}" var="item" id="recordID">
<apex:outputField value="{item.name}" />
</apex:pageBlockTable>
<apex:pageBlockButtons location="Top">
<apex:commandButton value="Save" />
</apex:pageBlockButtons>
</apex:pageBlock>
</apex:outputPanel>
</apex:outputPanel>
<!--apex:pageBlock title="{!objectName} detail" rendered="true" id="recordID">
<apex:pageBlockTable value="{!sobjectWrapper}" var="item">
<apex:outputField value="{item.name}" />
</apex:pageBlockTable>
<apex:pageBlockButtons location="Top">
<apex:commandButton value="Save" />
</apex:pageBlockButtons>
</apex:pageBlock-->
<apex:actionFunction name="showObjectInfo" action="{!showObjectDetail}" reRender="outerPanel,innerPanel,recordID">
<apex:param assignTo="{!selectedObjectID}" name="selectedObjectID" value=""/>
<apex:param assignTo="{!tempFields}" name="field" value="" />
<apex:param assignTo="{!objectName}" name="objectName" value="" />
</apex:actionFunction>
</apex:component>
Please provide me any solution
Thank you in advance
<apex:component controller="Type_Ahead_Component_Controller" >
<apex:stylesheet value="{!URLFOR($Resource.AutoComplete,'/jquery-ui.css')}"/>
<apex:includeScript value="{!URLFOR($Resource.AutoComplete,'/jquery-1.12.4.js')}"/>
<apex:includeScript value="{!URLFOR($Resource.AutoComplete,'/jquery-ui.js')}"/>
<apex:attribute name="sObj" type="String" description="sobject name"></apex:attribute>
<apex:attribute name="fields" type="String" description="SObject field name"></apex:attribute>
<apex:attribute name="index" type="string" description="SObject name as index" assignTo="{!objectName}" />
<apex:pageBlock >
<apex:pageBlockSection collapsible="false" title="{!objectName}">
<input id="{!index}objectSearch" value="{!searchTerm}"/>
</apex:pageBlockSection>
</apex:pageBlock>
<apex:outputPanel id="outerPanel">
<apex:outputPanel id="innerPanel">
<apex:pageBlock title="{!objectName} detail">
<apex:pageBlockTable value="{!sobjectWrapper}" var="item" id="recordID">
<apex:outputField value="{item.name}" />
</apex:pageBlockTable>
<apex:pageBlockButtons location="Top">
<apex:commandButton value="Save" />
</apex:pageBlockButtons>
</apex:pageBlock>
</apex:outputPanel>
</apex:outputPanel>
<!--apex:pageBlock title="{!objectName} detail" rendered="true" id="recordID">
<apex:pageBlockTable value="{!sobjectWrapper}" var="item">
<apex:outputField value="{item.name}" />
</apex:pageBlockTable>
<apex:pageBlockButtons location="Top">
<apex:commandButton value="Save" />
</apex:pageBlockButtons>
</apex:pageBlock-->
<apex:actionFunction name="showObjectInfo" action="{!showObjectDetail}" reRender="outerPanel,innerPanel,recordID">
<apex:param assignTo="{!selectedObjectID}" name="selectedObjectID" value=""/>
<apex:param assignTo="{!tempFields}" name="field" value="" />
<apex:param assignTo="{!objectName}" name="objectName" value="" />
</apex:actionFunction>
</apex:component>
Please provide me any solution
Thank you in advance
- YV
- August 12, 2021
- Like
- 0
- Continue reading or reply
i am not able test for loop scenario in this pagination controller class. Can anyone will help me please i am newbie in salesforce developer.
this is my controller code
public void returnSelectedFields() { // show selected fields from availabel list to selected list
System.debug('selcted size in controller :'+selected.size());
if(selectedFieldOptions == null){
selectedFieldOptions = new list<SelectOption>();// selected fields in this list
}
Set<String> selectedFieldSet = new Set<String>(selected); // getting selected fields into string set to remove
for(String str : selectedFieldSet) {
for(integer j = 0; j<availableFieldOptions.size(); j++) {
if(str == availableFieldOptions[j].getvalue()) {
selectedFieldOptions.add(new selectOption(availableFieldOptions[j].getvalue(), availableFieldOptions[j].getLabel()));
availableFieldOptions.remove(j);
}
}
}
if(availableFieldOptions.size()==0) {
addHide = true;
}
if(selectedFieldOptions.size() > 0) {
removeHide = false;
processHide = false;
}
selectedFieldOptions.sort();
availableFieldOptions.sort();
}
public void removeSelectedFields() { // for remove selected fields from second picklist and add them into to second pikclist
Set<String> removeFieldSet = new Set<String>(remove); // getting selected fields into string set to remove
for(String str : removeFieldSet) { // removing fields from selected fields
for(integer j = 0; j<selectedFieldOptions.size(); j++) {
if(str == selectedFieldOptions[j].getvalue()){
availableFieldOptions.add(new SelectOption(selectedFieldOptions[j].getvalue(), selectedFieldOptions[j].getLabel()));
selectedFieldOptions.remove(j);
}
}
}
if(selectedFieldOptions.size() != 0) {
removeHide = false;
processHide = false;
}
else {
removeHide = true;
processHide = true;
}
if(availableFieldOptions.size() > 0) {
addHide = false;
}
availableFieldOptions.sort();
System.debug('availableFieldOptions size in remove methods : '+availableFieldOptions.size());
System.debug('selectedFieldOptions size remove methods : '+selectedFieldOptions.size());
}
Thank you
YV
public void returnSelectedFields() { // show selected fields from availabel list to selected list
System.debug('selcted size in controller :'+selected.size());
if(selectedFieldOptions == null){
selectedFieldOptions = new list<SelectOption>();// selected fields in this list
}
Set<String> selectedFieldSet = new Set<String>(selected); // getting selected fields into string set to remove
for(String str : selectedFieldSet) {
for(integer j = 0; j<availableFieldOptions.size(); j++) {
if(str == availableFieldOptions[j].getvalue()) {
selectedFieldOptions.add(new selectOption(availableFieldOptions[j].getvalue(), availableFieldOptions[j].getLabel()));
availableFieldOptions.remove(j);
}
}
}
if(availableFieldOptions.size()==0) {
addHide = true;
}
if(selectedFieldOptions.size() > 0) {
removeHide = false;
processHide = false;
}
selectedFieldOptions.sort();
availableFieldOptions.sort();
}
public void removeSelectedFields() { // for remove selected fields from second picklist and add them into to second pikclist
Set<String> removeFieldSet = new Set<String>(remove); // getting selected fields into string set to remove
for(String str : removeFieldSet) { // removing fields from selected fields
for(integer j = 0; j<selectedFieldOptions.size(); j++) {
if(str == selectedFieldOptions[j].getvalue()){
availableFieldOptions.add(new SelectOption(selectedFieldOptions[j].getvalue(), selectedFieldOptions[j].getLabel()));
selectedFieldOptions.remove(j);
}
}
}
if(selectedFieldOptions.size() != 0) {
removeHide = false;
processHide = false;
}
else {
removeHide = true;
processHide = true;
}
if(availableFieldOptions.size() > 0) {
addHide = false;
}
availableFieldOptions.sort();
System.debug('availableFieldOptions size in remove methods : '+availableFieldOptions.size());
System.debug('selectedFieldOptions size remove methods : '+selectedFieldOptions.size());
}
Thank you
YV
- YV
- July 17, 2021
- Like
- 0
- Continue reading or reply
i am not able to update check box value on apex controller in following code
visualforce component code
I am stuck here
in this code i am not able to update child check box state in apex controller
Please help me
Thank you
I am stuck here
in this code i am not able to update child check box state in apex controller
Please help me
Thank you
- YV
- July 14, 2021
- Like
- 0
- Continue reading or reply
how to pagination more than 15k records without using standardSetController, offset and limit next,previous, first and last
Hi folks,
I am working on a assignment (using visualforce component) where i need to work on more than 15000 thousands records and need full pagination without using standardSetcontroller, offset and limits,
Please help me,
Thanks
yagya
I am working on a assignment (using visualforce component) where i need to work on more than 15000 thousands records and need full pagination without using standardSetcontroller, offset and limits,
Please help me,
Thanks
yagya
- YV
- July 04, 2021
- Like
- 0
- Continue reading or reply
Why i am able to save records through visualforce page even there are some required fields and some have active validation rule ?
- I created a Visualforce page and added standard controller position__c object. There are some required fields like name,min_pay and max_pay. Min and max pay both have validation rule to check the minimum value criteria. Without entering value in input text on visualforce page on those fields why i am able to save records.
<apex:page standardController="Position__c">
<apex:form>
<apex:pageMessages/>
<apex:pageBlock title="Position">
<apex:pageBlockButtons>
<apex:commandButton action="{!save}" value="save"/>
<apex:commandButton action="{Cancel}" value="Cancel"/>
</apex:pageBlockButtons>
<apex:pageBlockSection title="Create records">
<apex:inputText value="{!position__c.name}" />
<apex:inputText value="{!position__c.min_pay__c}" />
<apex:inputText value="{!position__c.max_pay__c}" />
<apex:inputText value="{!position__c.status__c}" />
<apex:inputText value="{!position__c.job_description__c}" />
</apex:pageBlockSection>
</apex:pageBlock>
</apex:form>
</apex:page>
if i edit this page and save without do anything it will also accept values and will take $0.0 value in min and max pay fields
Please help me
Thank you in advance
- YV
- June 11, 2021
- Like
- 0
- Continue reading or reply
i am not able to rerender outputPanel as well pageblock via actionFunction
My code is here
<apex:component controller="Type_Ahead_Component_Controller" >
<apex:stylesheet value="{!URLFOR($Resource.AutoComplete,'/jquery-ui.css')}"/>
<apex:includeScript value="{!URLFOR($Resource.AutoComplete,'/jquery-1.12.4.js')}"/>
<apex:includeScript value="{!URLFOR($Resource.AutoComplete,'/jquery-ui.js')}"/>
<apex:attribute name="sObj" type="String" description="sobject name"></apex:attribute>
<apex:attribute name="fields" type="String" description="SObject field name"></apex:attribute>
<apex:attribute name="index" type="string" description="SObject name as index" assignTo="{!objectName}" />
<apex:pageBlock >
<apex:pageBlockSection collapsible="false" title="{!objectName}">
<input id="{!index}objectSearch" value="{!searchTerm}"/>
</apex:pageBlockSection>
</apex:pageBlock>
<apex:outputPanel id="outerPanel">
<apex:outputPanel id="innerPanel">
<apex:pageBlock title="{!objectName} detail">
<apex:pageBlockTable value="{!sobjectWrapper}" var="item" id="recordID">
<apex:outputField value="{item.name}" />
</apex:pageBlockTable>
<apex:pageBlockButtons location="Top">
<apex:commandButton value="Save" />
</apex:pageBlockButtons>
</apex:pageBlock>
</apex:outputPanel>
</apex:outputPanel>
<!--apex:pageBlock title="{!objectName} detail" rendered="true" id="recordID">
<apex:pageBlockTable value="{!sobjectWrapper}" var="item">
<apex:outputField value="{item.name}" />
</apex:pageBlockTable>
<apex:pageBlockButtons location="Top">
<apex:commandButton value="Save" />
</apex:pageBlockButtons>
</apex:pageBlock-->
<apex:actionFunction name="showObjectInfo" action="{!showObjectDetail}" reRender="outerPanel,innerPanel,recordID">
<apex:param assignTo="{!selectedObjectID}" name="selectedObjectID" value=""/>
<apex:param assignTo="{!tempFields}" name="field" value="" />
<apex:param assignTo="{!objectName}" name="objectName" value="" />
</apex:actionFunction>
</apex:component>
Please provide me any solution
Thank you in advance
<apex:component controller="Type_Ahead_Component_Controller" >
<apex:stylesheet value="{!URLFOR($Resource.AutoComplete,'/jquery-ui.css')}"/>
<apex:includeScript value="{!URLFOR($Resource.AutoComplete,'/jquery-1.12.4.js')}"/>
<apex:includeScript value="{!URLFOR($Resource.AutoComplete,'/jquery-ui.js')}"/>
<apex:attribute name="sObj" type="String" description="sobject name"></apex:attribute>
<apex:attribute name="fields" type="String" description="SObject field name"></apex:attribute>
<apex:attribute name="index" type="string" description="SObject name as index" assignTo="{!objectName}" />
<apex:pageBlock >
<apex:pageBlockSection collapsible="false" title="{!objectName}">
<input id="{!index}objectSearch" value="{!searchTerm}"/>
</apex:pageBlockSection>
</apex:pageBlock>
<apex:outputPanel id="outerPanel">
<apex:outputPanel id="innerPanel">
<apex:pageBlock title="{!objectName} detail">
<apex:pageBlockTable value="{!sobjectWrapper}" var="item" id="recordID">
<apex:outputField value="{item.name}" />
</apex:pageBlockTable>
<apex:pageBlockButtons location="Top">
<apex:commandButton value="Save" />
</apex:pageBlockButtons>
</apex:pageBlock>
</apex:outputPanel>
</apex:outputPanel>
<!--apex:pageBlock title="{!objectName} detail" rendered="true" id="recordID">
<apex:pageBlockTable value="{!sobjectWrapper}" var="item">
<apex:outputField value="{item.name}" />
</apex:pageBlockTable>
<apex:pageBlockButtons location="Top">
<apex:commandButton value="Save" />
</apex:pageBlockButtons>
</apex:pageBlock-->
<apex:actionFunction name="showObjectInfo" action="{!showObjectDetail}" reRender="outerPanel,innerPanel,recordID">
<apex:param assignTo="{!selectedObjectID}" name="selectedObjectID" value=""/>
<apex:param assignTo="{!tempFields}" name="field" value="" />
<apex:param assignTo="{!objectName}" name="objectName" value="" />
</apex:actionFunction>
</apex:component>
Please provide me any solution
Thank you in advance
- YV
- August 12, 2021
- Like
- 0
- Continue reading or reply
how to pagination more than 15k records without using standardSetController, offset and limit next,previous, first and last
Hi folks,
I am working on a assignment (using visualforce component) where i need to work on more than 15000 thousands records and need full pagination without using standardSetcontroller, offset and limits,
Please help me,
Thanks
yagya
I am working on a assignment (using visualforce component) where i need to work on more than 15000 thousands records and need full pagination without using standardSetcontroller, offset and limits,
Please help me,
Thanks
yagya
- YV
- July 04, 2021
- Like
- 0
- Continue reading or reply
Why i am able to save records through visualforce page even there are some required fields and some have active validation rule ?
- I created a Visualforce page and added standard controller position__c object. There are some required fields like name,min_pay and max_pay. Min and max pay both have validation rule to check the minimum value criteria. Without entering value in input text on visualforce page on those fields why i am able to save records.
<apex:page standardController="Position__c">
<apex:form>
<apex:pageMessages/>
<apex:pageBlock title="Position">
<apex:pageBlockButtons>
<apex:commandButton action="{!save}" value="save"/>
<apex:commandButton action="{Cancel}" value="Cancel"/>
</apex:pageBlockButtons>
<apex:pageBlockSection title="Create records">
<apex:inputText value="{!position__c.name}" />
<apex:inputText value="{!position__c.min_pay__c}" />
<apex:inputText value="{!position__c.max_pay__c}" />
<apex:inputText value="{!position__c.status__c}" />
<apex:inputText value="{!position__c.job_description__c}" />
</apex:pageBlockSection>
</apex:pageBlock>
</apex:form>
</apex:page>
if i edit this page and save without do anything it will also accept values and will take $0.0 value in min and max pay fields
Please help me
Thank you in advance
- YV
- June 11, 2021
- Like
- 0
- Continue reading or reply
- Prema -
- September 26, 2018
- Like
- 0
- Continue reading or reply