How can I define a variable in the designer of a form?
Today I define the variable for my parameter, but when I see the form it gives this warning (even with the warning, it executes normally):
The variable 'id_grid' is either undeclared or never assigned.
Follow the code:
this.sqlDataSource1.ConnectionName = "String tpspoazsql01 onee";
this.sqlDataSource1.Name = "sqlDataSource1";
columnExpression15.ColumnName = "nome";
table3.MetaSerializable = "0|0|125|260";
table3.Name = "Cliente_enderecos_alter";
columnExpression15.Table = table3;
column15.Expression = columnExpression15;
columnExpression16.ColumnName = "endereco";
columnExpression16.Table = table3;
column16.Expression = columnExpression16;
columnExpression17.ColumnName = "numero";
columnExpression17.Table = table3;
column17.Expression = columnExpression17;
columnExpression18.ColumnName = "bairro";
columnExpression18.Table = table3;
column18.Expression = columnExpression18;
columnExpression19.ColumnName = "cidade";
columnExpression19.Table = table3;
column19.Expression = columnExpression19;
columnExpression20.ColumnName = "estado";
columnExpression20.Table = table3;
column20.Expression = columnExpression20;
columnExpression21.ColumnName = "cep";
columnExpression21.Table = table3;
column21.Expression = columnExpression21;
selectQuery3.Columns.Add(column15);
selectQuery3.Columns.Add(column16);
selectQuery3.Columns.Add(column17);
selectQuery3.Columns.Add(column18);
selectQuery3.Columns.Add(column19);
selectQuery3.Columns.Add(column20);
selectQuery3.Columns.Add(column21);
selectQuery3.FilterString = "[Cliente_enderecos_alter.id_cliente] = ?ID1";
selectQuery3.Name = "Cliente_enderecos_alter";
queryParameter5.Name = "ID1";
queryParameter5.Type = typeof(int);
queryParameter5.ValueInfo = "0";
queryParameter5.Value = id_grid;
selectQuery3.Parameters.Add(queryParameter5);
selectQuery3.Tables.Add(table3);
this.sqlDataSource1.Queries.AddRange(new DevExpress.DataAccess.Sql.SqlQuery[] {
selectQuery3});
this.sqlDataSource1.ResultSchemaSerializable = resources.GetString("sqlDataSource1.ResultSchemaSerializable");