473,787 Members | 2,798 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

power off while running exe

9 New Member
hi! i want to know that if my vb application is running i.e. the exe and suppose in between that if power goes off and the computer gets switched off. when power comes and we switch on the computer then that exe should run from the same point where it has stopped earier during power off.
Sep 28 '07 #1
4 1241
code937
24 New Member
I think that would depend upon what the application was doing...

If you're processing data then you could put in a marker about which record you have reached on a query unload event and then when the program starts back up it looks for that marker, if you're not handling data then im not sure how, i'd need to see what you app is doing to carry on with.
Sep 28 '07 #2
Ali Rizwan
925 Contributor
hi! i want to know that if my vb application is running i.e. the exe and suppose in between that if power goes off and the computer gets switched off. when power comes and we switch on the computer then that exe should run from the same point where it has stopped earier during power off.
Hello
This is on the type of your app.
There are two solutions
1) As said below use marker
2) Use a configuration file in which after every second or after soome time all of your work or your working state will copied and when the power turns off and on you can load settings from that file it can be a txt file or a database.

Now tell which solution you choose.
I can made an example for you.
GOODLUCK
Sep 28 '07 #3
skadu3
9 New Member
hi thanks for your reply.
as i don't know how to use a marker, can you please send me the examples of both the solutions.

WAITING FOR YOUR REPLY!!!!
Sep 29 '07 #4
Ali Rizwan
925 Contributor
hi thanks for your reply.
as i don't know how to use a marker, can you please send me the examples of both the solutions.

WAITING FOR YOUR REPLY!!!!
I m really very sorry because i cant do this at this time but i ll make it any other time.
But i too not know about marker i can only make of copying the text to a file.
But let me know the app you are building is a database or any other.
If not then you use FSO system for this purpose on a timer control. Which saves all the data in the textboxes, state of checkboxes and other controls in a txt or any other file.
Let you set 1 second to timer then timer save all the state to the txt file after every 1 second
You can tell by marker to the person who give the idea.

I m SORRY buddy

GOODLUCK
ALI
Sep 30 '07 #5

Sign in to post your reply or Sign up for a free account.

Similar topics

6
4018
by: Stephane Belzile | last post by:
Is there a way I can detect in vb.Net the power has switched to a UPS unit in case of power failure? Thanks
6
358
by: Stephane Belzile | last post by:
Is there a way I can detect in vb.Net the power has switched to a UPS unit in case of power failure? Thanks
6
2457
by: maxthebaz | last post by:
Our machines have this requirement: if power failure occurs, many important variables are to be resumed from where they were interrupted after the machine is restarted (power on in this case). In other words, the basic idea is to keep a snapshot of the state machine before it is interrupted. The board is provided with: - a 32-bit H8S/2633 Hitachi microprocessor; - a battery-backed memory (BBM), where these variables are stored; BBM area...
16
6684
by: nagmvs | last post by:
Hi, Can any one tell me How to disable Keyboard Functions using JavaScript.If knows please tell me the code.Also tell me the code for mouse disable also. Thanks, Nagesh.
0
9655
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
10363
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
10169
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
10110
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
9964
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
6749
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
5534
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4067
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
3
2894
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.