Hi All,
I have developed a class library project in Visual studio 2013 and have added to the AOT.
And also I have added the (classLibrary.dll) to the Reference node on ax AOT.
Now I am trying to run the app via a Job and I am getting an Error at an if condition as "Wrong Types of Comparision".
static void clrManagedCode(Args _args)
{
axUsersRolesLibrary.Class1 objClass1;
InteropPermission interopObj;
str userIdObj;
;
try
{
interopObj = new InteropPermission(InteropKind::DllInterop);
interopObj.assert();
objClass1 = new axUsersRolesLibrary.Class1();
userIdObj = 'ravi';
if(objClass1.getYourRole(userIdObj)==true)
{
info("You are an AX admin!!!!");
}
else
{
info("You are not an AX admin!!!!");
}
}
catch
{
error('CLR Exception caught !!!!');
}
}
I have highlighted the code where I got error.
My question can't I pass parameters from AX ?
Because that's an Boolean method in AX and return true or false based certain condition.
In visual studio the project is running fine.
Please help me to rectify the issue ?
*This post is locked for comments
I have the same question (0)