Click here to Skip to main content
15,920,956 members
Home / Discussions / C#
   

C#

 
AnswerRe: Preventing the user to resize the ListView columns Pin
Luc Pattyn3-Oct-09 8:29
sitebuilderLuc Pattyn3-Oct-09 8:29 
GeneralRe: Preventing the user to resize the ListView columns Pin
SimpleData3-Oct-09 8:38
SimpleData3-Oct-09 8:38 
GeneralRe: Preventing the user to resize the ListView columns Pin
Manas Bhardwaj3-Oct-09 9:31
professionalManas Bhardwaj3-Oct-09 9:31 
GeneralRe: Preventing the user to resize the ListView columns Pin
DaveyM693-Oct-09 9:34
professionalDaveyM693-Oct-09 9:34 
GeneralRe: Preventing the user to resize the ListView columns Pin
SimpleData3-Oct-09 10:09
SimpleData3-Oct-09 10:09 
Joke[Message Deleted] Pin
Muammar©3-Oct-09 1:56
Muammar©3-Oct-09 1:56 
GeneralRe: Big chief, no fart! Pin
Luc Pattyn3-Oct-09 2:03
sitebuilderLuc Pattyn3-Oct-09 2:03 
GeneralRe: Big chief, no fart! Pin
Muammar©3-Oct-09 2:19
Muammar©3-Oct-09 2:19 
GeneralRe: Big chief, no fart! Pin
Xmen Real 3-Oct-09 2:13
professional Xmen Real 3-Oct-09 2:13 
GeneralRe: Big chief, no fart! Pin
Muammar©3-Oct-09 2:18
Muammar©3-Oct-09 2:18 
Questionhow to store OnComm values in a single string variable Pin
Mads1153-Oct-09 1:12
Mads1153-Oct-09 1:12 
AnswerRe: how to store OnComm values in a single string variable Pin
freakyit3-Oct-09 1:46
freakyit3-Oct-09 1:46 
AnswerRe: how to store OnComm values in a single string variable Pin
Luc Pattyn3-Oct-09 2:02
sitebuilderLuc Pattyn3-Oct-09 2:02 
AnswerRe: how to store OnComm values in a single string variable Pin
dan!sh 3-Oct-09 2:10
professional dan!sh 3-Oct-09 2:10 
AnswerRe: how to store OnComm values in a single string variable Pin
PIEBALDconsult3-Oct-09 6:34
mvePIEBALDconsult3-Oct-09 6:34 
QuestionDataGridViewCombo Pin
jacobsan43-Oct-09 0:35
jacobsan43-Oct-09 0:35 
AnswerRe: DataGridViewCombo Pin
Xmen Real 3-Oct-09 1:42
professional Xmen Real 3-Oct-09 1:42 
AnswerRe: DataGridViewCombo Pin
dan!sh 3-Oct-09 2:07
professional dan!sh 3-Oct-09 2:07 
QuestionRe: DataGridViewCombo Pin
jacobsan43-Oct-09 2:44
jacobsan43-Oct-09 2:44 
private System.Windows.Forms.DataGridView jobSheetDGV;
private SABDBDataSet6 sABDBCountryDataSet;
private System.Windows.Forms.BindingSource countrytDetailsBindingSource;
private SAB.SABDBDataSet6TableAdapters.CountryDetailsTableAdapter countryDetailsTableAdapter;

private void jobSheetDGV_CellLeave(object sender, DataGridViewCellEventArgs e)
{
int rowIndex = jobSheetDGV.CurrentCell.RowIndex;
if (e.ColumnIndex == 3)
{
if (jobSheetDGV.Rows[rowIndex ].Cells[3].Value == null)
{
string sql2 = "GetCountryIdByCountryName";
DbCommand cmd2 = _db.GetStoredProcCommand(sql2);
_db.AddInParameter(cmd2, "CountryName", DbType.String, jobSheetDGV.Rows[rowIndex].Cells[2].Value);
using (IDataReader dataReader1 = _db.ExecuteReader(cmd2))
{
while (dataReader1.Read())
{
string sql = "GetStatesByCountryId";
DbCommand cmd = _db.GetStoredProcCommand(sql);
_db.AddInParameter(cmd, "CountryId", DbType.Int32, countryId.CountryId);
using (IDataReader dataReader = _db.ExecuteReader(cmd))
{
while (dataReader.Read())
{
states = new States(dataReader.GetInt32(0), dataReader.GetString(1), dataReader.GetString(2), dataReader.GetString(3),
dataReader.GetString(4), dataReader.GetInt32(5));
if (states != null)
States.Items.Add(states);


}
}
}
}

In this States is the column name.
The question is simple that i want to fill states in respective to the country selected.I have a country table with country id as primary key and a state table with country id as foreign key..
}
}
}
QuestionImplementing MVC architecture in Windows Form Pin
srikrishnakrishna murthy2-Oct-09 23:46
srikrishnakrishna murthy2-Oct-09 23:46 
AnswerRe: Implementing MVC architecture in Windows Form Pin
Christian Graus2-Oct-09 23:51
protectorChristian Graus2-Oct-09 23:51 
GeneralRe: Implementing MVC architecture in Windows Form Pin
srikrishnakrishna murthy3-Oct-09 0:17
srikrishnakrishna murthy3-Oct-09 0:17 
GeneralRe: Implementing MVC architecture in Windows Form Pin
Christian Graus3-Oct-09 10:54
protectorChristian Graus3-Oct-09 10:54 
QuestionC# Programming ? Pin
Dossa2-Oct-09 23:11
Dossa2-Oct-09 23:11 
AnswerRe: C# Programming ? Pin
nagendrathecoder2-Oct-09 23:13
nagendrathecoder2-Oct-09 23:13 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.