"Regular Expression to Match Output" not working f
Moderators: AmigoJack, bbadmin, helios, MudGuard
"Regular Expression to Match Output" not working f
I want to use the XML parser "xmlwf" from James Clark. It works for me, but, the match output isn't working for me. When I click to the left of a problem line in my text output window, it just beeps at me. It doesn't take me to the line in the file. I've tried all of the examples in the TextPad documentation.
Thanks,
Peter
Thanks,
Peter
-
ben_josephs
- Posts: 2464
- Joined: Sun Mar 02, 2003 9:22 pm
Regular Expression to match output not working.
These two lines are what I get when I parse an XML file that I've purposely removed a portion of a closing element.
I:\DTR\XML>c:\sgml\xml\expat\bin\xmlwf.exe I:\DTR\XML\dtr80424.xml
I:\DTR\XML\dtr80424.xml:11:2: mismatched tag
The "mismatched tag" is shown, obviously. But, when I click on that line, it doesn't take me into the original file where the error is. That's what I want it to do.
Thanks.
I:\DTR\XML>c:\sgml\xml\expat\bin\xmlwf.exe I:\DTR\XML\dtr80424.xml
I:\DTR\XML\dtr80424.xml:11:2: mismatched tag
The "mismatched tag" is shown, obviously. But, when I click on that line, it doesn't take me into the original file where the error is. That's what I want it to do.
Thanks.
-
ben_josephs
- Posts: 2464
- Joined: Sun Mar 02, 2003 9:22 pm
-
ben_josephs
- Posts: 2464
- Joined: Sun Mar 02, 2003 9:22 pm
Regular Expression Finds
Thanks, Ben.
Sorry. I never got an e-mail that you'd responded here again. Yes, I always have POSIX turned on. Your regex works for me. Meaning, it does take me into the file where the "error" is. Now, it takes me to the wrong line entirely, though. For testing, I simply took out a close tag for a heading at the top of a file. When I parsed it and went to the error, it took me hundreds of lines down, to where the <document> ends at </document>. Is this normal?
Thanks a lot,
Peter
Sorry. I never got an e-mail that you'd responded here again. Yes, I always have POSIX turned on. Your regex works for me. Meaning, it does take me into the file where the "error" is. Now, it takes me to the wrong line entirely, though. For testing, I simply took out a close tag for a heading at the top of a file. When I parsed it and went to the error, it took me hundreds of lines down, to where the <document> ends at </document>. Is this normal?
Thanks a lot,
Peter
-
ben_josephs
- Posts: 2464
- Joined: Sun Mar 02, 2003 9:22 pm
Here's my output:
I:\DTR\XML>c:\sgml\xml\expat\bin\xmlwf.exe I:\DTR\XML\dtr80417.xml
I:\DTR\XML\dtr80417.xml:325:2: mismatched tag
For testing, I took out the end tag for a head. I removed a </head> on line 15. As you can see above, it recognizes an error, but, it takes me to line 325! Now, I'm not that familiar with this particular xml parser. I've just read on its web site that it's not a "validating" parser. Which might explain its uselesness here. I'm trying to find out from some of my colleagues if they know of any other good "validating" xml parsers for Windows command line use.
-Peter
I:\DTR\XML>c:\sgml\xml\expat\bin\xmlwf.exe I:\DTR\XML\dtr80417.xml
I:\DTR\XML\dtr80417.xml:325:2: mismatched tag
For testing, I took out the end tag for a head. I removed a </head> on line 15. As you can see above, it recognizes an error, but, it takes me to line 325! Now, I'm not that familiar with this particular xml parser. I've just read on its web site that it's not a "validating" parser. Which might explain its uselesness here. I'm trying to find out from some of my colleagues if they know of any other good "validating" xml parsers for Windows command line use.
-Peter
-
ben_josephs
- Posts: 2464
- Joined: Sun Mar 02, 2003 9:22 pm