• Post Reply Bookmark Topic Watch Topic
  • New Topic

Always on Top Functionality  RSS feed

 
Manikandan Adaikkalavan
Ranch Hand
Posts: 35
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I am opening a HTML file in Internet Explorer from my swing application.
I am using the code given below
...........
private final static String WIN_FLAG = "url.dll,FileProtocolHandler";
private final static String WIN_PATH = "rundll32";
............
String cmd = WIN_PATH + " " + WIN_FLAG + " " + url;
// url is HTML file Path
Process p = Runtime.getRuntime().exec( cmd );
...........
The HTML file is opening up,but it always opens behind the swing application,that makes me every time to maximize the HTML file after it being opened up.
I want to open it in front of the Swing Application.I need to implement "Always On Top" functionality for the html page in java / javascript.
any idea please ??
 
John Smith
Ranch Hand
Posts: 84
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm not sure you can change this behavior (easily). I was under the impression that what you are observing is a "feature" in Windows designed to prevent random applications from stealing the focus whenever they please.
Randy
 
Manikandan Adaikkalavan
Ranch Hand
Posts: 35
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can't be solved in Java ?? ]
I am in need to solve this...
I also tried in Javscript...i.e., that opening HTML page...in that body tag ...i tried in calling self.focus() method.....but still didn't get worked.....
Please anybody to help me out .....
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!