<span>AFAIK the writeline function ignores endlines and writes out the string as a single line. Easy solution - call the function once for each line. could store your output matrix as an array of strings or write a func that splits up a string by newline and outputs each line separately. Im no GME expert though, could be a better way to do it</span> <br>
<br><div class="gmail_quote">On Thu, Mar 22, 2012 at 2:09 PM, Jonathan Sprinkle <span dir="ltr"><<a href="mailto:sprinkle@ece.arizona.edu" target="_blank">sprinkle@ece.arizona.edu</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi all,<br>
<br>
My question certainly displays some naiveté, so I apologize in advance. :) I want to generate output in the console that a user can paste into another program without having to open a file. For example, the output should appear as<br>
<br>
matrix = [ 1 1 1; …<br>
2 2 2; …<br>
3 3 3; …<br>
];<br>
<br>
However, if I generate this matrix as an std::string, it shows correctly when generated to a file, but the output in the console is<br>
<br>
matrix = [ 1 1 1; … 2 2 2; … 3 3 3; … ];<br>
<br>
Which will not work in the other program (MATLAB, of course). I also tried this:<br>
<br>
CString str;<br>
str.Format( "Test 1 \n Test 2" );<br>
GMEConsole::Console::Out::WriteLine( str );<br>
<br>
But this shows as<br>
<br>
Test 1 Test 2<br>
<br>
So, any advice? :) For now it is easy to work around, by not allowing copy out of the console, but if I'm just doing something really stupid (or is there is a checkbox I need to enter somewhere) I am much obliged.<br>
<br>
Cheers,<br>
Jonathan<br>
<br>
_______________________________________________<br>
gme-users mailing list<br>
<a href="mailto:gme-users@list.isis.vanderbilt.edu" target="_blank">gme-users@list.isis.vanderbilt.edu</a><br>
<a href="http://list.isis.vanderbilt.edu/mailman/listinfo/gme-users" target="_blank">http://list.isis.vanderbilt.edu/mailman/listinfo/gme-users</a><br>
</blockquote></div><br>