# StartExtraDialog
# Gerald Banon, 1998

package provide dpi.inpe.br/banon/1998/08.02.08.56 2.1

# ----------------------------------------------------------------------

proc StartExtraDialog {t string {var1 {}} {var2 {}} {var3 {}}} {
# runs with start
	$t delete 1.0 end
	TextStyles $t
# --------------------
	if {$string == \
"host name not found"} {
		$t insert insert "\n\t"
		Insert $t insert {The host name has not be found.}
		$t insert insert "\n\n\t"
		Insert $t insert {Check if the TCP/IP Ethernet Card has been configurated.}
		$t insert insert "\n\n\t"
		Insert $t insert {The URLib local collection has not been posted.}
	}
## --------------------
#	if {$string == \
#"domain name not found"} {
#		$t insert insert "\n\t"
#		Insert $t insert {The domain name has not be found.}
#		$t insert insert "\n\n\t"
#		Insert $t insert {The current host is not connected to Internet or has no static IP.}
#		$t insert insert "\n\n\t"
#		Insert $t insert {The installation was not completed.}
#	}
# --------------------
	if {$string == \
"urlib.net site not found"} {
		$t insert insert "\n\t"
		Insert $t insert {The urlib.net site has not be found.}
		$t insert insert "\n\n\t"
		Insert $t insert {The computer is probably in standalone mode.}
		$t insert insert "\n\n\t"
		Insert $t insert {The installation was not completed.}
	}
# --------------------
	if {$string == \
"ip address not found"} {
		$t insert insert "\n\t"
		Insert $t insert {The ip address has not be found.}
		$t insert insert "\n\n\t"
		Insert $t insert {Check if the TCP/IP Ethernet Card has been configurated.}
		$t insert insert "\n\n\t"
		Insert $t insert {The URLib local collection has not been posted.}
	}
# --------------------
	if {$string == \
"access not completed"} {
		$t insert insert "\n\t"
		Insert $t insert {The communication with the URLib local collection server cannot be made.}
		$t insert insert "\n\n\t"
#		Insert $t insert {<$var1> was used as server name.} {} $var1
		Insert $t insert {<$var1> was used as IP.} {} $var1
		TagAdd $t fixed {<$var1>} -forward $var1
		$t insert insert "\n\t"
		Insert $t insert {<$var1> was used as URLib port.} {} $var2
		TagAdd $t fixed {<$var1>} -forward $var2
		$t insert insert "\n\n\t"
		Insert $t insert {The URLib local collection has not been posted.}
	}
# --------------------
	if {$string == \
"URLibService running"} {
		$t insert insert "\n\t"
		Insert $t insert {You are starting URLibService, but it has already been started.}
		$t insert insert "\n\n\t"
		Insert $t insert {For consistency reason, only one URLibService must be running at the same time.}
		TagAdd $t italic one
#		$t insert insert "\n\n\t"
#		Insert $t insert {Do you want continuing with this New Service?}
#		$t insert insert "\n\n\t"
#		Insert $t insert {(if URLibService is still running, you should answer No) }
#		$t insert insert "\n\t"
#		Insert $t insert \
{(if the previous run terminated abnormally, you may answer Yes) }
	}
# --------------------
	if {$string == \
"more than one local collection are posted"} {
		$t insert insert "\n\t"
		Insert $t insert {At the moment, stopping the servers is not allowed.}
		$t insert insert "\n\t"
		Insert $t insert {More than one local collection are posted.}
		$t insert insert "\n\n\t"
		Insert $t insert {The following ports are in use: $var1.} {} $var1
		TagAdd $t fixed {$var1} -forward $var1
	}
# --------------------
	if {$string == \
"unknown local collection or wrong registration key"} {
		$t insert insert "\n\t"
		Insert $t insert {The local collection is unknown or the registration key is wrong.}
		$t insert insert "\n\n\t"
		Insert $t insert {The installation was not completed.}
		$t insert insert "\n\n\t"
		Insert $t insert {Check if the local collection has been registered properly and run again the start command.}
	}
# --------------------
}
