예제 #1
0
 private int customSortAllAssociationListByParameterGroup(ClassOneParamAssociation itemA, ClassOneParamAssociation itemB)
 {
     if ((itemA.ParameterGroup.ToLower() == itemB.ParameterGroup.ToLower()))
     {
         if ((String.Compare(itemA.ThisParameterName.ToLower(), itemB.ThisParameterName.ToLower(), StringComparison.Ordinal)) != 0)
         {
             return(-1);
         }
         else
         {
             return(1);
         }
     }
     else if ((String.Compare(itemA.ParameterGroup.ToLower(), itemB.ParameterGroup.ToLower(), StringComparison.Ordinal)) != 0)
     {
         return(-1);
     }
     else
     {
         return(1);
     }
 }
예제 #2
0
        public void ReadSharedParametersFile()
        {
            ClassOneParamAssociation newgroupUnderSelectedIndexChanged;

            // MessageBox.Show(m_sharedParamFile.Groups.coun
            // Dim iter As DefinitionGroupsBaseIterator
            // iter = m_sharedParamFile.Groups.ForwardIterator
            // Do While iter.MoveNext
            //     Dim myGroup = iter.Current
            // Loop
            // MessageBox.Show("here")
            foreach (DefinitionGroup myGroup in RevitInterface.SharedParameterFile.Groups)
            {
                AllParamterGroupsList.Add(new ClassOneParamGroup(myGroup.Name));
                foreach (Autodesk.Revit.DB.ExternalDefinition oneExternalDef in myGroup.Definitions)
                {
                    newgroupUnderSelectedIndexChanged = new ClassOneParamAssociation(oneExternalDef, this);
                    AllAssociationArrayList.Add(newgroupUnderSelectedIndexChanged);
                }
            }

            // '  MessageBox.Show("e) readSharedParametersFile")
        }
예제 #3
0
 private int customSortAllAssociationListByParameterName(ClassOneParamAssociation itemA, ClassOneParamAssociation itemB)
 {
     return(String.Compare(itemA.ThisParameterName.ToLower(), itemB.ThisParameterName.ToLower(), StringComparison.Ordinal));
 }
예제 #4
0
 public void addMemberToActiveSet(ClassOneSet setObj, ClassOneParamAssociation parameterObj)
 {
     setObj.AddParameterToMembers(parameterObj.ThisParameterName);
 }