BAD_PARAM/201. vmcid: SUN minor code: 201

When i am trying to execute the code of CORBA

"BAD_PARAM/201. vmcid: SUN minor code: 201 " exception comes. The flow of code and function calls are as follows.

//-Change of Static IP code starts

MOData[] mo;

mo=new MOData[1];

mo[0]=new MOData();

mo[0].identity=idn;

mo[0].attributes=new NameValue[1];

mo[0].attributes[0]=new NameValue();

mo[0].attributes[0].name="MultipleStaticIp";

mo[0].attributes[0].value=orb.create_any();

mo[0].attributes[0].value.insert_string("10.10.10.100");

String test = setUserProfile(ss,makeIdentity(moData1.identity),list[2].identity,new String[]{"Services"},new Object[]{mo});

System.out.println("Result of Profile "+test1);

System.out.println("Result of service "+test1);

//--Change of Static IP code ends--

**

* Assignes a profile to a user.

* @param session the Session obtained at login

* @param identity the User MO Identity

* @param assocIdentity the Profile MO Identity

* @param attrName association attribute names

* @param attrValue association attribute values

* @return the status of the operation

* @throws OperationException

*/

public String setUserProfile(Session session, MOIdentityHolder identity, NameValue[] assocIdentity,

String[] attrName, Object[] attrValue)

throws OperationException

{

MOAttributeSetHolder moAttributesHolder = this.makeAttributes(null,null);

StringHolder status =new StringHolder();

MOData[] assocList;

if (assocIdentity !=null)

{

assocList =new MOData[1];

assocList[0] =new MOData();

assocList[0].identity = makeIdentity(assocIdentity).value;

assocList[0].attributes = this.makeAttributes(attrName,attrValue).value;

}

else

assocList =new MOData[0];

int res = nmsSm.set_user_profile(session, identity, assocList, moAttributesHolder, status);

if (res != 0)

return status.value;

else

return"OK";

}

**

* Creates a holderfor MO attributes.

* @param attrName a set of attribute names

* @param attrValue a set of attributes values

* @return the created holder

*/

protected MOAttributeSetHolder makeAttributes(String[] attrName, Object[] attrValue)

{

MOAttributeSetHolder moAttributesHolder =new MOAttributeSetHolder();

if (attrName ==null)

{

moAttributesHolder.value =new NameValue[0];

return moAttributesHolder;

}

Vector v =new Vector();

for (int i = 0; i < attrName.length; i++)

{

if (attrValue[i] ==null)

continue;

NameValue nv =new NameValue();

nv.name = attrName[i];

nv.value = orb.create_any();

if (attrValue[i]instanceof String)

nv.value.insert_string((String)attrValue[i]);

elseif (attrValue[i]instanceof Integer)

nv.value.insert_long(((Integer)attrValue[i]).intValue());

elseif (attrValue[i]instanceof Boolean)

nv.value.insert_boolean(((Boolean)attrValue[i]).booleanValue());

elseif (attrValue[i]instanceof NameValue[][])

MOIdentitySetHelper.insert(nv.value, (NameValue[][])attrValue[i]);

elseif (attrValue[i]instanceof MOData[])

MODataSetHelper.insert(nv.value, (MOData[])attrValue[i]);

elseif (attrValue[i]instanceof MOData)

MODataHelper.insert(nv.value, (MOData)attrValue[i]);

v.add(nv);

}

moAttributesHolder.value = (NameValue[])v.toArray(new NameValue[0]);

return moAttributesHolder;

}

The exception comes as follows

org.omg.CORBA.BAD_PARAM. vmcid: SUN minor code: 201 completed: maybe

Please help me out how to pass the parameter.....

[6269 byte] By [S_Chantia] at [2007-11-27 9:23:54]
# 1
Try the RMI forum.
ejpa at 2007-7-12 22:19:27 > top of Java-index,Core,Core APIs...