stripANSI with regex - WeOnlyDo Discussion board

stripANSI with regex (wodSSH / wodSSH.NET)

by Eric, Monday, December 10, 2007, 15:02 (6194 days ago)

I need to use the stripANSI to get my program to work properly but now my screen is missing any formatting. Is there a way to perform the same function in a Visual Basic subroutine that would allow me to check for certain positioning sequences and replace with spaces. This would be great as then I would be able to format what gets diplayed in a descent format.

I am using the COM object in blocking mode. When I use the ActiveX object everything looks great.

Re: stripANSI with regex

by woddrazen, Monday, December 10, 2007, 15:59 (6194 days ago) @ Eric

Eric,


Maybe VB6 Replace Function will help you.

Here is example:
[code]
Dim a As String

a = this is@@@@test message
Debug.Print Replace(a, @@@@ , )[/code]

Hope this helps.


Drazen

Re: stripANSI with regex

by Eric, Monday, December 10, 2007, 16:13 (6194 days ago) @ woddrazen

Yes this helps.

Regards,
Eric