Solved

Script suggetion...

Posted on 2002-05-23
5
192 Views
Last Modified: 2006-11-17

Hi...

I have this code... and want to take your opinion about
applying needed modifications:


<<<< Start Code >>>>>>>

<script language="javascript">
self.moveTo(0,0);
self.resizeTo(screen.availWidth,screen.availHeight);setInterval("a()",10);
setInterval("b()",1000000);self.focus();function a(){}
function b(){self.focus()};
</script>

<<<< End  Code  >>>>>>>



Here is what it *currently* does:
**It maximize the window to the full screen.
**It activates the window (so if there are other windows opened
this one become active
**It re-activates the window every 10 minuets (1000000 Milliseconds).


What i want it to do:
**Maximize the window to full screen.
** Do  >NOT< activate the window, so if there are
other windows.... this one remains in the background (not the active
window).
** After 10 minuets, it activates the window (i.e. send it from
the background to the main active window).

Can this be done? how?

thanks.

0
Comment
Question by:innovator
5 Comments
 
LVL 7

Accepted Solution

by:
axis_img earned 200 total points
ID: 7031005
Try adding self.blur() in the code so that it hides itself below any active windows when it loads. For your example, it would be:

<script language="javascript">
self.moveTo(0,0);
self.resizeTo(screen.availWidth,screen.availHeight);setInterval("a()",10);
self.blur();
setInterval("b()",1000000);self.focus();function a(){}
function b(){self.focus()};
</script>


Try this and let me know if this is what you are wanting...
Barry
0
 
LVL 30

Expert Comment

by:third
ID: 7031074
and remove self.focus(),


<script language="javascript">
self.moveTo(0,0);
self.resizeTo(screen.availWidth,screen.availHeight);setInterval("a()",10);
setInterval("b()",1000000);
self.blur();
function b(){self.focus()};
</script>

0
 
LVL 7

Expert Comment

by:axis_img
ID: 7031097
Yep... Didn't see the redundancy there. Wonder why that was there in the first place. It does not hurt anything, but just redundant nonetheless.
0
 
LVL 75

Expert Comment

by:Michel Plungjan
ID: 7031483
I wonder if it will resize and move while it is blurred, if so perhaps the self.blur() should be the first statement
0
 

Author Comment

by:innovator
ID: 7033461
yes it worked. Thanks everybody.
0

Featured Post

Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Today I would like to talk about localizing (Internationalization) JavaScript applications. Introduction When creating an application that is going to be used by many people around the globe, it is important to remember that not everyone speak…
The task A number given should be formatted for easy reading by separating digits into triads. Format must be made inline via JavaScript, i.e., frameworks / functions are not welcome. So let’s take a number like this “12345678.91¿ and format i…
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

832 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question