Skip to main content
Jan 30, 2023 3:30 PM UTC
Solved

Windchill find out Installation directory through API

How do I get windchill installation directory / load point location though API.

I see almost every article related to this but no luck.

Please suggest or guide. 

 

 

 

 

Jan 30, 2023 3:53 PM UTC

Hello @KU_9572760 

 

At the beginning of your class:

 

public class TEHUtils {

 

static String wthome;

static {
    try {
             WTProperties wtProps = WTProperties.getLocalProperties();

             String wthome = wtProps.getProperty("wt.home", "c:/tmp");
      } catch (Throwable t) {
                 t.printStackTrace(System.err);
                throw new ExceptionInInitializerError(t);
      }
}

..

 

 

BR,

Pascal

 

2 replies

Jan 30, 2023 3:53 PM UTC

Hello @KU_9572760 

 

At the beginning of your class:

 

public class TEHUtils {

 

static String wthome;

static {
    try {
             WTProperties wtProps = WTProperties.getLocalProperties();

             String wthome = wtProps.getProperty("wt.home", "c:/tmp");
      } catch (Throwable t) {
                 t.printStackTrace(System.err);
                throw new ExceptionInInitializerError(t);
      }
}

..

 

 

BR,

Pascal

 

Jan 30, 2023 4:05 PM UTC

Hi Pascal,

your earlier solution also worked.

 

Big Thanks,