I want to do the next thing:
String[] cmd = {"cmd","/c","c:\\Program Files (x86)\\Microsoft Office\\Office12\\WINWORD.exe","/mOpenPage","c:\\Navodilo.doc"};
Process proc = Runtime.getRuntime().exec(cmd);
But, without to specify the winword.exe path but open the document with the macro...
I read that there exist Auto Open macro, is it possible to specify input arguments for Auto Open macro?
SOLVED:
String[] cmd = {"cmd","/c","start","WINWORD.exe","/mOpenPage","c:\\Navodilo_za_uporabo_spletnega_servisa_wsEdp.doc"};
Process proc = Runtime.getRuntime().exec(cmd);
It runs default winword.exe and open word document with specified Macro