void main()
{
//This uses the dm consol command dm_setvarstring
//To set the name of an NPC,item,placeable.
//Access this by ##dm_setvarstring sName "What you want as the name"
//Then use the item on the object you desire, If you want the generic name
//Simply reuse the item on the specified object without setting sName again.

object oObject;
string sName;
oObject = GetItemActivatedTarget();
sName = GetLocalString(oObject,"sName");
SetName(oObject,sName);

SetLocalString(oObject,sName,"");

}