Any ideas?
Brian
Cameron Laird <Cam...@Lairds.com>
Business: http://www.Phaseit.net
Personal: http://starbase.neosoft.com/~claird/home.html
Use [dde] to check if the app is already running, and send it a message
to pop itself up if it is.
The following script is a basic skeleton:
package require dde
# Establish the DDE topic
set topicName MyTopic
# See if a service with our topic is already running. If so,
# delegate to it.
set otherServices [dde services TclEval $topicName]
if { [llength $otherServices] > 0 } {
dde execute TclEval $topicName {
wm deiconify .
raise .
bell
}
exit
}
# Launch the service
dde servername $topicName
grid [label .l -text [list $topicName is running]]
grid [button .q -text Quit -command exit]
--
73 de ke9tv/2, Kevin KENNY GE Corporate R&D, Niskayuna, New York, USA