function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
sunny@99-chgsunny@99-chg 

page block buttons are dissappearing...

Hai,

 

  When i click on Pageblock button,After action status and action completed.The page block buttons are dissappearing.why it is like that,can anyone suggest me for not to dissappear the buttons..

Best Answer chosen by Admin (Salesforce Developers) 
sunny@99-chgsunny@99-chg

Hai Vishal I only rectified my Problem,

 

I used reRender to Form in Submit button.Thats why that problem occured.

now i changed reRender to Pagemessages.its working fine.

 

<apex:pagemessages  id="stat"></apex:pagemessages>

 

<apex:commandButton value="Submit" status="wait" reRender="stat" action="{!SaveToAccount}" image="{!URLFOR($Resource.Buttons,'Button/button94839828.png')}" style="margin-left: 151px;" /> 

All Answers

vishal@forcevishal@force

Are you using "rendered" attribute in the pageblockbuttons?

sunny@99-chgsunny@99-chg

No I didnt used

SamuelDeRyckeSamuelDeRycke

Do they dissapear from the source, or do they get invisible ? Are you doing a lot of css things which may caused something unforseen ? Anyway, without code I'm afraight we can only guess at to what is going wrong.

 

 

 

vishal@forcevishal@force

Hi,

 

Can you please share your code here?

sunny@99-chgsunny@99-chg

Hai Vishal,

 

Sorry for the late,i was busy in other work .here is my page

 

<apex:page controller="Esnallot" sidebar="false">
<head>
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />
</head>
<style>
div#wrapper {
margin: 0 auto;
width:1095px;
}
div#WrapperPhoneImage {
margin: 0 auto;
width:1000px;
}
.main_box_text_bg{width:260px; height:30px; float:left; background:url(../images/mbl_top_text_bg.jpg) no-repeat left top; font-family:Arial, Helvetica, sans-serif; font-size:14px; font-weight:bold; color:#004f96; text-align:center; padding:15px 0px 0px 0px;}
.main_box_dollortext_bg{width:331px; height:30px; float:left; background:#085eb1; font-family:Arial, Helvetica, sans-serif; font-size:24px; font-weight:bold; color:#fff; text-align:center; padding:4px 0px 0px 0px; margin:2px 0px 0px 1px;}
.activeButton
{
font-size: 15px;
border: 2px solid black;
border-radius: 10px;
}
.disabledButton
{
font-size: 15px;
background: none repeat scroll 0 0 lightgrey;
border: 2px solid black;
border-radius: 10px;
}
#largeBreak
{
float: left;
margin: 0px;
padding: 10px;
border: 2px solid orange;
}
#smallBreak
{
float: left;
margin: 0px;
padding: 10px;
border: 2px solid orange;
}
.custPopup
{
background-color: white;
border-width: 2px;
border-style: solid;
z-index: 9999;
left: 50%;
padding:10px;
position: absolute;
width: 300px;
margin-left: -250px;
top:100px;
}
.custPopup2
{
background-color: white;
border-width: 2px;
border-style: solid;
z-index: 9999;
left: 50%;
padding:10px;
position: absolute;
width: 700px;
margin-left: -250px;
top:100px;
}
.popupBackground
{
background-color:black;
opacity: 0.20;
filter: alpha(opacity = 20);
position: absolute;
width: 100%;
height: 100%;
top: 0;
left: 0;
z-index: 9998;
}
.content
{
height:100%;
width:905px;
margin:20px;
float:right;
overflow:auto;
background:white;
sborder: 2px solid red;
}
.content a
{
color: red;
}
.filterOptionsContainer
{
height:75px;
overflow:auto;
border: 2px solid orange;
}
.filterOptionsContainer a
{
color: black;
font-size:20px;
}
.popupContainer
{
width: 160px;
padding: 20px 0px 0px 20px;
float:left;
font-size:15px;
border: 2px solid magenta;
}
.popupDiv
{
background-color: #1797C0;
opacity:0.9
text-align:left;
border:2px solid black;
}
.phoneDetails
{
height: 100%;
padding: 10px;
overflow:auto;
sborder: 2px solid cyan;
}
.phoneBox1
{
height: 300px;
width: 160px;
margin: 5px;
float: left;
border: 1px solid darkgrey;
}
.phoneBox
{
height: 20%;
width: 160px;
margin: 5px;
float: left;
border: 1px solid darkgrey;
}

.phoneImage1
{
width:150px;
height:150px;
margin-top:5px;
margin-botton:5px;
margin-left:-412px;
margin-right:5px;
}
.phoneImage
{
width:150px;
height:150px;
margin-top:5px;
margin-botton:5px;
margin-left:5px;
margin-right:5px;
}
.phoneDescription
{
margin: 0px 5px 5px 5px;
font-size: 12px;
font-weight: bold;
text-align: center;
sborder:2px solid olive;
}
.phoneDescription1
{
margin: 0px 5px 5px -412px;
font-size: 12px;
font-weight: bold;
text-align: center;
sborder:2px solid olive;
}
#navOptions
{
height: 100%;
overflow:auto;
border: 2px solid cyan;
}
#navOptions span
{
float: left;
padding: 0 0 10px 15px;
sborder: 2px solid magenta;
}
#navOptions a
{
float: left;
font-weight: bold;
margin: 0;
padding: 0;
text-decoration: none;
color: red;
}
.activeButton
{
border: 2px solid blue;
border-radius: 10px 10px 10px 10px;
font-size: 15px;
width: 80px;
text-align: center;
color: red;
}
.disabledButton
{
background: none repeat scroll 0 0 lightgrey;
border: 2px solid grey;
border-radius: 10px 10px 10px 10px;
font-size: 15px;
color: grey !important;
width: 80px;
text-align: center;
padding: 0px !important;
cursor: default;
}
#largeBreak
{
border: 1px solid white;
float: left;
width: 164px;
}
#smallBreak
{
border: 1px solid white;
float: left;
width: 8px;
}
#phoneListing
{
max-width:2000px;
}
NonNexusPhone
{
float: Center;
}
RetailerPhone
{
margin left:0;
}
.customPopup2{
background-color: #FFFFCC;
border-radius: 18px;
-moz-border-radius:18px;
-webkit-border-radius:18px;
border-style: solid;
border-width: 2px;
left: 50%;
padding:10px;
position:fixed;
z-index: 9999;
-moz-box-shadow:0 0 20px #000;
-webkit-box-shadow: 0 0 20px #000;
width: 240px;
margin-left: -120px;
top:150px;
}
</style>

<script type="text/javascript">
var selectedItem='{!selectedItemName}';
function selectItemPhone(PhoneName,PhoneId,itemType)
{


if(selectedItem != '')
{
if(selectedItem==PhoneName)
{
alert('You have already selected this '+itemType+'.');
return false;
}
else
{
if(!confirm('Your existing selected '+itemType+' is '+selectedItem+'. Would you like to replace it with '+PhoneName+' ?'))
return false;
}
}
document.getElementById('selItemId').value=PhoneId;
document.getElementById('selItemName').value=PhoneName;

return true;
}
</script>
<body>
<input type="hidden" name="selectedItemId" id="selItemId" />
<input type="hidden" name="selectedItemName" id="selItemName" />


<apex:form id="form">

<div id="wrapper">
<apex:actionStatus id="wait">
<apex:facet name="start">
<apex:outputPanel id="processTran">
<apex:outputPanel style="position: fixed; top: 0; left: 0; width: 100%; height:100%; z-index: 1100;background-image:url('{!$Resource.o2bc__Overlay}')" layout="block">
<apex:outputText >&nbsp;</apex:outputText>
</apex:outputPanel>
<apex:outputPanel styleClass="customPopup2" layout="block" >
<c:loading2 text="Processing Request..." />
</apex:outputPanel>
</apex:outputPanel>
</apex:facet>
</apex:actionStatus>
<apex:image url="{!URLFOR($Resource.PartnerImages,'PartnerImage/PartnerPortalheader.png')}" style="width:1095px;"/>
<apex:pagemessages ></apex:pagemessages>

<apex:pageblock Title="Phone Selection" id="PgBlock">

<apex:pageblocksection Title="Account Detail" collapsible="false">

<table style="width:100%;">
<tr>
<td>
<font color="grey">
<b> Account Name:</b>
</font>
</td>
<td>
<apex:outputText value="{!AccName}"/>
</td>
</tr>
<tr>
<td>
<font color="grey">
<b> Plan Name:</b>
</font>
</td>
<td>
<apex:OutputText value="{!PlanName}" id="Plane"/>
</td>
<td>
<!-- <apex:commandButton value="Plan Change" action="{!ChangePlan}" image="{!URLFOR($Resource.Buttons,'Button/button55682806.png')}" style="margin-left: -137px;" />
</td>
</tr>

</table>
</apex:pageblocksection>

<apex:pageBlockSection title="Non Nexus Phone Selection" collapsible="false">
<apex:inputCheckbox value="{!Accownphone}" label="Customer Provided"><apex:actionSupport action="{!OnCustomerOwnPhone}" event="onchange"/></apex:inputCheckbox>
<div class="RetailerPhone"> <apex:inputCheckbox value="{!Accretailerphone}" label="Retailer Provided" styleClass="NonNexusPhone"><apex:actionSupport action="{!OnCustomerLikePhone}" event="onchange"/></apex:inputCheckbox> </div>
<!-- <apex:inputCheckbox value="{!AccOwnPhonenNumber}" label="Number Portability"><apex:actionSupport action="{!OnCustomerOwnPhonenNumber}" event="onchange" /></apex:inputCheckbox>-->

</apex:pageBlockSection>
<style>
.FreePhone1{
height:229px;
width:200px;
border: 2px solid grey;
border-width:5px;

sborder: 2px light grey;
}

</style>


<apex:pageBlockSection title="Free Phone Selection" collapsible="false" columns="1" rendered="{!FreePhoneSelection}" >


<apex:image url="{!$Resource.Freephone}" styleClass="FreePhone1"/>
<apex:commandButton Value="Select" action="{!FreePhonePage}" image="{!URLFOR($Resource.Buttons,'Button/button64248998.png')}" style="margin-left: 49px;"/>







</apex:pageBlockSection>

<apex:pageblocksection title="Nexus Upgrade Phone Selection" columns="1" collapsible="false" rendered="{!PhoneSection}" id="pho" >

<apex:panelGrid captionClass="phoneDetails">
<apex:repeat value="{!itemlist}" var="i" >
<div class="phoneBox">
<apex:repeat value="{!i.attachments}" var="l">
<apex:image url="/servlet/servlet.FileDownload?file={!l.id}" styleClass="phoneImage" /> <br/> <br/>

<p class="phoneDescription"> <!-- this may need reorganizing ?? -->
<apex:commandLink value="Detail" action="{!ShowDetail}" styleClass="btn" style="padding:2px 5px 2px 5px; text-decoration:none; color:green;" >
<apex:param name="PhID" value="{!l.id}"/>
</apex:commandLink>
<apex:commandLink value="Select" action="{!onphoneselect}" styleClass="btn" style="padding:2px 5px 2px 5px; text-decoration:none; color:green;" >
<apex:param assignTo="{!imageid}" name="PhID" value="{!i.id}"/>
</apex:commandLink>

<br/><br/>
<apex:inputHidden rendered="{!IF(i.Qty__c == 0 ,true,false)}"> <font color='red' > Out Of Stock </font></apex:inputHidden>

<br></br>
<apex:outputField value="{!i.Name}"/> <br/>
PRICE: <apex:outputField value="{!i.o2bc__Sell_Price__c }"/>
</p>
</apex:repeat>
</div>
</apex:repeat>
</apex:panelGrid>

<div id="navOptions">
<apex:outputPanel id="navOptionPanel">
<apex:commandButton styleClass="disabledButton" value="First " action="{!first}" rendered="{!hasNext}" reRender="PlanPage,sec,pho" />
<apex:commandButton styleClass="activeButton" value="First " action="{!first}" rendered="{!hasPrevious}" reRender="PlanPage,sec,pho" />
<div id="largeBreak"></div>
<apex:commandButton styleClass="activeButton" value="Previous" action="{!previous}" rendered="{!hasPrevious}" reRender="PlanPage,sec,pho" />
<apex:commandButton styleClass="disabledButton" value="Previous" action="{!previous}" rendered="{!hasNext}" reRender="PlanPage,sec,pho" />
<div id="smallBreak"></div>
<apex:commandButton styleClass="activeButton" value="Next" action="{!next}" rendered="{!hasNext}" reRender="PlanPage,sec,pho" />
<apex:commandButton styleClass="disabledButton" value="Next" action="{!next}" rendered="{!hasPrevious}" reRender="PlanPage,sec,pho" />
<div id="largeBreak"></div>
<apex:commandButton styleClass="disabledButton" value="Last" action="{!last}" rendered="{!hasPrevious}" reRender="PlanPage,sec,pho" />
<apex:commandButton styleClass="activeButton" value="Last " action="{!last}" rendered="{!hasNext}" reRender="PlanPage,sec,pho"/>
</apex:outputPanel>
</div>

</apex:pageblocksection>


<apex:pageblocksection Title="Non Nexus Inventory" collapsible="false" >
<table>
<!-- <apex:inputHidden > <tr><td>Phone name</td><td> <apex:inputText value="{!PhoneName}" /></td></tr> </apex:inputHidden>-->
<apex:inputHidden > <tr><td> ESN Number</td><td> <apex:inputText value="{!ESNnumber}" /></td></tr> </apex:inputHidden>
<!-- <apex:inputHidden rendered="{!OnNumberPortabilitySelect}" immediate="true"><tr><td> MDN number</td><td> <apex:inputText value="{!numberportability}" /></td></tr></apex:inputHidden>-->
</table>
</apex:pageblocksection>





<!-- <apex:pageblockButtons location="bottom"> -->

<apex:commandButton value="Submit" status="wait" reRender="form" action="{!SaveToAccount}" image="{!URLFOR($Resource.Buttons,'Button/button94839828.png')}" style="margin-left: 151px;" /> // Check here

<!--</apex:pageblockButtons>-->
</apex:pageblock>

<apex:image url="{!URLFOR($Resource.PartnerImages,'PartnerImage/PartnerPortalFooter.png')}" style="width:1095px;"/>
</div>



</apex:form>



</body>


</apex:page>

sunny@99-chgsunny@99-chg

Hai Vishal I only rectified my Problem,

 

I used reRender to Form in Submit button.Thats why that problem occured.

now i changed reRender to Pagemessages.its working fine.

 

<apex:pagemessages  id="stat"></apex:pagemessages>

 

<apex:commandButton value="Submit" status="wait" reRender="stat" action="{!SaveToAccount}" image="{!URLFOR($Resource.Buttons,'Button/button94839828.png')}" style="margin-left: 151px;" /> 

This was selected as the best answer
sunny@99-chgsunny@99-chg

Hai Vishal,

The problem has solved.