HTMLDOM進行状況オブジェクト
プログレスオブジェクト
Progressオブジェクトは、HTMLの<progress>要素を表します。
<progress>要素は、タスクの進行状況を表します。
進行状況オブジェクトにアクセスする
getElementById()を使用して、<progress>要素にアクセスできます。
例
var x = document.getElementById("myProgress");
進行状況オブジェクトを作成する
document.createElement()メソッドを使用して、<progress>要素を作成できます。
例
var x = document.createElement("PROGRESS");
進行状況オブジェクトのプロパティ
Property | Description |
---|---|
labels | Returns a list of the progress bar's labels (if any) |
max | Sets or returns the value of the max attribute of a progress bar |
position | Returns the current position of the progress bar |
value | Sets or returns the value of the value attribute of a progress bar |
標準のプロパティとイベント
Progressオブジェクトは、標準のプロパティとイベントもサポートします。
関連ページ
HTMLリファレンス:HTML <progress>タグ