Kashub's Code Barn - "wc3270"

podświetlone jako oracle8 (dodał(a) ja @ 2020-03-05 10:48:35)

Twoja wyszukiwarka
Parcel ABC
Podświetl ten kod w:
Ostatnio dodane:
Losowe wpisy:
  PRIVATE void createSessionWC3270(String sessionParms){
 
        ProcessBuilder p = NEW ProcessBuilder();
        FILE tempFile = NEW FILE("C:\\Program Files\\wc3270\\");
        SYSTEM.OUT.println("1: " + tempFile.getAbsolutePath());
        IF (tempFile.EXISTS()){
            Thread openConsoleT = NEW Thread(NEW Runnable() {
                @Override
                PUBLIC void run() {
                    try {
                        SYSTEM.OUT.println("powershell \"& '" + "start cmd.exe /C \"C:\\Program Files\\wc3270\\wc3270.exe\" " + sessionParms +  "'\"");
                        Process p = Runtime.getRuntime().EXEC("powershell \"& '" + "C:\\Program Files\\wc3270\\wc3270.exe " + sessionParms +  "'\"");
                    } catch (IOException e) {
                        e.printStackTrace();
                    }
                }
            });
            openConsoleT.START();
        }ELSE{
            tempFile = NEW FILE(("C:\\Program Files (x86)\\IBM\\wc3270\\"));
            IF (tempFile.EXISTS()){
                Thread openConsoleT = NEW Thread(NEW Runnable() {
                    @Override
                    PUBLIC void run() {
                        try {
                            SYSTEM.OUT.println("powershell \"& '" + "C:\\Program Files (x86)\\wc3270\\wc3270.exe " + sessionParms +  "'\"");
                            Process p = Runtime.getRuntime().EXEC("powershell \"& '" + "C:\\Program Files (x86)\\wc3270\\wc3270.exe " + sessionParms +  "'\"");
                        } catch (IOException e) {
                            e.printStackTrace();
                        }
                    }
                });
                openConsoleT.START();
            }
 
        }
       // Process p = Runtime.getRuntime().EXEC("powershell \"& '" + "wc3270.exe" + sessionParms +  "'\"");
 
 
    }
| Sklepy internetowe | | Sklep z artykułami dla dzieci | | Opony letnie | | Sklep z artykułami RTV/AGD | | Programista Trójmiasto | | Skróć link | | Załóż za darmo bloga | | Kody programów | | Wklejacz kodów |