Quantcast
Channel: Forums - Recent Threads
Viewing all articles
Browse latest Browse all 143529

Change label of a table's field

$
0
0

Hi,

I want to change the label of  a table field. i am getting an error while executing the following code

public static void main(Args _args)
{
#Properties
#AOT
#DictField

CMAAttribPrioritySetup aps;
TreeNode treeTable1;
SysDictField df;
FieldId fieldId;
df = new SysDictField(tableNum(CMAAttribCombination),fieldNum(CMAAttribCombination,AttribStringValue1 ));
select firstonly aps
where aps.AttribFieldId == df.id();

treeTable1 = df.treeNode();

treeTable1.AOTsetProperty(#PropertyLabel, "Labelone");
str labelname = treeTable1.AOTgetProperty(#PropertyLabel);
info(labelname);
treeTable1.AOTsave();

}

the line of code marked is throwing an error.

Error is : 

Microsoft.Dynamics.Ax.Xpp.ErrorException was unhandled by user code
Message: An exception of type 'Microsoft.Dynamics.Ax.Xpp.ErrorException' occurred in aoskernel.dll but was not handled in user code
Additional information: Unable to extract node content to disk. The file '%1' is read-only.

Thanks in advance.

Anand


Viewing all articles
Browse latest Browse all 143529

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>