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
gyani19901.3956550919266765E12gyani19901.3956550919266765E12 

How can i use loading image on button click in salesforce1 app

Hi,
I have a vf page and in this vf page i use a loading image and this image is show in system but i want to show in the salesforce1 app so what should i have to do regarding this pop up on button click.
User-added image
Wizno @ ConfigeroWizno @ Configero
Are you trying to have your custom Loading icon appear in the standard SF1 interface?
You won't be able to do that, but you can have it come up on your VF page within your SF1 app. 

Otherwise, in your VF Page you can have something similar to this. 
 
<apex:commandButton onClick="showLoadingDiv()" action="{!YourCustomAction}" value="Submit"></apex:commandButton>

<script>
function showLoadingDiv(){
   //Assuming JQuery is loaded
   $("#LoadingIndicator").show();
}
function hideLoadingDiv(){
   $("#LoadingIndicator").hide();
}
</script>


<div id="LoadingIndicator">
   <img src="{!URLFOR($Resource.LoadingIcon)}"/>
</div>

<style>
  #LoadingIndicator { display: none; }
</style>