To get unique group objects

How do get the unique directory groups in iFS?
We are able to get the users using the Java API but we dont find any method for getting the unique groups.
Does Java API in iFS provide that?
Anyone tried it, please respond.

Not sure what you mean by 'unique groups'.
If you want to find a specific group there are two alternatives (that I know):
* Use the DirectoryGroup API get its members,
traverse it looking for what you want
(starting at "WORLD").
* Use the search API
--jk
null

Similar Messages

  • Powershell - Select-Object -Unique vs Group-Object

    Hi,
    I have the following problem with powershell.
    I have a list of strings call it $machine_list which
    I know there are duplicates.
    The following  code produces the following output:
    $machine_list.count -- 15375
    $a = $machine_list | Select-Object -Unique
    $a.Count -- 12134
    $b = $machine_list | Group-Object -NoElement
    $b.Count -- 12082
    I am trying to get a unique list and looking at different
    ways of doing it.
    So in my example above why are the counts different?
    Should they not be the same - $a.Count -eq $b.Count?
    I am hoping somebody can explain this in more detail to me.
    Also is there a way I can compare the results to see how they
    differ? (Comparing $a with the Name Values of $b).
    Thanks,
    Ward.

    Dirk - another way to think this out.  "group" means that each named group has a unique name.  In a list of strings the group name and object are identical so the list of group names is the list of identical strings.
    Select -unique and sort -unique produce an identical set of lists.  Select -unique, however, does not necessarily produce a sorted output although the output is guaranteed to be unique.  What you may be mixing up is that many learned to add sort
    in PowerShell V1 because they did not get a sorted output from a unique operation.  As I posted above, this issue has come up constantly as people start to learn databases.  A company that I used to work for wrote its own 'uniquing' code.  It
    always produced a sorted output as a byproduct of the method.  When we implemented SQL database technology the programmers could not understand why select unique in SQL did not produce a sorted output.  They constantly complained that it was a bug.
    In most cases we would like a uniquing operation or not sort the results.  Suppose I have a result set order a specific way.  Now I want group it on a column but I do not want the order of the records changed.  Grouping and select unique should
    not change the order.  There are many discussions in the database field as to why this needs to be.  I am not sure which set of standards PS follows.  In PS1 it appeared to follow the industry standard.  Maybe I will test it later.
    ¯\_(ツ)_/¯

  • Error while creating MV replication group object

    Hi,
    I am getting error while creating replication group object. I tried to create using OEM and SQLPlus
    OEM error
    This error while creating M.V. rep. group object
    There is a table or view named SCOTT.EMP.
    It must be dropped before a materialized view can be created.
    In SQLPLUS
    SQL> CONNECT MVIEWADMIN/MVIEWADMIN@SWEET
    Connected.
    SQL>
    SQL> BEGIN
    2 DBMS_REPCAT.CREATE_MVIEW_REPOBJECT (
    3 gname => 'SCOTT',
    4 sname => 'KARTHIK',
    5 oname => 'emp_mv',
    6 type => 'SNAPSHOT',
    7 min_communication => TRUE);
    8 END;
    9 /
    BEGIN
    ERROR at line 1:
    ORA-23306: schema KARTHIK does not exist
    ORA-06512: at "SYS.DBMS_SYS_ERROR", line 86
    ORA-06512: at "SYS.DBMS_REPCAT_SNA_UTL", line 2840
    ORA-06512: at "SYS.DBMS_REPCAT_SNA_UTL", line 773
    ORA-06512: at "SYS.DBMS_REPCAT_SNA_UTL", line 5570
    ORA-06512: at "SYS.DBMS_REPCAT_SNA", line 82
    ORA-06512: at "SYS.DBMS_REPCAT", line 1332
    ORA-06512: at line 2
    Please not already I have created KARTHIK schema.

    Arthik,
    I think I know what may have happened.
    As I can see you are trying to create support for an updateable materialized view.
    You have to make sure the name of the schema that owns the materialized view is the same as the schema owner of the master table (at master site).
    From the code you have shown, I bet the owner of table EMP is SCOTT.
    From the other hand, you want to create materialized view EMP_MV under schema KARTHIK that refers to table SCOTT.EMP at master site.
    According to the documentation, the schema name used in DBMS_REPCAT.CREATE_MVIEW_REPOBJECT must be same as the schema that owns the master table.
    Please check the documentation at the link below
    http://download.oracle.com/docs/cd/B19306_01/server.102/b14227/rarrcatpac.htm#i109228
    I tried to reproduce your example in my environment, and I got exactly the same error which actually confirms my assumption that the reason for the error is the fact that you tried to create the materialized view in a schema with different name than the one where master table exists.
    I'll skip some of the steps that I used to create the replication environment.
    I have two databases, DB1.world and DB2.world
    On DB2.world I will generate replication support for table EMP which belongs to user SCOTT
    SQL> conn scott/*****@DB2.world
    Connected.
    SQL>create materialized view log on EMP with primary key;
    Materialized view log created.
    SQL>
    SQL>conn repadmin/*****@DB2.world
    Connected.
    SQL>BEGIN
      2       DBMS_REPCAT.CREATE_MASTER_REPGROUP(
      3         gname => 'GROUPA',
      4         qualifier => '',
      5         group_comment => '');
      6*   END;
    PL/SQL procedure successfully completed.
    SQL>BEGIN
      2       DBMS_REPCAT.CREATE_MASTER_REPOBJECT(
      3         gname => 'GROUPA',
      4         type => 'TABLE',
      5         oname => 'EMP',
      6         sname => 'SCOTT',
      7         copy_rows => TRUE,
      8         use_existing_object => TRUE);
      9*   END;
    10  /
    PL/SQL procedure successfully completed.
    SQL> BEGIN
      2       DBMS_REPCAT.GENERATE_REPLICATION_SUPPORT(
      3         sname => 'SCOTT',
      4         oname => 'EMP',
      5         type => 'TABLE',
      6         min_communication => TRUE);
      7    END;
      8  /
    PL/SQL procedure successfully completed.
    SQL>execute DBMS_REPCAT.RESUME_MASTER_ACTIVITY(gname => 'GROUPA');
    PL/SQL procedure successfully completed.
    SQL> select status from dba_repgroup;
    STATUS                                                                         
    NORMAL                                                                          Now let's create updateable materialized view at DB1. Before that I want to let you know that I created one sample in DB1 user named MYUSER. MVIEWADMIN is Materialized View administrator.
    SQL>conn mviewadmin/****@DB1.world
    Connected.
    SQL>   BEGIN
      2       DBMS_REFRESH.MAKE(
      3         name => 'MVIEWADMIN.MV_REFRESH_GROUPA',
      4         list => '',
      5         next_date => SYSDATE,
      6         interval => '/*1:Hr*/ sysdate + 1/24',
      7         push_deferred_rpc => TRUE,
      8         refresh_after_errors => TRUE,
      9         parallelism => 1);
    10    END;
    11  /
    PL/SQL procedure successfully completed.
    SQL>   BEGIN
      3       DBMS_REPCAT.CREATE_SNAPSHOT_REPGROUP(
      5         gname => 'GROUPA',
      7         master => 'DB2.wolrd',
      9         propagation_mode => 'ASYNCHRONOUS');
    11    END;
    12  /
    PL/SQL procedure successfully completed.
    SQL>conn myuser/*****@DB1.world
    Connected.
    SQL>CREATE MATERIALIZED VIEW MYUSER.EMP_MV
      2    REFRESH FAST
      3    FOR UPDATE
      4    AS SELECT EMPNO, ENAME, JOB, MGR, SAL, COMM, DEPTNO, HIREDATE
      5*      FROM   [email protected];
    Materialized view created.
    SQL>conn mviewadmin/******@DB1.world
    Connected.
    SQL> BEGIN
      2       DBMS_REFRESH.ADD(
      3         name => 'MVIEWADMIN.MV_REFRESH_GROUPA',
      4         list => 'MYUSER.EMP_MV',
      5         lax => TRUE);
      6    END;
      7  /
    PL/SQL procedure successfully completed.And now lets run CREATE_MVIEW_REPOBJECT.
    SQL>   BEGIN
      2       DBMS_REPCAT.CREATE_MVIEW_REPOBJECT(
      3         gname => 'GROUPA',
      4         sname => 'MYUSER',
      5         oname => 'EMP_MV',
      6         type => 'SNAPSHOT',
      7         min_communication => TRUE);
      8    END;
      9  /
      BEGIN
    ERROR at line 1:
    ORA-23306: schema MYUSER does not exist
    ORA-06512: at "SYS.DBMS_SYS_ERROR", line 86
    ORA-06512: at "SYS.DBMS_REPCAT_SNA_UTL", line 2840
    ORA-06512: at "SYS.DBMS_REPCAT_SNA_UTL", line 773
    ORA-06512: at "SYS.DBMS_REPCAT_SNA_UTL", line 5570
    ORA-06512: at "SYS.DBMS_REPCAT_SNA", line 82
    ORA-06512: at "SYS.DBMS_REPCAT", line 1332
    ORA-06512: at line 3 I reproduced exactly the same error message.
    So the problem is clearly in the schema name that owns the materialized view.
    Now lets see if what would happen if I create the MV under schema SCOTT which has the same name as the schema on DB2.world where the master table exists.
    SQL>conn scott/****@DB1.world
    Connected.
    SQL>CREATE MATERIALIZED VIEW SCOTT.EMP_MV
      2    REFRESH FAST
      3    FOR UPDATE
      4    AS SELECT EMPNO, ENAME, JOB, MGR, SAL, COMM, DEPTNO, HIREDATE
      5*      FROM   [email protected];
    Materialized view created.
    SQL>conn mviewadmin/******@DB1.world
    Connected.
    SQL> BEGIN
      2       DBMS_REFRESH.ADD(
      3         name => 'MVIEWADMIN.MV_REFRESH_GROUPA',
      4         list => 'SCOTT.EMP_MV',
      5         lax => TRUE);
      6    END;
      7  /
    PL/SQL procedure successfully completed.And now lets run CREATE_MVIEW_REPOBJECT.
    SQL>   BEGIN
      2       DBMS_REPCAT.CREATE_MVIEW_REPOBJECT(
      3         gname => 'GROUPA',
      4         sname => 'SCOTT',
      5         oname => 'EMP_MV',
      6         type => 'SNAPSHOT',
      7         min_communication => TRUE);
      8    END;
    PL/SQL procedure successfully completed.As you can see everything works fine when the name of the schema owner of the MV at DB1.world is the same as the schema owner of the master table at DB2.world .
    -- Mihajlo
    Message was edited by:
    tekicora

  • Get all Groups for current user

    Hi I try to get all groups for the current logged on user. This is what I do:
    First I try to search with the IGruopSearchFilter to obtain all unique Group IDs. I always get an proxy error by doing this, maybe the query is to much.
    Then I want to use the method group.isUserMember(user.getUniqueID() to check whether the user is a member of that group or not.
    Is there a better way to obtain all groups for a user (without using a query IGroupSearchFilter)?
    Thanks ahead for your help.
    Burkhardt

    Burkhadrt,
    have you tried this?
    https://media.sdn.sap.com/javadocs/preNW04/SP2/60_sp2_javadocs/ume/com/sap/security/api/IUser.html#getParentGroups(boolean)
    This should give you an iterator for all groups the given user is assigned to.
    Hope it helps... and if so:
    if (helpful) {
      points++
    Regards,
    Dominik

  • Not able to get group name by using memberof class, getting Total groups as 0 even I am member of that group.

    Not able to get group name by using memberof class, getting Total groups as 0 even I am member of that group. Through this memberof class I am trying to find full qualified name(DN) of my group.
    code I have used:
    //specify the LDAP search filter
                   String searchFilter = "(&(objectClass=user)(CN=Username))";
                   //Specify the Base for the search
                   String searchBase = "";
    Also I have used,
                 String searchFilter = "(&(objectClass=user)(CN=Username))";
                   //Specify the Base for the search
                   String searchBase = "ou=ibmgroups,o=ibm.com";
    But in both cases I am getting value for Total groups as 0.
    Code Reference:
    * memberof.java
    * December 2004
    * Sample JNDI application to determine what groups a user belongs to
    import java.util.Hashtable;
    import javax.naming.*;
    import javax.naming.ldap.*;
    import javax.naming.directory.*;
    public class memberof     {
         public static void main (String[] args)     {
              Hashtable env = new Hashtable();
              String adminName = "CN=Administrator,CN=Users,DC=ANTIPODES,DC=COM";
              String adminPassword = "XXXXXXX";
              String ldapURL = "ldap://mydc.antipodes.com:389";
              env.put(Context.INITIAL_CONTEXT_FACTORY,"com.sun.jndi.ldap.LdapCtxFactory");
              //set security credentials, note using simple cleartext authentication
              env.put(Context.SECURITY_AUTHENTICATION,"simple");
              env.put(Context.SECURITY_PRINCIPAL,adminName);
              env.put(Context.SECURITY_CREDENTIALS,adminPassword);
              //connect to my domain controller
              env.put(Context.PROVIDER_URL,ldapURL);
              try {
                   //Create the initial directory context
                   LdapContext ctx = new InitialLdapContext(env,null);
                   //Create the search controls          
                   SearchControls searchCtls = new SearchControls();
                   //Specify the search scope
                   searchCtls.setSearchScope(SearchControls.SUBTREE_SCOPE);
                   //specify the LDAP search filter
                   String searchFilter = "(&(objectClass=user)(CN=Andrew Anderson))";
                   //Specify the Base for the search
                   String searchBase = "DC=antipodes,DC=com";
                   //initialize counter to total the group members
                   int totalResults = 0;
                   //Specify the attributes to return
                   String returnedAtts[]={"memberOf"};
                   searchCtls.setReturningAttributes(returnedAtts);
                   //Search for objects using the filter
                   NamingEnumeration answer = ctx.search(searchBase, searchFilter, searchCtls);
                   //Loop through the search results
                   while (answer.hasMoreElements()) {
                        SearchResult sr = (SearchResult)answer.next();
                        System.out.println(">>>" + sr.getName());
                        //Print out the groups
                        Attributes attrs = sr.getAttributes();
                        if (attrs != null) {
                             try {
                                  for (NamingEnumeration ae = attrs.getAll();ae.hasMore();) {
                                       Attribute attr = (Attribute)ae.next();
                                       System.out.println("Attribute: " + attr.getID());
                                       for (NamingEnumeration e = attr.getAll();e.hasMore();totalResults++) {
                                            System.out.println(" " +  totalResults + ". " +  e.next());
                             catch (NamingException e)     {
                                  System.err.println("Problem listing membership: " + e);
                   System.out.println("Total groups: " + totalResults);
                   ctx.close();
              catch (NamingException e) {
                   System.err.println("Problem searching directory: " + e);
    Any help will be highly appreciated.

    Not able to get group name by using memberof class, getting Total groups as 0 even I am member of that group. Through this memberof class I am trying to find full qualified name(DN) of my group.
    code I have used:
    //specify the LDAP search filter
                   String searchFilter = "(&(objectClass=user)(CN=Username))";
                   //Specify the Base for the search
                   String searchBase = "";
    Also I have used,
                 String searchFilter = "(&(objectClass=user)(CN=Username))";
                   //Specify the Base for the search
                   String searchBase = "ou=ibmgroups,o=ibm.com";
    But in both cases I am getting value for Total groups as 0.
    Code Reference:
    * memberof.java
    * December 2004
    * Sample JNDI application to determine what groups a user belongs to
    import java.util.Hashtable;
    import javax.naming.*;
    import javax.naming.ldap.*;
    import javax.naming.directory.*;
    public class memberof     {
         public static void main (String[] args)     {
              Hashtable env = new Hashtable();
              String adminName = "CN=Administrator,CN=Users,DC=ANTIPODES,DC=COM";
              String adminPassword = "XXXXXXX";
              String ldapURL = "ldap://mydc.antipodes.com:389";
              env.put(Context.INITIAL_CONTEXT_FACTORY,"com.sun.jndi.ldap.LdapCtxFactory");
              //set security credentials, note using simple cleartext authentication
              env.put(Context.SECURITY_AUTHENTICATION,"simple");
              env.put(Context.SECURITY_PRINCIPAL,adminName);
              env.put(Context.SECURITY_CREDENTIALS,adminPassword);
              //connect to my domain controller
              env.put(Context.PROVIDER_URL,ldapURL);
              try {
                   //Create the initial directory context
                   LdapContext ctx = new InitialLdapContext(env,null);
                   //Create the search controls          
                   SearchControls searchCtls = new SearchControls();
                   //Specify the search scope
                   searchCtls.setSearchScope(SearchControls.SUBTREE_SCOPE);
                   //specify the LDAP search filter
                   String searchFilter = "(&(objectClass=user)(CN=Andrew Anderson))";
                   //Specify the Base for the search
                   String searchBase = "DC=antipodes,DC=com";
                   //initialize counter to total the group members
                   int totalResults = 0;
                   //Specify the attributes to return
                   String returnedAtts[]={"memberOf"};
                   searchCtls.setReturningAttributes(returnedAtts);
                   //Search for objects using the filter
                   NamingEnumeration answer = ctx.search(searchBase, searchFilter, searchCtls);
                   //Loop through the search results
                   while (answer.hasMoreElements()) {
                        SearchResult sr = (SearchResult)answer.next();
                        System.out.println(">>>" + sr.getName());
                        //Print out the groups
                        Attributes attrs = sr.getAttributes();
                        if (attrs != null) {
                             try {
                                  for (NamingEnumeration ae = attrs.getAll();ae.hasMore();) {
                                       Attribute attr = (Attribute)ae.next();
                                       System.out.println("Attribute: " + attr.getID());
                                       for (NamingEnumeration e = attr.getAll();e.hasMore();totalResults++) {
                                            System.out.println(" " +  totalResults + ". " +  e.next());
                             catch (NamingException e)     {
                                  System.err.println("Problem listing membership: " + e);
                   System.out.println("Total groups: " + totalResults);
                   ctx.close();
              catch (NamingException e) {
                   System.err.println("Problem searching directory: " + e);
    Any help will be highly appreciated.

  • CP5 - W7 - Nested/Grouped objects - Not possible

    Hi dear community,
    I use Photoshop, Premiere, after effects, and many other adobe produts...
    All of them have something in common, you can group or nest objects, vector based or pixel based media does not matter.
    In Premiere, yoy can group a film a title and some effects into a cilp, and then use that clip as a object.
    In Photoshop you can create folders under layers and use those to manage several objects at once.
    But what about captivate? Even the "not to be mensioned here PowerPoint" can group objects.
    Why is it so that within a company one does not reuse smart ideas and maby code?
    Do not get me wrong, I love all the posibilities with captivate, but explode sometimes on the small unessesary to forget to develop things.
    And to you who want to tell me about SHIFT, that is not what I am talking about
    Thank you for reading!
    // Daniel

    Hello,
    Sorry for that, must have been tired. The link is in the main page of these CP-forums, but here you have it too:
    Feature Request Form
    Lilybiri

  • OIM AD Group Object Classes

    Hello
    I need to add an additional object class to AD groups that are created from OIM. I am using OIM 9.1.0.2 and trying to update the lookup.ad.configuration ldapgroupobject class from "group" to "group | PosixGroup" and it looks like this is not taking. Does anyone know a good way to get the additional object class added when creating new groups in AD? Any help you can give would be appreciated.
    Nick

    Anyone able to help on this? I have opened a ticket but not getting anything from them on it.
    Thanks for the help
    Nick

  • Help With Grouping Objects

    I have four Pages 2 components (line of a certain color & width which will be used as a border, two text blocks, one masked image) which will hopefully be turned into a business card. Template is laid out and I'd like to move it all to there, but seemingly am unable to.
    I've tried selecting and grouping them ( Arrange >Group) but that doesn't work. I can't get the line object to be selected along with the other three, no matter which selection trick or technique I happen to try. I can select either the bordering line or whatever number of the three other objects, but never all four at the same time.
    Is this a limitation in Pages or am I simply missing something? If it can't be done, can you recommend some other way of getting to the same goal?

    Peggy,
    They may have been, but they're now gone. I gave up on the idea of using lines for borders for another reason, e.g., the measurements get messed up due to how the line is drawn or measured to/from.
    I did move to the AW way of doing it, basically nested 'boxes' of different shapes, all of it to be stacked and then the text boxes/images to be moved onto it.
    Same problem; could not get all of them go Group. In fact, after several tries and undos, I couldn't get any of them to. Pages tends to get lost, I think.
    Ran into other problems also; when the image you are using is a cropped (masked) one, you seem to be stuck with the adjustment bars for the whole thing. The result of this, for example, is seen when you subsequently do Group say that masked image with several other items like text frames or whatever else is working — you wind up with something which can be quite a bit larger than the visual end product.
    The drawback here is seen when you then drop all of it into a template like the one for the business cards; the whole thing gets correspondingly shrunk and the aligment you set up on the master can't be retained.
    Pages seems to have no capability to simply crop/mask off part of an entire construct, identify that as what you really want to play with, and to simply throw away the rest. Some objects I still can't get to group in with the rest, no matter what I do or how I do it.
    Short term workaround was to just put it all together and then take a screenshot of it. That works, and that image can then be dropped into each of the ten slots in the Avery template imported in Pages. It all works, but you do lose some sharpness in the end product.
    Of course, my printer just won't quite feed the Avery sheets correctly and I wind up with those irritating white lines along some of the borders. That's some other issue, however. Oh, well ..........

  • How to get customer-specific objects into PCUI ?

    Hello,
    we want to get an Z-table as tab page of the business partner-application into PCUI. It should 'only' be possible to create new entries - today there is no need to modify or delete records.
    Does there exist something like a "cookbook" on this task or has anyone of you experience how to get customer-specific objects (without using EEWB) into PCUI ?
    Thanks in advance
    Martin

    Option 1:
    If you are good in ABAP.
    You can add new tab in which create a new Field group. Assign it to a model access clas in which handle the table update.You can get the details in PCUI cookbook itsel.
    Option 2:
    If you are good at java
    Develop an FM to update the table.
    Call the FM from webdynpro
    Include this webdynpro as HTML viewer in PCUI.
    Regards,
    Abdul Raheem S

  • How to get user groups

    Hi,
    How can I get current users groups since the User and Group objects are marked as deprecated.
    Right now I'm doing the folowing:
    User user = request.getResourceResolver().adaptTo(User.class);
    Iterator<Group> groupsIterator = user.memberOf();
    Is there an other way to do it properly and without using deprecated methods/objects?
    Regards,
    Piotr

    Hi devPl83,
    Assuming you are on CQ5.5+, you should use org.apache.jackrabbit.api.security.user.User
    http://dev.day.com/docs/en/cq/current/javadoc/com/day/cq/security/User.html:
    Cheers -- David

  • Sharepoint 2010 get User Groups from specific site

    Hello,
    I was able to get all User groups from entire site Collection.
    But instead of getting user groups from entire site, I want read user groups only from one specified sub site.
    Please help!
    Thanks

    Assuming you have an SPWeb object named "web", example:
    SPSite site = new SPSite(http://yourdomain/sites/yoursite);
    SPWeb web = site.OpenWeb("mysubsite/subsbusite");
    web.Groups will return a collection of SPGroup objects for the current subsite. If this subsite inherits permissions from a parent site (web.HasUniquePerm = False), the list is the same as the Groups property of the parent site.
    SPWeb.Groups:
    http://msdn.microsoft.com/en-us/library/office/microsoft.sharepoint.spweb.groups(v=office.15).aspx
    SPGroup:
    http://msdn.microsoft.com/en-us/library/office/microsoft.sharepoint.spgroup(v=office.15).aspx
    You would be better results by posting coding questions in "SharePoint 2010 - Development and Programming" instead of "SharePoint 2010 - General Discussions and Questions".
    Mike Smith TechTrainingNotes.blogspot.com
    Books:
    SharePoint 2007 2010 Customization for the Site Owner,
    SharePoint 2010 Security for the Site Owner

  • Rename Layer, Group, Object Javascript

    Hey Guys,
    I'm trying to write a script that renames a layer, and group within the layer, then an object within the layer (but not a part of the group) and have it run in a loop.
    Here's what I've got so far, the group rename doesn't work.
    #target Illustrator
    var doc = app.activeDocument;
    idLayers(doc)//IRename layers
    idGroups(doc)//Rename groups
    function idLayers(doc){
        for(i=0;doc.layers.length>i;i++){
            doc.layers[i].name= 'id:GTM_Group '+(i+1)
    function idGroups(doc){
        for(i=0;doc.groups.length>i;i++){
            doc.groups[i].name= 'id:GTM_Group '+(i+1)
    I haven't put in anthing to rename the single object yet since I cant even get the group rename to work. I suspect that the group re-name section isn't working because I'm either using bad syntax or an invalid command. Any ideas?

    Found out that I was really close, and some interesting facts about how thorough illustrator will be when renaming groups across the board. Basically the files I'm working with have a layer that requires a specific name and number, and group within that layer and an object outside of that group but still in the same layer. Within the group is a compound path made up of several objects, I noticed that the when I started getting the group rename working it was skipping multiple numbers because it was going inside the compound path, find groups within the compound path and renaming them as well. So as long as I make sure there are no groups hidden within the groups I wanted to rename the script  works like a charm.
    Anyway this is what that script looks like I'm still working on getting the up-grouped object renamed. I notice this discussion has gotten a few views since I went to lunch. I'll post the final version at the end of the day if I have time.
    If anyone has any suggestions or constructive advice I'd be very open to hear it.
    #target Illustrator
    var doc = app.activeDocument;
    idLayers(doc)//IRename layers
    idGroups(doc)//Rename groups
    function idLayers(doc){
        for(i=0;doc.layers.length>i;i++){
            doc.layers[i].name= 'Named Layer  '+(i+1)
    function idGroups(doc){
        for(i=0;doc.groupItems.length>i;i++){
            doc.groupItems[i].name= 'Named Group '+(i+1)

  • Group-object hierarchy

    Hi guys,
    my Boss wants me to create a Report in powershell that Shows all machines per Location per Country and I'm struggling with that. Here are a few Infos about the whole Situation:
    The AD OU structure is
    RootOU
                -US
                         -DEN
                                     -DENPC001
                                     -DENPC002
                         -MAN
                                     -MANPC001
                                     -MANPC002
                 -UK
                         -LON
                                     -LONPC001
                                     -LONPC002
    I Need to come up with a script that results in 3 rows:
    Country Name, Location Name, Number of Computers.
    What I can manage to do is to get the Location and the Count of machines per Location, but how do I also get the Country in the same line?
    Here's my code:
    ################ Code begin #############
    function Get-ADLocationMembers {
     [CMDLetBinding()]
     Param (
      [string[]]$computername="LONPC001",
      [string]$DN="cn=LONPC001,ou=LON,ou=UK,dc=mydomain,dc=tld"
     BEGIN
            $objComp = New-Object -TypeName PSObject
        }#Begin
     PROCESS
      foreach ($computer in $computername) {
       $Location = (($computer).Substring(0,3))
       $Country = ((($dn -split ",")[-3]) -replace("OU=",""))
                write-Verbose "Location $($location)"
       write-verbose "Country $($Country)"
       $props = @{
        "Location" = $location;
        "Country"=$Country;
       }#foreach
       Add-Member -InputObject $objComp -NotePropertyMembers $props -EA "SilentlyContinue"
      }#foreach
     }#Process
        END
            $objComp
        }#End
    Get-ADLocationMembers | Group Location -NoElement
    ############### Code End #################
    The result is
    Count Name
        1 LON
    What I would Need is something like this:
    Country Count Name
    UK            1 LON
    Any help is greatly appreciated :)
    Thx
    Sebastian
    Sebastian Bammer

    $dns = @(
    "cn=DENPC001,ou=DEN,ou=US,dc=mydomain,dc=tld",
    "cn=DENPC002,ou=DEN,ou=US,dc=mydomain,dc=tld",
    "cn=MANPC001,ou=MAN,ou=US,dc=mydomain,dc=tld",
    "cn=MANPC002,ou=MAN,ou=US,dc=mydomain,dc=tld",
    "cn=MANPC003,ou=MAN,ou=US,dc=mydomain,dc=tld",
    "cn=LONPC001,ou=LON,ou=UK,dc=mydomain,dc=tld",
    "cn=LONPC002,ou=LON,ou=UK,dc=mydomain,dc=tld")
    $ht = @{}
    $regex1 = 'cn=.+,(ou=.+,ou=.+),dc=mydomain,dc=tld'
    $regex2 = 'ou=(.+),ou=(.+)'
    $dns |
    foreach {
    if ($_ -match $regex1)
    {$ht[$matches[1]]++}
    $ht.keys |
    foreach {
    $_ -match $regex2 > $null
    [PSCustomObject]@{
    Country = $Matches[2]
    Location = $Matches[1]
    Count = $ht[$_]
    } |
    sort Country,Location |
    Format-Table -AutoSize
    Country Location Count
    UK LON 2
    US DEN 2
    US MAN 3
    [string](0..33|%{[char][int](46+("686552495351636652556262185355647068516270555358646562655775 0645570").substring(($_*2),2))})-replace " "

  • [TIP]-Getting Uses Group Names Efficiently

    We were having trouble getting the names of the groups that a user belonged to. We could easily get the object ID's but getting the name for each group was very slow issuing single row queries. Anyway we are able to query group memberships efficiently using a queryfilter.
    Here is a code snippet in Java:
    public ArrayList getUserGroupNames ()
    throws MalformedURLException, RemoteException, NotInRequestException
    ArrayList groupNames = new ArrayList();
    IRemoteSession remoteSession = edk.getRemotePortalSession();
    //Get array of group object Id's that the user belongs too.
    int[] groupIdArray = remoteSession.getUserManager().getCurrentUserGroups();
    //Issue a query on the object Id's to get their names
    ObjectProperty[] op = {UserGroupProperty.SimpleName};
    QueryFilter[] qf = {new IntArrayQueryFilter(ObjectProperty.ObjectID, Operator.In, groupIdArray)};
    IObjectQuery ioq = remoteSession.getUserGroupManager().queryObjects(-1, 0, -1, ObjectProperty.ObjectID, true, op, qf);
    for (int i = 0; i < ioq.getRowCount(); i++)
    groupNames.add(ioq.getRow(i).getStringValue(UserGroupProperty.SimpleName));
    return groupNames;
    Hope this is usefull to others.

    Hi,
    You can still add 50 addresses to the group in the paid version and test it without sending it. After adding all contacts to the group, click on the group name and it should launch the Mail application with all recipient's email addresses populated in the respective To, CC or BCC fields. You can touch the CC or BCC fields and it will expand the list containing all the addresses.
    Since you dont wan't to send the email, you can just cancel out of the operation after verifying if all the email addresses are being populated.

  • Concatenate a string with the results of group-object

    I wrote a script to get the 10 most recent entries in the Windows application log. It works fine, but I would prefer to format the output differently.The output looks like this:server1\
    Count Name
        9 1008
        1 1010
    server 2\
    Count Name
        5 256
        5 258
    I'd like it to look like this.Server Count Name
    server1    9 1008
    server1    1 1010
    Server Count Name
    server2    5  256
    server2    5  258
    Ideally, the server name would only appear once per group, but I'd settle for what I showed above. Where does the "\" after the server name come from? Why are there all those empty lines between server groups?$S = get-content -Path c:\scripts\PowerShell\servers.txt
    Foreach ($Server in $S)
    if (test-connection $server -quiet -TimeToLive 5 -Count 2)
    $events = get-WinEvent -ComputerName $Server -logname application -Maxevents 10 -ErrorAction silentlyContinue
    $output1 = $events | group-object -property Id -noelement | sort-object -property count -descending -ErrorAction silentlyContinue
    $output2 = Out-String -InputObject $output1 -Width 100
    join-path $Server $output2
    else
    {"Could not connect to " + $Server}
    Thanks,Matthew

    Hi Matthew,
    I‘m writing to check if the suggestions were helpful, if you have any questions, please feel free to let me know.
    If you have any feedback on our support, please click here.
    Best Regards,
    Anna
    TechNet Community Support
    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Support, contact [email protected]

Maybe you are looking for

  • Query regarding hotfix & bam updater service

    Using Oracle BPM 10.3 MP2 Enterprise Edition Version: 10.3.2 Build: #100874. Hi All, I have following 2 queries: 1.) Currently we have 6 engines configured in Process Admin, After any hotfix is applied , do we need to re-create the Oracle® BPM Engine

  • Hiding Command Box

    Hi, I have imported the Best practices for EP package. In the package we have webgui transactional iviews. my concern is when i run the iview i can see the command box and from that i can run other transactions. I want to hide the command box so that

  • How do I set a password on an specific Smart Mailbox only?

    I want some of my folders in Mail to be of restricted access with a password. Is that possible? Alternatively, how do I set a password to open Mail so not everyobe sitting in my front of my laptop can have access to it...? Thanks in advance.

  • Recurring Appointment Issue Part II

    I've read all the postings on issues with getting recurring appointments on the iPhone; I've just gotten my phone and have all the latest software updates so I haven't had any problems getting them on. I am however having problems with the iPhone syn

  • Using my new MacBook Pro with my old HP 6110 printer

    I just purchased a new MacBook Pro and synced it with the settings from my old computer. I'm now trying to print to my old HP 6110 printer. I see HP 6110 printer in my printer settings, but the job gets stuck in the printer queue. I'm wondering if my