public frmNavQuery(QueryFieldCollection queryfields, InfoBindingSource bs, InfoNavigator nav) { //language = CliSysMegLag.GetClientLanguage(); language = CliUtils.fClientLang; queryFields = queryfields; if (queryfields == null || queryfields.Count == 0) { DataColumnCollection dcc = ((InfoDataSet)bs.GetDataSource()).RealDataSet.Tables[bs.DataMember].Columns; colNum = dcc.Count; colName = new string[colNum]; for (int j = 0; j < colNum; j++) { colName[j] = dcc[j].ColumnName; } } else { colNum = queryfields.Count; colName = new string[colNum]; for (int j = 0; j < colNum; j++) { colName[j] = queryfields[j].FieldName; } } bSource = bs; infoNavigator = nav; InitializeComponent(); InitializeQueryConditionItem(); }
// End Add public InfoNavigator() { this.SureInsert = false; this.SureDelete = true; this.QuerySQLSend = true; this.InternalQuery = true; this._ViewScrollProtect = false; m_states = new StateCollection(this, typeof(StateItem)); //m_sureDeleteText = "Are you sure to delete current record?"; //m_sureInsertText = "Are you sure to insert record?"; this.LayoutCompleted += new EventHandler(InfoNavigator_LayoutCompleted); _QueryFields = new QueryFieldCollection(this, typeof(QueryField)); _QueryMode = QueryModeType.ClientQuery; _QueryFont = new Font("SimSun", 9.0f); }