473,666 Members | 2,258 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Short-Cut New Chromeless Window

I want to add a short-cut to a windows app similar to launching from a windows
run line

a New window, to prevent changing an existing browser window from moving off a
current logged in session to another web application.

And, I'd like it to be a chromeless window, sans toobars and sized similar to a
popup.

TIA

JeffP.....
Jul 23 '05 #1
4 5973
JeffP wrote:
I want to add a short-cut to a windows app similar to launching from a windows
run line

a New window, to prevent changing an existing browser window from moving off a
current logged in session to another web application.

And, I'd like it to be a chromeless window, sans toobars and sized similar to a
popup.

Perhaps you should ask in a Windows developer forum? One that can
guess what your unnamed "windows app" is that is launched from a
"run line" and has some idea what "sized similar to a popup" means.
TIA


You're welcome.
--
Zif
Jul 23 '05 #2
JeffP wrote:
I want to add a short-cut to a windows app similar to launching from a windows
run line

a New window, to prevent changing an existing browser window from moving off a
current logged in session to another web application.

And, I'd like it to be a chromeless window, sans toobars and sized similar to a
popup.


I am just guessing here.

Something like the following?

window.open("pr oduct.xul", "Product",
"chrome,dialog, modal,close=no, titlebar=no,res izable=no");

That's something I have been trying out with Firefox and XUL. Have no
idea about Windows or IE.

Regards,
--
Wei
Jul 23 '05 #3
Wei Wang wrote:
JeffP wrote:
I want to add a short-cut to a windows app similar to launching from a windows
run line

a New window, to prevent changing an existing browser window from moving off a
current logged in session to another web application.

And, I'd like it to be a chromeless window, sans toobars and sized similar to a
popup.

I am just guessing here.

Something like the following?

window.open("pr oduct.xul", "Product",
"chrome,dialog, modal,close=no, titlebar=no,res izable=no");

That's something I have been trying out with Firefox and XUL. Have no
idea about Windows or IE.

Regards,


On IE, if you rename any .html file to .hta, it becomes an "HTML
Application" and launches outside the browser as its own app. There are
additional parameters (and I'll post a sample structure below) that
control the window's appearance and restrictions on things like right
clicking.

The biggest thing to be aware of (for you and any users of your app) is
that an HTA is outside the security sandbox (such as it is) for IE. That
means that while a regular HTML file using Javascript can't access local
files, the registry, etc. an HTA file *can* do all of those things. It
has pretty much unfettered access to the local machine. The example
below contains a function that launches Notepad to edit the HTA itself.

To use an HTA as a basic site container, you're usually best off to make
a full-size <iframe> that has it's src attribute pointed to your
starting URL. This prevents clicked links from opening new IE windows
and keeps everything inside your HTA.

Also be sure to either leave either the sysmenu set to true (giving you
the "x" in the top right or provide a button/link to window.close().
Otherwise, it takes an ALT-F4 to kill the window. To make the example
chromeless, change the CAPTION to "no" instead of "yes".

All of the attributes of the HTA:Application tag are documented at
microsoft.com

-------------------------------------
J Wynia
Myriad Intellect, Inc.
"Web technology that earns its keep."
www.myriadintellect.com
-------------------------------------

----------yourfile.hta-------------
<HTML>
<HEAD>
<TITLE>Your HTA Application</TITLE>
<HTA:APPLICATIO N ID="yourHTA"
APPLICATIONNAME ="Your HTA Application"
BORDER="thin"
CAPTION="yes"
CONTEXTMENU="ye s"
ICON=""
INNERBORDER="no "
MAXIMIZEBUTTON= "yes"
MINIMIZEBUTTON= "yes"
NAVIGABLE="yes"
SCROLL="auto"
SELECTION="yes"
SHOWINTASKBAR=" yes"
SINGLEINSTANCE= "no"
SYSMENU="yes"
VERSION="1.0"
WINDOWSTATE="no rmal"/>
<script language="javas cript">
<!--
function edit_hta(){
$this_hta = yourHTA.command Line;
$command = "notepad.ex e " + $this_hta;
$objShell = new ActiveXObject(" WScript.Shell") ;
$lngReturn = $objShell.Run ($command, 1, true);
}
// -->
</script>
</HEAD>
<BODY>
Your HTA content goes here. Simply <a href="#"
onclick="edit_h ta();">open this HTA file</a> in a text editor and go to
town. If you're looking to make this window look much more like a
regular Windows application, I recommend looking at the <a
href="http://webfx.eae.net/docs/environ.html">C SS values that you can
grab from the current Windows theme</a>. By setting your CSS to use
those values instead of things like #CCCCCC, you can make the HTA app
blend in with the current Windows settings.
</BODY>
</HTML>
Jul 23 '05 #4
J Wynia thanks....

I found that if I use the following I get a new window, and I'll review your
code below..

From a the Windows run line....
run: iexplore.exe http://myserver/mywebapp/mailrem.aspx

I may also try to put a literal in my aspx page that can do the following.

-- re-direct to a new instance browser chromeless window and the required page
-- go back one to restore the original browser window to the previous web
application

I'm not sure what's so confusing my users run a windows application for their
CRM processes, which I can cmd buttons to launch other programs or an internet
browser.

These users are also usually logged into one of a few websites for our business
service partners and they don't like being logged out. They'd prefer a new
browser window.

I have many times launched chromeless windows from w/in my own web app for
clients that run one single web app, but this client has no less than 4 to 6
windows open to their service providers.

I'll post my best solution state when available....

Thanks again...

JeffP.....
"J Wynia" <jw****@speakea sy.net> wrote in message
news:CK******** ************@sp eakeasy.net...
Wei Wang wrote:
JeffP wrote:
I want to add a short-cut to a windows app similar to launching from a windowsrun line

a New window, to prevent changing an existing browser window from moving off acurrent logged in session to another web application.

And, I'd like it to be a chromeless window, sans toobars and sized similar to apopup.

I am just guessing here.

Something like the following?

window.open("pr oduct.xul", "Product",
"chrome,dialog, modal,close=no, titlebar=no,res izable=no");

That's something I have been trying out with Firefox and XUL. Have no
idea about Windows or IE.

Regards,


On IE, if you rename any .html file to .hta, it becomes an "HTML
Application" and launches outside the browser as its own app. There are
additional parameters (and I'll post a sample structure below) that
control the window's appearance and restrictions on things like right
clicking.

The biggest thing to be aware of (for you and any users of your app) is
that an HTA is outside the security sandbox (such as it is) for IE. That
means that while a regular HTML file using Javascript can't access local
files, the registry, etc. an HTA file *can* do all of those things. It
has pretty much unfettered access to the local machine. The example
below contains a function that launches Notepad to edit the HTA itself.

To use an HTA as a basic site container, you're usually best off to make
a full-size <iframe> that has it's src attribute pointed to your
starting URL. This prevents clicked links from opening new IE windows
and keeps everything inside your HTA.

Also be sure to either leave either the sysmenu set to true (giving you
the "x" in the top right or provide a button/link to window.close().
Otherwise, it takes an ALT-F4 to kill the window. To make the example
chromeless, change the CAPTION to "no" instead of "yes".

All of the attributes of the HTA:Application tag are documented at
microsoft.com

-------------------------------------
J Wynia
Myriad Intellect, Inc.
"Web technology that earns its keep."
www.myriadintellect.com
-------------------------------------

----------yourfile.hta-------------
<HTML>
<HEAD>
<TITLE>Your HTA Application</TITLE>
<HTA:APPLICATIO N ID="yourHTA"
APPLICATIONNAME ="Your HTA Application"
BORDER="thin"
CAPTION="yes"
CONTEXTMENU="ye s"
ICON=""
INNERBORDER="no "
MAXIMIZEBUTTON= "yes"
MINIMIZEBUTTON= "yes"
NAVIGABLE="yes"
SCROLL="auto"
SELECTION="yes"
SHOWINTASKBAR=" yes"
SINGLEINSTANCE= "no"
SYSMENU="yes"
VERSION="1.0"
WINDOWSTATE="no rmal"/>
<script language="javas cript">
<!--
function edit_hta(){
$this_hta = yourHTA.command Line;
$command = "notepad.ex e " + $this_hta;
$objShell = new ActiveXObject(" WScript.Shell") ;
$lngReturn = $objShell.Run ($command, 1, true);
}
// -->
</script>
</HEAD>
<BODY>
Your HTA content goes here. Simply <a href="#"
onclick="edit_h ta();">open this HTA file</a> in a text editor and go to
town. If you're looking to make this window look much more like a
regular Windows application, I recommend looking at the <a
href="http://webfx.eae.net/docs/environ.html">C SS values that you can
grab from the current Windows theme</a>. By setting your CSS to use
those values instead of things like #CCCCCC, you can make the HTA app
blend in with the current Windows settings.
</BODY>
</HTML>

Jul 23 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

10
2262
by: Niels Dekker (no reply address) | last post by:
Is it possible for a standard compliant C++ compiler to have ( sizeof(short) < sizeof(int) ) and ( sizeof(short) == sizeof((short)0 + (short)0) ) ? Regards, Niels Dekker http://www.xs4all.nl/~nd/dekkerware
99
9038
by: Glen Herrmannsfeldt | last post by:
I was compiling a program written by someone else about six years ago, and widely distributed at the time. It also includes makefiles for many different systems, so I know it has been compiled with many different compilers. I got compile errors when it used va_arg to fetch an argument of type short. That seemed a little strange to me, so I changed it to int and it compiled just fine. So now I wonder, just what is the rule for va_arg...
34
16665
by: Andy | last post by:
Hi, Are 1 through 4 defined behaviors in C? unsigned short i; unsigned long li; /* 32-bit wide */ 1. i = 65535 + 3; 2. i = 1 - 3; 3. li = (unsigned long)0xFFFFFFFF + 3; 4. li = 1 - 3;
8
1684
by: NilsNilsson | last post by:
I wrote this: short s1 = 0; short s2 = 1; short s3 = s1 + s2; And gor this compile error message: Cannot implicitly convert type 'int' to 'short' What is wrong here?
8
16379
by: Ken Dopierala Jr. | last post by:
Hi, I'm reading the header file of a PCX image and I need to convert 2 bytes to a short. How would I go about doing this? I know that they are bytes 8 & 9 in my byte array. I'm not sure how to take those two and convert them into a short though. In C I would just use a union and assign them accordingly. Thanks! Ken.
15
8262
by: Steffen Loringer | last post by:
Hi, I'm using the following function to join 2 char (byte) into one short on a 32 bit X86 platform: unsigned short joinUnsigShort(unsigned char a,unsigned char b) { unsigned short val = 0; val = a; val <<= 8;
4
5187
by: slougheed | last post by:
I encountered a problem after we had converted our declarations of 'unsigned short int' to uint16_t. In one instance, whoever did the conversion failed to delete the 'short' keyword so we had a 'uint16_t short'. The compiler (GNU 3.3.5) allows this but ignores the original unsigned keyword and initialzes the variable as a signed short int. I created a very simple test program just to see what was happening: #include <stdio.h> ...
10
5628
by: Jim Langston | last post by:
Is the following well defined? size_t IntVal = 65537; unsigned short Length; if ( IntVal static_cast<unsigned short>( -1 ) ) { std::cout << "Value too long to fit in a short" << std::endl; } else
10
5431
by: nyhetsgrupper | last post by:
The following code result in the following compilation error: Error 1 Cannot implicitly convert type 'int' to 'short'. An explicit conversion exists (are you missing a cast?) short a = 1; short b = 2; short result = a + b; Can anyone explain why??
3
6397
by: mathieu | last post by:
Could someone please tell me what is wrong with the following -ugly- piece of c++ code. Why when I explicititely set the template parameter my gcc compiler start getting confused: bla.cxx: In function 'int main()': bla.cxx:25: error: call of overloaded 'foo(short unsigned int*&)' is ambiguous bla.cxx:2: note: candidates are: void foo(OutputType*) bla.cxx:10: note: void foo(PixelType*)
0
8443
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8356
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8866
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8781
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8550
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
4198
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
2769
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
2011
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1772
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.