View Full Version : Progress bar java script error.

15 Sep 2008, 4:11 AM
Hi ,

I have a problem with Progress Bar. I am using progress bar while retrievening information from data base using Ajax call.

while making Ajax call first time, progress bar is displaying properly. After succesful completion of retrieving data, i am hiding the progress bar and am getting javascript error 33354 object required in IE.

If i see the error in ext-all-debug.js file, it is showing 33354 line number at


w = Math.floor(value*this.el.dom.firstChild.offsetWidth);
this.progressBar.setWidth(w); -33354.

Here is my code:

I am calling the below function in my Ajax request:

handler: showProgressBar(1,3,3,'Loading Account Info',40),
and my showProgressBar function is:

var pbar2;
function showProgressBar(n,m,time,text,steps)
pbar2 = new Ext.ProgressBar({
text:'Retrieving Account Information',

Runner.run(pbar2, time, steps||500, function(){
var pbarTimeout;
var Runner = function(){
var f = function(v, pbar, count, cb){
return function(){
if(v > count)
var i = v/count;
pbar.updateProgress(i, Math.round(''));

return {
run : function(pbar, time, count, cb){
for(var i = 1; i < (count+2); i++){
pbarTimeout = setTimeout(f(i, pbar, count, cb), i*time*1000/count);

This code i have taken from somewhere in the examples of ext js.
Problem seems to be with the width. I have tried by specifing the width, but still, i am getting java script error.

In FF, it is not showing any error. I am using Ext2.1 and IE 6.0.

Need some help on this.

17 Sep 2008, 8:37 PM
Any help will be appreciated.

30 Oct 2008, 4:40 PM
Scotch... were you able to resolve this? I have also been receiving this error in IE, primarily on the first occurrence of the ProgressBar. It doesn't seem to throw that error after that initial instance for some reason.

31 Oct 2008, 12:39 AM
Set a break on that line in Firebug, and see why it's happening.

3 Feb 2009, 3:09 AM
Did anyone have any luck resolving this issue? I tried setting a breakpoint at that line in FF but couldn't see the reason for the error only in IE.