From: Andrew M. <And...@ar...> - 2009-08-27 09:19:14
|
This is probably a basic question, in which case sorry. I have spent some time looking through the documentation and doing web-searches, but have not managed to work out where I am going wrong. I am trying to find something that can parse XML output from the UCBerkeley open source structural analysis package OpenSees. It uses a Tcl interpreter, so when I came across TclXML, I thought that this would be ideal. However, I am getting a "can't find package" error, which suggests that it can't find TclXML. I am running Windows XP I have downloaded and installed ActiveState ActiveTcl 8.5.4.0 It was not clear to me whether TclXML is included in ActiveTcl (and I wasn't sure how to add it if it isn't) I was taking a look at the documentation, and I came upon the following example in the documentation (which gave me hope that TclXML *is* included): ========================== package require xml proc EStart {varName name attlist args} { upvar #0 $varName var incr var } set count 0 set parser [::xml::parser -elementstartcommand [list EStart count]] $parser parse [read stdin] puts "The XML document contains $count elements" ========================== I pasted the lines into a file that I called "XML-count-elements.tcl" and I put an XML file called DFree.xml into the same directory. I thought I could test it out using the following command line: D:\OpenSees\XML> type DFree.xml | tclsh85 XML-count-elements.tcl can't find package xml while executing "package require xml" (file "XML-count-elements.tcl" line 1) The process tried to write to a nonexistent pipe. This suggests to me that TclXML is *not* included. If so, it would be nice if this were stated in the documentation. I therefore downloaded the package "tclxml-3.2.zip" from the website and placed the files in the "C:\Tcl\lib" directory. However, this has not solved my problem. Have I put them in the wrong place, or does this mean that some compilation is required? This would be a show-stopper as I do not have one and there would be problems in trying to get one. Any advice? Thanks, Andrew ____________________________________________________________ Electronic mail messages entering and leaving Arup business systems are scanned for acceptability of content and viruses |
From: Andreas K. <and...@ac...> - 2009-08-27 17:02:24
|
Andrew Mole wrote: > This is probably a basic question, in which case sorry. I have spent > some time looking through the documentation and doing web-searches, but > have not managed to work out where I am going wrong. In general, we (ActiveState) trimmed ActiveTcl 8.5 down relative to ActiveTcl 8.4. For AT 8.5. only the most important packages are still distributed with the ActiveTcl archive itself. The other packages are not lost however. They can be installed from the TEApot repository using the 'teacup' client application. For the documentation, see http://docs.activestate.com/activetcl/8.5/at.pkg_index.html and the big link 'TEApot Package Management' you can see on this page. teacup itself is documented under http://docs.activestate.com/activetcl/8.5/tpm/tpm/files/CTP_teacup.html reachable from the index page. It also has command line help, invokable with % teacup help Now, in the specific case of the TclXML packages, the main package is 'xml'. To work it however needs a series of other packages. Per the package index of 'xml' you need either xml::tcl xmldefs xml::tclparser or xml::c xmldefs xml::tclparser xml::expat (optional) The first set is for a pure Tcl solution, the second set has C components. Which are faster. > This suggests to me that TclXML is *not* included. If so, it would be > nice if this were stated in the documentation. Andreas |
From: Steve B. <Ste...@ex...> - 2009-08-27 22:59:21
|
ActiveState currently distribute TclXML v2.6. This version is pretty old now. When is ActiveState going to make v3.2 (or v3.3 when I get it released) available? Cheers, Steve Ball On 28/08/2009, at 3:00 AM, Andreas Kupries wrote: > Andrew Mole wrote: >> This is probably a basic question, in which case sorry. I have spent >> some time looking through the documentation and doing web-searches, >> but >> have not managed to work out where I am going wrong. > > In general, we (ActiveState) trimmed ActiveTcl 8.5 down relative to > ActiveTcl > 8.4. For AT 8.5. only the most important packages are still > distributed with > the ActiveTcl archive itself. > > The other packages are not lost however. They can be installed from > the TEApot > repository using the 'teacup' client application. > > For the documentation, see > > http://docs.activestate.com/activetcl/8.5/at.pkg_index.html > > and the big link 'TEApot Package Management' you can see on this page. > > teacup itself is documented under > > http://docs.activestate.com/activetcl/8.5/tpm/tpm/files/CTP_teacup.html > > reachable from the index page. It also has command line help, > invokable with > > % teacup help > > > Now, in the specific case of the TclXML packages, the main package > is 'xml'. To > work it however needs a series of other packages. Per the package > index of > 'xml' you need either > > xml::tcl > xmldefs > xml::tclparser > or > xml::c > xmldefs > xml::tclparser > xml::expat (optional) > > The first set is for a pure Tcl solution, the second set has C > components. > Which are faster. > > >> This suggests to me that TclXML is *not* included. If so, it would be >> nice if this were stated in the documentation. > > > Andreas > > ------------------------------------------------------------------------------ > Let Crystal Reports handle the reporting - Free Crystal Reports 2008 > 30-Day > trial. Simplify your report design, integration and deployment - and > focus on > what you do best, core application coding. Discover what's new with > Crystal Reports now. http://p.sf.net/sfu/bobj-july > _______________________________________________ > Tclxml-users mailing list > Tcl...@li... > https://lists.sourceforge.net/lists/listinfo/tclxml-users > |