Hi, I have a working (windows application) uniface-test, and now trying to divide this up into re-usable parts (units). So 1 of the first things I need to do is open the application and pass it on from one unit to another. When I run tis I get the following message: "Unable to find the object MDIClient. See Details for additional information"
Anyone an idea what is going wrong here?
Here are my 3 units:
Unit 1 = start unit:
var unitTZISAPP = require("TZISAPP");
var unitTZISAPP_LOGON = require("TZISAPP_LOGON");
let TZisApp = unitTZISAPP.letZisApp();
let returnvalue = unitTZISAPP_LOGON.TZisAppLogOn(TZisApp);
Unit 2 called TZISAPP:
module.exports.letZisApp = letTZISAPP;
Unit 3 called TZISAPP_LOGON:
module.exports.TZisAppLogOn = TZISAPPLogOn;
let wndUniMDIFormLogOn = TZisApp.MDIClient.wndUniMDIForm; => ERROR ON THIS LINE
let uViewPortLogOn = wndUniMDIFormLogOn.uviewport;
what are you supplying as the argument for the function in your unit3 (so what are you passing for the parameter TZisApp)
let wndUniMDIFormLogOn = TZisApp.MDIClient.wndUniMDIForm;
if TZisApp is the name of your testedapplication, why do you need the argument within your function?
the Variable of TZisApp that you set in the other units dont seem to be global (so they are within the scope of the separate units only; i dont know enough about the syntax of the language you are using to give you suggestions on how to do this, but a google search should yield results here "how to make global variable in x language")