Skip to content

Instantly share code, notes, and snippets.

@jmhmd
Created March 10, 2016 15:49
Show Gist options
  • Save jmhmd/4f95627a753f38936ab3 to your computer and use it in GitHub Desktop.
Save jmhmd/4f95627a753f38936ab3 to your computer and use it in GitHub Desktop.
#! _trigger=100 _bitmap=-1 _states=1 _top_toolbar
put_info version "1.0.0.1";
set username [get_info username]
set acc [get_info "study_accession_number" [get_studies selected] ]
set prog_to_launch3 "C:\\Program Files\\Internet Explorer\\IEXPLORE.EXE"
set prog_to_launch2 "C:\\Program Files (x86)\\Google\\Chrome\\Application\\chrome.exe"
set prog_to_launch1 "C:\\Documents and Settings\\RAD\\Local Settings\\Application Data\\Google\\Chrome\\Application\\chrome.exe"
set url_string "http://jhdev1.radiology.umm.edu/query/accession/$acc/?u=$username"
if { [file exists $prog_to_launch1] == 1 } {
exec -- $prog_to_launch1 $url_string &
} elseif { [file exists $prog_to_launch2] == 1 } {
exec -- $prog_to_launch2 $url_string &
} else {
exec -- $prog_to_launch3 $url_string &
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment