Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
out/string question
#1
Is it possible to get everything what macro prints through "out" command into one string?
#2
What purpose?

This code gets all text that currently is displayed in the output:
Code:
Copy      Help
str s
s.getwintext(id(2201 _hwndqm))
#3
When i was writing my macro i used out command to see how it`s working through writing process. Now when everything is ok i`d like to get those out messgs into one solid text that i can manipulate on (like msg it to user, paste in excel etc).
Otherwise I`d have to go through the code again and add new commands each time it "outs" sth, and then link it together. I thought there might be a way to just save some time on it.
#4
Thanks, works fine.

How to combine it into one line?
(since every "out" output is in the separate line)
#5
Code:
Copy      Help
s.findreplace("[]" "; ")
#6
Thank you.
#7
Or, use your own function for text output. For example, create function Out2 and paste this text:

Code:
Copy      Help
;/
function str's

g_out2+s
g_out2+"; "
out s

Then, in the macro, replace all out to Out2. At the beginning of the macro, insert this:

Code:
Copy      Help
str+ g_out2=""

When the macro ends, all its output will be in global variable g_out2.
#8
Yes, this is probably better, since you don`t have to set wintxt to clean macro output before running
Thanks again.


Forum Jump:


Users browsing this thread: 1 Guest(s)