Skip to main content
May 15, 2020 5:50 AM UTC
Solved

how to print output on Terminal instead of MethodServer from Java class?

HI, I am executing a java class from terminal in windchill environment. If I use System.out.println("Print this "); method , output gets printed in methodserver log file. I want this output to be printed on Terminal from which I executed my java file. How any I achieve this?

May 15, 2020 5:55 AM UTC
public static void printMessageToConsole(String message) {
MethodContext methodContext = MethodContext.getContext();
methodContext.sendFeedback(new StatusFeedback(message));
}

6 replies

May 15, 2020 5:55 AM UTC
public static void printMessageToConsole(String message) {
MethodContext methodContext = MethodContext.getContext();
methodContext.sendFeedback(new StatusFeedback(message));
}
May 15, 2020 6:11 AM UTC

Thank you @BjoernRueegg  This is working.