Running QAD mfg/pro program using mbpro, do I need mf.p to run in the script?

I'm trying to run a QAD mfg/pro (running on Progress 10.1) program using mbpro command. I've provided the database, Propath and other startup parameters to my shell script. When I run the script, mbpro runs the .r program. But issue I'm facing is when my program runs through mbpro, it can't find variables like global_db etc. I get the error in my errorlog file as:

Shared variable global_user_lang_dir has not yet been created. (392)
When I run the same program from mfg/pro menu, it runs without issue. Which makes me think that the environment is not loaded with all the information. Do I need to run mf.p along with mbpro to load all environment variables? My script file is as follows:
exec $DLC/bin/mbpro \
-p xxtestprogram.r\
-d mdy -yy 1990 -Bt 350 -c 30 -D 100 -mmax 3000 -nb 200 -s 3500 \
> errorfile.err
Last edited: