public void AddSearchItem(string sItemName, string sItemFiled, FiledType FiledType,string LookUpOrComboBoxSetting) { LItemName.Add("[" + sItemName + "]"); LItemFiled.Add("[" + sItemFiled + "]"); LFieldType.Add(FiledType); LLookUpOrComboBoxSetting.Add(LookUpOrComboBoxSetting); }
public void AddSearchItem(string sItemName, string sItemFiled, FiledType FiledType, string sql, string returnfield, string displayfield, string columnfield, string columntetx, string text) { LItemName.Add("[" + sItemName + "]"); LItemFiled.Add("[" + sItemFiled + "]"); LFieldType.Add(FiledType); string LookUpOrComboBoxSetting = sql + "|" + returnfield + "|" + displayfield + "|" + "|" + columnfield + "|" + columntetx + "|" + text; LLookUpOrComboBoxSetting.Add(LookUpOrComboBoxSetting); }
/// <summary> /// 根据字段类型,返回对应的字符串 /// </summary> /// <param name="type"></param> /// <returns></returns> public static string FiledTypeToString(FiledType type) { switch (type) { case FiledType.c_number: return("number"); case FiledType.c_string: return("string"); case FiledType.c_table: return("table"); default: break; } return(""); }
/// <summary> /// 解析cell数据 /// </summary> /// <param name="filedType"></param> /// <param name="data"></param> /// <returns></returns> public static string ParseCellDataByType(FiledType filedType, string data) { StringBuilder sb = new StringBuilder(); switch (filedType) { case FiledType.c_unkonw: return(data); case FiledType.c_number: return(data); case FiledType.c_string: sb.Append("\"" + data + "\""); return(sb.ToString()); case FiledType.c_table: return(DealCellDataByTable(data)); default: return(data); } }
public void AddSearchItem(string sItemName, string sItemFiled, FiledType FiledType, string ComboBoxValues,string ComboBoxTexts) { LItemName.Add("[" + sItemName + "]"); LItemFiled.Add("[" + sItemFiled + "]"); LFieldType.Add(FiledType); string LookUpOrComboBoxSetting = ComboBoxValues + "|" + ComboBoxTexts; LLookUpOrComboBoxSetting.Add(LookUpOrComboBoxSetting); }