Cyborg5000 Posted March 15 Share Posted March 15 Iam trying to capture an empty space/ string between two texts, but also want to add text to it. Reason for Impact: NA Recovery Action: NA Start Time (CST): 07-Mar-2023 02:02 AM End Time (CST): NAVendor Ticket: Notification: So between Vendor Ticket: and Notification if empty add NA Link to comment Share on other sites More sharing options...
TheXman Posted March 15 Share Posted March 15 (edited) <snip> Edited March 18 by TheXman CryptoNG UDF: Cryptography API: Next Genjq UDF: Powerful and Flexible JSON Processor | jqPlayground: An Interactive JSON ProcessorXml2Json UDF: Transform XML to JSON | HttpApi UDF: HTTP Server API | Roku Remote: Example ScriptAbout MeHow To Ask Good Questions On Technical And Scientific Forums (Detailed) | How to Ask Good Technical Questions (Brief)"Any fool can know. The point is to understand." -Albert Einstein Link to comment Share on other sites More sharing options...
ioa747 Posted March 15 Share Posted March 15 (edited) Local $Str = ClipGet() ConsoleWrite($str & @CRLF) $Str = StringReplace($Str, "Vendor Ticket:" & @CRLF & "Notification:", "Vendor Ticket:" & @CRLF & "NA" & @CRLF & "Notification:") ConsoleWrite($str & @CRLF) #cs Reason for Impact: NA Recovery Action: NA Start Time (CST): 07-Mar-2023 02:02 AM End Time (CST): NA Vendor Ticket: Notification: #CE Edited March 15 by ioa747 Link to comment Share on other sites More sharing options...
Cyborg5000 Posted March 15 Author Share Posted March 15 (edited) Thanks, but text may be available between Vendor Ticket: and Notification in further instances. Edited March 15 by Cyborg5000 Link to comment Share on other sites More sharing options...
ioa747 Posted March 15 Share Posted March 15 if it has text, it won't change it Link to comment Share on other sites More sharing options...
Cyborg5000 Posted March 15 Author Share Posted March 15 a small help? how can i use it in a loop of 1000 text files? Link to comment Share on other sites More sharing options...
ioa747 Posted March 15 Share Posted March 15 (edited) what is the source of the text? if it is a single text it will change all , no matter how much it is when it finds Vendor Ticket: Notification:it will change it with Vendor Ticket: NA Notification: Edited March 15 by ioa747 Link to comment Share on other sites More sharing options...
Cyborg5000 Posted March 15 Author Share Posted March 15 10 minutes ago, ioa747 said: what is the source of the text? text files Link to comment Share on other sites More sharing options...
Cyborg5000 Posted March 15 Author Share Posted March 15 @ioa747 Thanks a lot, was able to set it to a loop on the text file. Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now