YouTip LogoYouTip

Plugins Base Progressbar

# jQuery EasyUI Basic Plugin - Progressbar * * jQuery EasyUI Plugins](#) * * * Override the default defaults with `$.fn.progressbar.defaults`. The progressbar provides a feedback for a long-running operation. The progress can be updated to let the user know what is currently happening. !(#) ## Dependencies * none ## Usage #### Create ProgressBar The ProgressBar component can be created from markup or programmatically. Creating from markup is easier, add the 'easyui-progressbar' class to a `
` tag.
Create ProgressBar using javascript.
$('#p').progressbar({ value: 60}); #### Get or Set Value We get the current value and set a new value to the component. var value = $('#p').progressbar('getValue');if (value < 100){ value += Math.floor(Math.random() * 10); $('#p').progressbar('setValue', value);} ## Properties | Name | Type | Description | Default Value | | :--- | :--- | :--- | :--- | | width | string | Set the width of the progressbar. | auto | | height | number | The height of the component. This property is available since version 1.3.2. | 22 | | value | number | The percentage value. | 0 | | text | string | The text template to be displayed on the component. | {value}% | ## Events | Name | Parameters | Description | | :--- | :--- | :--- | | onChange | newValue,oldValue | Fires when the value changes. Code example: $('#p').progressbar({onChange: function(value){alert(value)}}); | ## Methods | Name | Parameters | Description | | :--- | :--- | :--- | | options | none | Return the options object. | | resize | width | Resize the component. Code example: $('#p').progressbar('resize'); // resize the progressbar to initial width $('#p').progressbar('resize', 350); // resize the progressbar to a new width | | getValue | none | Return the current progress value. | | setValue | value | Set a new progress value. | * * jQuery EasyUI Plugins](#)
← Plugins Base TooltipPlugins Base Searchbox β†’