+ Start a Discussion
❤Code❤Code 

Dynamic display upload browse button

Hi All,

I have an requirement where i have an object X__c and checkbox fields as C1__c, C2__c, C3__c. Whenever i click checkbox C1__c then dynamically it will display one upload browse button near that checkbox field. Whenevr i will uncheck the browse button will disapper. 

And 2nd one is i can upload more than 15mb file and less than 25 mb.

Can anyone share some sample code.

Regards
viruSviruS
Use Inline VF page on standard layout or use full vf page 
❤Code❤Code
Hi Virus,

How to upload more than 10 mb file as an attachment.

Regards
viruSviruS
The size limit for an attached file is 25 MB when attached directly to the related list.

The size limit for multiple files attached to the same email is 25 MB, with a maximum size of 5 MB per file.

https://help.salesforce.com/apex/HTViewHelpDoc?id=collab_files_size_limits.htm
Sudeep DubeSudeep Dube
For this vf page create PracticeSchenario__c   custom object  and two custom field  C1, C2 check box type and one Name field 
I hope this is good for ur intialtive 


<apex:page standardController="PracticeSchenario__c" >
    Hi this is according to ur requirement
  <apex:form id="f1">
  
   <apex:inputField value="{!PracticeSchenario__c.name}"/> 
  
  
   <apex:inputField value="{!PracticeSchenario__c.c1__c}" >
   <apex:actionSupport event="onchange" reRender="f1" />
   </apex:inputField> 
   <apex:commandButton value="upload" rendered="{!PracticeSchenario__c.c1__c}" id="b1"/>
  
   <apex:inputField value="{!PracticeSchenario__c.c2__c}">           
     <apex:actionSupport event="onchange" reRender="f1" />
   </apex:inputField> 
   <apex:commandButton value="upload" rendered="{!PracticeSchenario__c.c2__c}" id="b2"/>
  
  </apex:form>
</apex:page>


Regards 
Sudeep Kumar Dube