This is a migrated thread and some comments may be shown as answers.

Progress bar inside itemtemplate

1 Answer 50 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Jean-Marc
Top achievements
Rank 1
Jean-Marc asked on 18 Jul 2012, 08:33 AM
I need to have a progress bar inside my grid
<ItemTemplate>
 <div id="progress_bar" class="ui-progress-bar ui-container">
  <div id="PBar" class="ui-progress" style="width:0;">
  <span class="ui-label" style="display:block;"> <b id="PValue" class="value">0%</b></span>
  </div><!-- .ui-progress -->
 </div><!-- #progress_bar --> 
</ItemTemplate>
 for (var i = 0; i < rows.length; i++) {
                masterTable.getColumnByUniqueName("IDMailing").get_element(); //accessing Bound Columns
                idMailingToWrite = rows[i].get_cell("IDMailing").innerText;

                    if (idMailingToWrite == idMailingToFind) {
                        var pbar = rows[i].findElement("PBar");
                        pbar.style.width = progressValue + "%";

                        var PValue = rows[i].findElement("PValue");
                        PValue.innerHTML = progressValue + "%";

                    }
            }

the problem is that as I access to the div to write the value it always is the first div, I mean the one of the first row of the grid no matter of what row really is.

how can I access to the right div?

Thank you


1 Answer, 1 is accepted

Sort by
0
Jean-Marc
Top achievements
Rank 1
answered on 18 Jul 2012, 09:05 AM
oh yes ok...i see...forgot runat="server"
Tags
Grid
Asked by
Jean-Marc
Top achievements
Rank 1
Answers by
Jean-Marc
Top achievements
Rank 1
Share this question
or