Showing results for 
Search instead for 
Did you mean: 


Former Member
0 Kudos

what is Globalcontainer in XI

Accepted Solutions (0)

Answers (4)

Answers (4)

Former Member
0 Kudos


In a very Layman language ,Global Container as its name suggests ,A container that can store values which can be used in your all UDF's.

Let us understand it by an e.g. --> If we have 50 UDF's for a mapping.And all of them are using a constant which is decided by our client as say 11.and based on this constant our all UDF's process further.

In such a case its better to store this constant as Global Container which prevents you from defining this constant 5o times in all yor UDF's and further if client later decided to change this value to 12 then we need to change this value only in Global container at one place , not in all 50 UDF's.

It saves lot of time and efforts.This is one of practical Implementaion of Global Container

Thanks & Regards,

Anurag Garg

Former Member
0 Kudos


To know about global container check above links and to write the UDF check the code.

Getglobal container.

String gctmp;

GlobalContainer gc = container.getGlobalContainer();

gctmp = (String) gc.getParameter(globalContainer);

return gctmp;

Setglobal container.

GlobalContainer gc = container.getGlobalContainer();

gc.setParameter("controlNo", controlNo);

return controlNo;



Reward points if helpful

Active Contributor
0 Kudos


Global container is used in graphical mapping.This object enables you to cache the values that you want to read again when you next call any user-defined function that is in the same message mapping. Note that the sequence in which user-defined functions are called is predefined. It depends on the position of the target fields that the function was assigned to.

To get a global container object, call the getGlobalContainer() method for the Container Object.

There are times when we want to create many tags from just one source tag - imagine situation, when we get serial numbers as a range (from, to) and we have to create one tag for each serial number.

For example.. refer this link by Michale ...


Aashish Sinha

PS : reward points if helpful

Former Member
0 Kudos


This object enables you to cache the values that you want to read again when you next call any user-defined function in the same message mapping

Refer the below help and the code for the global container: