Posted By
|
Message
|
Blackstorm
Registered 29/08/2002
Points 439
|
20th June, 2004 at 23:50:44 -
Does anyone know how I could make it so that a reminder pops up a week in advance of a certain date? I'm trying to make a calendar where you type in something that you have to do at a certain date and have a popup appear telling you that you need to do that thing in seven days, 1 day, etc.
I also need to know how and if it's even poosible to make a program start up when windows opens, and then remain on the desktop without a window in the taskbar at the bottom.
Wise sayings:
"A pint of example is worth a gallon of advice."
"Do unto others as you want done unto you."
"An idea is nothing without effort."
"HOLY CRAP!"
|
Assault Andy Administrator
I make other people create vaporware
Registered 29/07/2002
Points 5686
|
21st June, 2004 at 02:27:09 -
Yes-sir-ee! Okay open up your win.ini file (surprising located in your windows directory) and look at it.
[windows]
load=
NullPort=None
device=HP DeskJet 690C Series Printer,HPFDJC07,LPT1:
That is the section you want to look at. Using MMF\TGF and the ini object open up this file, change the group to "windows" and the item to "run". Next set the value as a string to "[Your program's location here]". So it now looks similar to this:
[windows]
load=
run="C:\andy\games\poo.exe"
NullPort=None
device=HP DeskJet 690C Series Printer,HPFDJC07,LPT1:
There are other methods, I think adding the tag -startup to a shortcut's target should make the file load on startup but I'll have to look into that. Anyway,
Since I do not know what program you are using I will write this explanation using MMF. Now that you have your file starting up you should add the date\time object (only for MMF) and one of the various alert\popup\newwindow objects to your application. Then with your date and time object and on the start of the frame (because your app runs everytime the user turns on the computer) check the date, and then check the appointments that the user has recorded. If one of the recorded dates is equal to the current date minus 7 days(one week in advance) then use the pop-up window object to alert your user.
Creator of Faerie Solitaire:
http://www.create-games.com/download.asp?id=7792
Also creator of ZDay20 and Dungeon Dash.
http://www.Jigxor.com
http://twitter.com/JigxorAndy
|
Kris Possibly Insane
Registered 17/05/2002
Points 2017
|
21st June, 2004 at 08:02:11 -
or you could just put it in the startup folder on the start menu
"Say you're hanging from a huge cliff at the top of mt. everest and a guy comes along and says he'll save you, and proceeds to throw religious pamphlets at you while simultaniously giving a sermon." - Dustin G
|
Tigerworks Klik Legend
Registered 15/01/2002
Points 3882
|
21st June, 2004 at 09:03:06 -
Startup folder is probably a better idea, as firstly you might overwrite something else running on startup in win.ini, plus the run= in win.ini is where most viruses put themselves to boot on startup, so people's antivirus programs may get suspicious.
- Tigerworks
|
Kramy
Registered 08/06/2002
Points 1888
|
21st June, 2004 at 14:01:40 -
You could also put the startup command in the registry(like I have for some of my own programs), but you'll have to figure that out yourself if you want to. I'm not going to explain it because it's far too easy to mess up people's computers without them knowing once you know how.
Kramy
|
Blackstorm
Registered 29/08/2002
Points 439
|
21st June, 2004 at 14:22:57 -
Assault Andy, I'm using MMF.
I know I need to have the program check and see if the date seven days ago has a reminder, but every time I try to add an event saying that "today's date is equal to today's date - 7 days", I just confuse myself. So... Much... MATH!
BTW...
Kramy, do you not trust me? *sniff*
Wise sayings:
"A pint of example is worth a gallon of advice."
"Do unto others as you want done unto you."
"An idea is nothing without effort."
"HOLY CRAP!"
|
Kramy
Registered 08/06/2002
Points 1888
|
21st June, 2004 at 14:53:45 -
It's not whether I don't trust you, it's whether I don't trust 50% of the people on these forums, that are reading these posts.
You'll need to store the day and month to remind.
Make 2 counters - a test "day" counter, and a test "month" counter
Always
--Set Month-counter to current month
--Set Day-counter to current day
If Day-counter-7 <= 0
--Subtract a month from Month-counter
--Set Day-counter to day-7
--Set Day-counter to ##days in month## + Day-Counter
If Month-counter > Month of Remind Date
--Remind
--Disable Remind(for next time)
If Month-counter equals Month of Remind Date
If Day-counter >= Day of Remind Date
--Remind
--Disable Remind(for next time)
Then you just have to record the month/day when a Reminder Date is entered. Oh, and that won't check years...
I actually used a similar system in a Reminder program I made, but it goes in the opposite direction, checking if a date hasn't passed yet. Oh, and I just typed that out by head, so I haven't tested if any of it will work.
Kramy
|
|
|