58
Points
Questions
17
Answers
6
-
- 2210 views
- 3 answers
- 0 votes
-
- 1628 views
- 3 answers
- 0 votes
-
- 2373 views
- 3 answers
- 0 votes
-
Hi Ameansap,
Yes,we can read privileges using SDK ,Please Refer below piece of code :
IAdmin admin = session.getAdminInstance();
INode node = admin.getNode(“Privileges”);
System.out.println(node.getChildNodes());//get all privileges
INode node1 = (INode) node.getChild(“Create Customers”);//Specify name of your privilege
IProperty[] props = (IProperty[]) node1.getProperties();
for (int i = 0; i < props.length; i++)// loop to check properties of privileges
{
String propname= props[i].getName();
System.out.println(“Name : ” + propname);
Object value = props[i].getValue();
System.out.println(“Value : ” + value);}
This would help you to read privileges.Let me know if you have any queries.
Thanks,
Kalyani- 2027 views
- 3 answers
- 0 votes
-
Hi Brian F,
Please refer the below code to Disable an Event Subscriber via SDK
IAdmin admin = session.getAdminInstance();
INode node = admin.getNode(“EventSubscribers”);INode subnode = (INode) node.getChild(“test subscriber”);//Your event subscriber name
IProperty[] props = (IProperty[])subnode.getProperties();
for (int i = 0; i < props.length; i++)
{
String propname= props[i].getName();
System.out.println(“Name : ” + propname);
Object value = props[i].getValue();
System.out.println(“Value : ” + value);
if(propname.equalsIgnoreCase(“Enabled”))
{
props[i].setValue(“No”);
}
}
This would help you to disable subscriber .
let me know for any queries.Thanks,
Kalyani- 1968 views
- 2 answers
- 0 votes
-
In Java Client – Go to user’s Preference Tab->Set thumbnail as (ON).Next step go to classes from admin tab select the object on which you are adding thumbnail ->go to cover page -> set thumbnail as visible (yes)
Note that the object on which you adding thumbnail must have Read,Modify,Discovery priviledge.- 2244 views
- 4 answers
- 0 votes