Exemple #1
0
        public static void MapToFields(ListViewItem aItem, MapedObject aMap, bool ruleBased)
        {
            FieldColumnMap aPair = new FieldColumnMap();

            if (!ruleBased)
            {
                aPair.ColumnName = aItem.SubItems[0].Text;
            }
            else
            {
                aPair.ColumnName = aItem.SubItems[1].Text;
            }
            aPair.RuleBased  = ruleBased;
            aPair.FieldName  = aItem.SubItems[1].Text;
            aPair.DataType   = aItem.SubItems[2].Text;
            aPair.IsNullable = bool.Parse(aItem.SubItems[4].Text);
            aMap.FieldMaps.Add(aPair);
        }
        private void AddToMapList(FieldColumnMap aMap)
        {
            var newPair = new ListViewItem(new string[] { aMap.ColumnName, aMap.FieldName, aMap.DataType, aMap.IsNullable.ToString(), aMap.IsNullable.ToString() });

            lstMappedPairs.Items.Add(newPair);
        }