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

Home Posts Topics Members FAQ

Is there an equivalent of exit() for quitting a smartdevice application ?

How can I quit a smartdevice application ?

After I click the right-hand(up) "X" button in the Pocket
PC 2002 Emulator,it seems that the smartdevice
application has not been closed.
(My smartdevice app has three forms.
Every form has a "X" button which is close to
the time information.)
Why? what happened when I click the button?

thx for answering my qestion.^^
Nov 15 '05 #1
8 2512

"Eric" <u0******@cc.nc u.edu.tw> wrote in message
news:0a******** *************** *****@phx.gbl.. .
How can I quit a smartdevice application ?

After I click the right-hand(up) "X" button in the Pocket
PC 2002 Emulator,it seems that the smartdevice
application has not been closed.
(My smartdevice app has three forms.
Every form has a "X" button which is close to
the time information.)
Why? what happened when I click the button?

thx for answering my qestion.^^


For some reason the "X" is a *minimize* button. When you disable
the minimize button you will get an "ok" button, which is the real "close"
button.

Apparently smart-device applications should never close, instead they should
minimize. The O/S will make sure not more than one version of the app
is running. It is however up to the programmer to free up resources
on "minimize".

Hans Kesting
Nov 15 '05 #2
If I use a socket to connect to a server in my smart-
device application,doe s the "ok" button free up all
resources including the socket?

It's more easier and natural for me to use the "ok"
button to close my app and free up all resources.And then
start my app again whenever I want.The "X" button really
makes me confused when I want to restart my app.
Can I just use the "ok" button in my app or it's better
for me to use the "X" button ?
-----Original Message-----

"Eric" <u0******@cc.nc u.edu.tw> wrote in message
news:0a******* *************** ******@phx.gbl. ..
How can I quit a smartdevice application ?

After I click the right-hand(up) "X" button in the Pocket PC 2002 Emulator,it seems that the smartdevice
application has not been closed.
(My smartdevice app has three forms.
Every form has a "X" button which is close to
the time information.)
Why? what happened when I click the button?

thx for answering my qestion.^^
For some reason the "X" is a *minimize* button. When you

disablethe minimize button you will get an "ok" button, which is the real "close"button.

Apparently smart-device applications should never close, instead they shouldminimize. The O/S will make sure not more than one version of the appis running. It is however up to the programmer to free up resourceson "minimize".

Hans Kesting
.

Nov 15 '05 #3
Just call Close() from your main form.

Works for me.

jim

"Eric" <u0******@cc.nc u.edu.tw> wrote in message
news:0a******** *************** *****@phx.gbl.. .
How can I quit a smartdevice application ?

After I click the right-hand(up) "X" button in the Pocket
PC 2002 Emulator,it seems that the smartdevice
application has not been closed.
(My smartdevice app has three forms.
Every form has a "X" button which is close to
the time information.)
Why? what happened when I click the button?

thx for answering my qestion.^^

Nov 15 '05 #4
To add to this, the main form must have its "MinimizeBo x" property set to
false. Otherwise, when the X is clicked on the main form, the application
will be minimised, rather than exiting. One problem with this, is that when
the "MinimizeBo x" property is changed, the X in the top right hand corner
changes to an "Ok" button. As far as I know, there is no way around this.

Hope this helps,

Mun

--
Munsifali Rashid
http://www.munsplace.com/


"Jim H" <no****@jimsacc ount.com> wrote in message
news:OV******** *****@TK2MSFTNG P11.phx.gbl...
Just call Close() from your main form.

Works for me.

jim

"Eric" <u0******@cc.nc u.edu.tw> wrote in message
news:0a******** *************** *****@phx.gbl.. .
How can I quit a smartdevice application ?

After I click the right-hand(up) "X" button in the Pocket
PC 2002 Emulator,it seems that the smartdevice
application has not been closed.
(My smartdevice app has three forms.
Every form has a "X" button which is close to
the time information.)
Why? what happened when I click the button?

thx for answering my qestion.^^


Nov 15 '05 #5
No it doesn't. The MinimizeBox property can be set to true. I just tested
this and calling Close() from inside MyForm1 results in the process exiting
cleanly. I don't set the MinimizeBox property to false in any of my
applications.

jim

"Munsifali Rashid" <mun.news@#Remo veToReply#cordl essmouse.co.uk> wrote in
message news:er******** ******@TK2MSFTN GP11.phx.gbl...
To add to this, the main form must have its "MinimizeBo x" property set to
false. Otherwise, when the X is clicked on the main form, the application
will be minimised, rather than exiting. One problem with this, is that when the "MinimizeBo x" property is changed, the X in the top right hand corner
changes to an "Ok" button. As far as I know, there is no way around this.

Hope this helps,

Mun

--
Munsifali Rashid
http://www.munsplace.com/


"Jim H" <no****@jimsacc ount.com> wrote in message
news:OV******** *****@TK2MSFTNG P11.phx.gbl...
Just call Close() from your main form.

Works for me.

jim

"Eric" <u0******@cc.nc u.edu.tw> wrote in message
news:0a******** *************** *****@phx.gbl.. .
How can I quit a smartdevice application ?

After I click the right-hand(up) "X" button in the Pocket
PC 2002 Emulator,it seems that the smartdevice
application has not been closed.
(My smartdevice app has three forms.
Every form has a "X" button which is close to
the time information.)
Why? what happened when I click the button?

thx for answering my qestion.^^



Nov 15 '05 #6
Are you testing this on the emulator or the Pocket PC device itself? As far
as I remember, clicking the X on the emulator would cause the process to
exit, regardless of the what the MinimizeBox property was set to. However,
on the handheld device, if this property was set to true, clicking on the X
would simply cause the application to minimise, rather than exit.
Re-launching the application would simply restore its window and resume from
where it was minimised.

Regards,

Mun

--
Munsifali Rashid
http://www.munsplace.com/


"Jim H" <no****@jimsacc ount.com> wrote in message
news:Oa******** ******@TK2MSFTN GP10.phx.gbl...
No it doesn't. The MinimizeBox property can be set to true. I just tested this and calling Close() from inside MyForm1 results in the process exiting cleanly. I don't set the MinimizeBox property to false in any of my
applications.

jim

Nov 15 '05 #7
I tested on both. You are correct, clicking the X will minimize the app. I
wasn't saying clicking the X would terminiate the app, sorry for the
misunderstandin g. What I was saying is calling Close() from inside the code
will terminate the application. He could add a close button, menu item, or
catch any message he wants and call the Form.Close() method.

jim

"Munsifali Rashid" <mun.news@#Remo veToReply#cordl essmouse.co.uk> wrote in
message news:uC******** ******@tk2msftn gp13.phx.gbl...
Are you testing this on the emulator or the Pocket PC device itself? As far as I remember, clicking the X on the emulator would cause the process to
exit, regardless of the what the MinimizeBox property was set to. However, on the handheld device, if this property was set to true, clicking on the X would simply cause the application to minimise, rather than exit.
Re-launching the application would simply restore its window and resume from where it was minimised.

Regards,

Mun

--
Munsifali Rashid
http://www.munsplace.com/


"Jim H" <no****@jimsacc ount.com> wrote in message
news:Oa******** ******@TK2MSFTN GP10.phx.gbl...
No it doesn't. The MinimizeBox property can be set to true. I just

tested
this and calling Close() from inside MyForm1 results in the process

exiting
cleanly. I don't set the MinimizeBox property to false in any of my
applications.

jim


Nov 15 '05 #8
Not to worry, it's all a learning experience :-)

Regards,

Mun

--
Munsifali Rashid
http://www.munsplace.com/


"Jim H" <no****@jimsacc ount.com> wrote in message
news:Oo******** ******@TK2MSFTN GP11.phx.gbl...
I tested on both. You are correct, clicking the X will minimize the app. I wasn't saying clicking the X would terminiate the app, sorry for the
misunderstandin g. What I was saying is calling Close() from inside the code will terminate the application. He could add a close button, menu item, or catch any message he wants and call the Form.Close() method.

jim

Nov 15 '05 #9

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

Similar topics

1
8515
by: Guinness Mann | last post by:
Pardon me if this is not the optimum newsgroup for this post, but it's the only .NET newsgroup I read and I'm certain someone here can help me. I have a C# program that checks for an error condition and if it finds it it notifies the user with a MessageBox and then on the next line of code (example in a minute) it calls Application.Exit(). To my astonishment, I stepped through the code with the debugger, and watched it call...
3
1515
by: Komandur Kannan | last post by:
We have application developed in .net platform (vb.net) running on a Symbol MC9000G handhelds. These handhelds authenticate to our 2000 domain using Kerberos. There is a mid-tier code running as web services to connect to the oracle back-end. I would like to get the username (logged into domain) in the code running in the handheld - the smartdevice platform does not support Environment.Username. How can i get this? This will help us...
20
5521
by: Mark | last post by:
I am using gnu g++ version 3.3.2, trying a simple test to read in and then write out a large (100,000 line) text file ########################################## CSTDIO VERSION TO READ/WRITE TEXT FILE: #include <cstdlib> #include <cstdio> using namespace std;
0
1160
by: Jérôme MATHIEU | last post by:
Hello everybody, Is it possible to develop smartdevice app on .net 4.2 with vs2005 ? thank you very much have a nice day Jérôme
3
1716
by: Xee | last post by:
When making a Smartdevice program and putting in a transparant picture, the part that "used to be transparant" is white. Is there something I can do about this?
0
994
by: JereeshVijayan | last post by:
hi, anyone can tell me from where i will get an example source code of C#.net, how to connect a 'SmartDevice' to a RAS through 'Dial Up Connection' Thanks Jereesh
2
5762
by: jsimons | last post by:
If the user accidentally clicks the X close button I'm using the following code in the form unload event to stop them from accidentally quitting Access. Private Sub Form_Unload(Cancel As Integer) Select Case MsgBox("Are you sure you want to exit?", vbYesNo) Case Is = vbYes Exit Sub Case Is = vbNo Cancel = True
21
3484
by: J de Boyne Pollard | last post by:
HSfgets() is standard in C file I/O. HS> HSThe only issue you need to pay attention too, is RAW HS(binary) vs COOK mode. It will relate the EOL (end HSof line) definitions of MS-DOS (<CRL><LR>) vs HSUnix (<LF>). Depending on your application that HSmay or may no pertain. TRThis is a handy definition, but it is NOT CORRECT. TRThe raw vs cooked distinction in Unix is VERY different
0
918
by: Bob Develd | last post by:
I wrote an application Smart Device for Pocket PC with Windows Mobile 5.0. In VStudio, how to recompile quickly this application for Pocket PC with Windows Mobile 6.0 without transferring all faile in a new project ? Thank for response
0
8883
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...
1
8561
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,...
1
6203
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5672
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4200
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...
0
4372
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2776
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
2013
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1778
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.