00001
00002
00003
00004
00005 #include "TCL_Global.h"
00006 #include "setenvtcl.h"
00007
00008 int setenvtcl(char *string,char *value)
00009 {
00010 int bOK=FALSE;
00011 char MyTclCommand[2048];
00012
00013 sprintf(MyTclCommand,"env(%s)",string);
00014
00015 if (TCLinterp==NULL) return((int)FALSE);
00016
00017 if ( !Tcl_SetVar(TCLinterp,MyTclCommand, value, TCL_GLOBAL_ONLY) )
00018 {
00019 bOK=(int)(FALSE);
00020 }
00021 else
00022 {
00023 bOK=(int)(TRUE);
00024 }
00025
00026 return bOK;
00027 }
00028