Bobby Jafari wrote:
I am writing to u as a last resort option for something that I think may be a bug with your module. I have a sample code bellow (The attached file needs to be copied to C:/Tcl/lib). Using the tclsh command will allow the execution of these tcl commands, but invoking them from Perl will give error.:Use Tcl; my $tclSession = new Tcl; $tclSession -> Eval ('cd C:/Tcl/lib'); # This works fine $tclSession -> call ("pkg_mkIndex", "C:/Tcl/lib", "*.tcl"); # TCL can't handle this
I believe you might call this a bug, as the standard case would want this anyways, but to properly initialize the new Tcl interp, you want to add '$tclSession->Init();' after the 'new Tcl'. This will fully enable the ::unknown mechanism and other tidbits beyond the "raw" Tcl interp you are otherwise provided.
That fixes the problem you see. Jeff
