Hello As I had commented on an earlier similar post, I had the same issue and this is how I fixed it. Following these steps, you don't have to launch fluent from command prompt!
Install Visual Studio 2017 Community Edition with C++ options (ANSYS 2019 doesn't support newer versions of VS such as MSVS 2019)
Go to Control Panel -> System and Security -> System -> Advanced System Settings -> Environment Variables
Go to the bottom section named 'System variables' and then double-click to open "Path"
There, create 4 new entries (mentioned below as steps 5, 6, 7, 8) by clicking on 'New':
C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.16.27023\bin\Hostx64\x64 (This is the location for "nmake" in MSVS 2017 Community Edition)
:\\ANSYS Inc\v194\fluent\ntbin\win64 (This is for ANSYS 2019, your version number will change according to the one you have installed)
Make sure that the entries in steps 5 - 8 are at the top most rows of the path variables, i.e., entry 5 should be in row 1, entry 6 should be in row 2, entry 7 should be in row 3, and entry 8 should be in row 4. You can change their row positions using "Move Up" option in the system variables dialog box
Click OK and exit out of the Path variables dialog box, as well as exit out of the Environment variables dialog box and System properties dialog box
Restart system
Start FLUENT. In the FLUENT Launcher, click on 'Show More Options'
Make sure that the working directory location is the location of your folder containing your UDF and then click OK to launch FLUENT
Now you will be able to build and load your UDFs.
Hope this will also help in your issue.