juicelooser
08-05-2003, 10:10 PM
I would like to be able to make a popup come up via cron that would say something at a certain time and possibly have a "yes" and "no" sort of thing on it. How would I be able to do this?
|
Click to See Complete Forum and Search --> : popup at a certain time juicelooser 08-05-2003, 10:10 PM I would like to be able to make a popup come up via cron that would say something at a certain time and possibly have a "yes" and "no" sort of thing on it. How would I be able to do this? Hayl 08-05-2003, 10:20 PM set up cron to run script that runs the xmessage command man xmessage for details on how to use it. juicelooser 08-05-2003, 10:23 PM man xmessage says that there is no manual entry for xmessage and when I type 'xmessage', it says command not found. I'm running Mandrake 9.1 Hayl 08-05-2003, 10:32 PM i guess you'll have to see if you can find the rpm fo rit on your install CDs if they have one. it's supposed to be installed with Xfree86. it's installed here on both of my systems. /usr/X11R6/bin/xmessage /usr/bin/X11/xmessage juicelooser 08-05-2003, 10:44 PM Okay, I've got that installed and I've played around with it a little. What I'm wondering is how to figure out what the user selects. I know it prints the button selected to the terminal, but how do I process that and, if the user selects one thing, do something, and if the user selects the other, do something else? sharth 08-05-2003, 10:53 PM use the -print option. and | (pipe) it, or set it equal to a variable in a script. then do the old if blah blah blah do blah blah blah. Hayl 08-05-2003, 10:54 PM it returns the number of the button that was clicked as its exit status. no matter what button you click, it will exit but you can make it run something else depending on the button that was pressed. (this is all in the manpage) juicelooser 08-05-2003, 11:23 PM awesome- thanks a lot for your help- i got everything working like I wanted. joelc 08-06-2003, 12:53 PM Just to satisfy morbid curiosity, what will your script do if they click 'yes'? juicelooser 08-06-2003, 09:27 PM It's just an automatic shutdown. The user can cancel if they want to keep using it. Sepero 08-09-2003, 05:21 AM I was wonder why I couldn't apt-get xmessage. For all my Debian brothers and sisters out there, it's gmessage. justlinux.com
Copyright Internet.com Inc. All Rights Reserved. |