Jump to content
Ketarin forum

Echoing the HTML/Regex captured to a text file


Omniferum
 Share

Recommended Posts

Does anybody know of a way to echo the captured regex to a text file? The problem is more line breaks I believe.

 

Trying to do further parsing of regex captures for post-processing commands. It is more "Here is a list of what we found if an error was found" type stuff.

 

A basic echo "{variable}" doesn't work as for each line break it treats it as a new command even though there isn't anything in the regex other than : and text. Tried using powershell via batch not with much success. Escaping { code blocks etc. etc.

 

Anybody got a solution/suggestion?

Link to comment
Share on other sites

Batch won't work, since it's unescaped data. You'd have to pass it thru an escaping process to ensure that it's capable of being passed on a command line, and even then, if the length of the string + the full path to the current working directory exceeds 248 characters you get very inconsistent results. You'll be better off using an alternative method, such as C# to database, or storing the data itself as another variable within the app profile (and checking it out via an export of the app profile OR by directly thru db manipulation).

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.