ProcessBuilder-无法执行conda命令

当我在命令行中运行以下命令时,我没有遇到任何问题,环境更改为jaydev

conda activate jaydev my command line after this looks something like this (jaydev) C:\Users\jay dev>

(我在Windows命令行而不是anaconda提示符下编写此命令,我已经进行了必要的配置)

但是,当我使用流程生成器并尝试执行相同的命令时,它不会执行该问题,如下所示。

ProcessBuilder pb = new ProcessBuilder("conda", "activate", "jaydev");]
Process p = pb.start();

错误-

    java.io.IOException: Cannot run program "conda": CreateProcess error=2, The system cannot find the file specified
    at java.lang.ProcessBuilder.start(ProcessBuilder.java:1048)
    at test.Test.main(Test.java:23)
Caused by: java.io.IOException: CreateProcess error=2, The system cannot find the file specified
    at java.lang.ProcessImpl.create(Native Method)
    at java.lang.ProcessImpl.<init>(ProcessImpl.java:386)
    at java.lang.ProcessImpl.start(ProcessImpl.java:137)
    at java.lang.ProcessBuilder.start(ProcessBuilder.java:1029)
    ... 1 more

任何帮助将不胜感激