G4C - Paths

;Path Finder for NetBar v6.0
;Kevin Anderson   andersok@mail.bogo.co.uk  {using Gui4Cli by D.Keletsekis}

;This Gui gets the paths of the users Net Apps and saves them to variables 
;in the ENV: drawer as well as copies them to ENVARC: so they are loaded 
;each time.

WinBig 50 20 380 273 'Net Application Paths'
WinType 01010001
WinFont Times.font 11 000

;On loading read the ENV variables (if exist) and update Text boxes

xOnLoad
UpDate Paths 1 $.W.NetBar
UpDate Paths 2 $.M.NetBar
UpDate Paths 3 $.N.NetBar
UpDate Paths 4 $.F.NetBar
UpDate Paths 5 $.I.NetBar
UpDate Paths 6 $.T.NetBar
UpDate Paths 7 $.P.NetBar

BOX 0 0 380 273 IN RIDGE

Text 20 5 350 20 ' Press the Get Button to find and set up your Net Applications etc' 80 NOBOX
GadFont Times.font 13 010


;Layout Path Settings Text boxes and Get buttons

Text 9 30 10 20 'WWW:' 10 NOBOX   ;Text label
GadFont Times.font 13 010
xTextIn 50 30 300 20 '' .W.NetBar 'WWW Client' 100         ;TextIn box
GadID 1                                     ;Give TextIn box a GadID for remote reference

xButton 355 30 20 20 'Get'                  ;Button on press launch file requester
ReqFile 10 10 100 300 'Choose your WWW Client' LOAD .W.NetBar ''  ;Write ENV variable
UpDate Paths 1 $.W.NetBar                   ;Update Text box with ENV variable

Text 7 60 10 20 'E-Mail:' 10 NOBOX   
GadFont Times.font 13 010
xTextIn 50 60 300 20 '' .M.NetBar 'E-Mail Client' 100    
GadID 2     ;
xButton 355 60 20 20 'Get'    
ReqFile 10 10 100 300 'Choose your E-Mail Client' LOAD .M.NetBar ''  
UpDate Paths 2 $.M.NetBar  

Text 14 90 10 20 'News:' 10 NOBOX
GadFont Times.font 13 010
xTextIn 50 90 300 20 '' .N.NetBar 'News Reader' 100    
GadID 3
xButton 355 90 20 20 'Get'
ReqFile 10 10 100 300 'Choose your News Reader' LOAD .N.NetBar ''
UpDate Paths 3 $.N.NetBar

Text 21 120 10 20 'FTP:' 10 NOBOX
GadFont Times.font 13 010
xTextIn 50 120 300 20 '' .F.NetBar 'FTP Client' 100   
GadID 4
xButton 355 120 20 20 'Get'
ReqFile 10 10 100 300 'Choose your FTP Client' LOAD .F.NetBar ''
UpDate Paths 4 $.F.NetBar

Text 22 150 10 20 'IRC:' 10 NOBOX
GadFont Times.font 13 010
xTextIn 50 150 300 20 '' .I.NetBar 'IRC Client' 100   
GadID 5
xButton 355 150 20 20 'Get'
ReqFile 10 10 100 300 'Choose your IRC Client' LOAD .I.NetBar ''
UpDate Paths 5 $.I.NetBar

Text 13 180 10 20 'Telnet:' 10 NOBOX
GadFont Times.font 13 010
xTextIn 50 180 300 20 '' .T.NetBar 'Telnet Client' 100
GadID 6
xButton 355 180 20 20 'Get'
ReqFile 10 10 100 300 'Choose your Telnet Client' LOAD .T.NetBar ''
UpDate Paths 6 $.T.NetBar

Text 21 210 10 20 'Ping:' 10 NOBOX
GadFont Times.font 13 010
xTextIn 50 210 300 20 '' .P.NetBar 'Ping' 100
GadID 7
xButton 355 210 20 20 'Get'
ReqFile 10 10 100 300 'Choose your Ping Client' LOAD .P.NetBar ''
UpDate Paths 7 $.P.NetBar

;Save button to save ENV variables for paths etc and copy to ENVARC

xButton 180 240 60 20 '_Save'
GadFont Times.font 15 010
CLI 'Copy ENV:??.NetBar ENVARC: >NIL:' 
GuiClose Paths

xOnClose
GuiClose Paths  ;Best to be safe than sorry


RESIZE_BIG 0 0 652 256 Paths

RESIZE_SMALL 0 0 547 236 Paths
