/    Sign up×
Community /Pin to ProfileBookmark

Java Script Error

I’ve a Web application written in Java script, which has a progress bar that will be displayed when the job is in progress.

Once the execution is completed progress bar gets erased and status of the job is displayed in the Internet explorer and application ‘ll come out of the job.

But in our Intranet application this works fine, but in Internet application the same is not working.
Progress bar is not getting erased and hence job status is not displayed in Internet explorer.

Please let me know if any of you come across the same and how to resolve the issue.

Thanks, -Sanna

to post a comment
JavaScript

5 Comments(s)

Copy linkTweet thisAlerts:
@disgracianJan 02.2007 — It's very difficult to diagnose the problem without seeing an example of the Javascript code or knowing what browser(s) are being used.

Cheers,

D.
Copy linkTweet thisAlerts:
@OverstatementJan 02.2007 — She said Internet Explorer. Yes, you need to provide the code that kills your page. And it's not clear what your showing the progress of, is it the progress of a server-side script or something in Javascript? And what comes after the this progress is finished?
Copy linkTweet thisAlerts:
@KSANNAauthorJan 02.2007 — Hi ,

Please find the explanation below:

We are calling the displayProgressbar() function before a call to stored process. So the gif image will be visible as long as the stored process in the backend is getting executed. Once the stored process gets executed, eraseprogressbar() will be called to erase the gif image(processing_EN.gif which is attached in this mail).


javascript function to display and erase the progress bar image:

Sub displayProgressbar()

Response.Write("<div id ='myDiv' STYLE='FONT-WEIGHT: bold; FONT-SIZE: 11pt; LEFT:350 px; COLOR: Red; FONT-FAMILY: Verdana; POSITION: absolute; TOP: 250 px; TEXT-ALIGN: center' > <img id = 'pBar' src=../Images/Processing_EN.gif></div>")

Response.Write("<script language=javascript>var pBar = document.getElementById('pBar');var myDiv = document.getElementById('myDiv');</script>")

Response.Write("<script language=javascript>function StartShowWait(){myDiv.style.visibility = 'visible';} window.clearInterval(); StartShowWait(); </script>")

Response.Flush()

End Sub

Sub eraseprogressbar()

'TO hide the progress bar

''''Response.Write("function HideWait(){mydiv.style.visibility = 'hidden';window.clearInterval();}")

Response.Write("<script language=javascript>")

Response.Write("myDiv.style.visibility='hidden';</script>")

Response.Flush()

End Sub

[upl-file uuid=bf55169a-079f-4f24-a9ab-ece786fb91af size=2kB]processing_EN.gif[/upl-file]
Copy linkTweet thisAlerts:
@OverstatementJan 02.2007 — I'm not familiar with the display property. Have you instead tried:
<i>
</i>myDiv.style.display = 'none';
myDiv.style.display = 'block';


I don't know why you're calling window.clearInterval() but it needs the id returned from SetInterval() as it's arguement.

And this line:
function HideWait(){mydiv.style.visibility = 'hidden';window.clearInterval();} it's not enclosed in <script> tags. You also never call that function.

And you need to enclose your img's src path with quotes. Apparently, browsers aren't as forgiving when it comes to src.

I don't know what language you're writing this in but you seem afraid to break up your <script> tags to seperate write commands on the first function but not on the second function.
Copy linkTweet thisAlerts:
@disgracianJan 03.2007 — The "Sub()...End Sub" stuff is VBScript, not Javascript, although there are some calls to Javascript in there which I'm not entirely sure is a wise idea. I'm no expert but I doubt that mixing scripting languages is a really great idea.

Cheers,

D.
×

Success!

Help @KSANNA spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 6.17,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @nearjob,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,
)...