Click here to Skip to main content
15,890,512 members
Home / Discussions / Windows Forms
   

Windows Forms

 
AnswerRe: Parent and child forms Pin
CompMan441-May-07 13:38
CompMan441-May-07 13:38 
GeneralRe: Parent and child forms Pin
sarah_malik2-May-07 5:18
sarah_malik2-May-07 5:18 
QuestionEnable ClearType for individual application Pin
roel_v20-Apr-07 20:37
roel_v20-Apr-07 20:37 
QuestionDraw Form Pin
Socheat.Net19-Apr-07 21:43
Socheat.Net19-Apr-07 21:43 
AnswerRe: Draw Form Pin
Paul Conrad13-Jul-07 13:45
professionalPaul Conrad13-Jul-07 13:45 
Questionfind webdav thread mails? Pin
ArunkumarSundaravelu18-Apr-07 23:19
ArunkumarSundaravelu18-Apr-07 23:19 
QuestionMaking the "row" of the selected node highlighted [modified] Pin
Skardal18-Apr-07 0:49
Skardal18-Apr-07 0:49 
QuestionDataGrid Sorting Problem Pin
sonia_basangar17-Apr-07 20:56
sonia_basangar17-Apr-07 20:56 
Hi,
In My Datagrid i have shoen the values from tables like passport no,passenger name,travel date,tour_code.
But when i click on the column Heading it is convered to Passport_no(ASc) & againi click to Passport_no(Desc) that is it just changing the heading but not actually ascending the values or descending the values of a column.


I have set all sort expression for each column
and in onsortcommand i write
<
#region DataGridSortCommand Event

public void doSortDataGridItem(object sender , System.Web.UI.WebControls.DataGridSortCommandEventArgs e)
{
SortingDataGrid.sortDataGridByValue(dgHistory,e);

}//End of this event.

#endregion
>

This is the method i used for the sorting
<
public string sortDataGridByValue(DataGrid datagrid, System.Web.UI.WebControls.DataGridSortCommandEventArgs e)
{

oColumnCollection=datagrid.Columns;
foreach (DataGridColumn oCol in oColumnCollection)
{
if(e.SortExpression.CompareTo(oCol.SortExpression)== 0)
{
oCol.HeaderText=oCol.HeaderText.Replace(" (ASC)","").Replace(" (DESC)","");
if(e.SortExpression.IndexOf(" ASC")>1)
{
oCol.SortExpression = e.SortExpression.Replace(" ASC", " DESC");
oCol.HeaderText = oCol.HeaderText.Replace(" (ASC)","");
oCol.HeaderText = oCol.HeaderText + " (DESC)";
return oCol.SortExpression;
}//End of inner If Block.
else if (e.SortExpression.IndexOf(" DESC") > 1 )
{
oCol.SortExpression = e.SortExpression.Replace(" DESC", "");

return e.SortExpression;
}
else
{
oCol.SortExpression = e.SortExpression + " ASC";
oCol.HeaderText = oCol.HeaderText + " (ASC)";
return oCol.SortExpression;
}
}//End of if block.

}//End of For loop.
return "";

}//End of method
>
AnswerRe: DataGrid Sorting Problem Pin
kubben19-Apr-07 1:51
kubben19-Apr-07 1:51 
Questionshowing a form twice Pin
godzooky17-Apr-07 4:16
godzooky17-Apr-07 4:16 
AnswerRe: showing a form twice Pin
Pete O'Hanlon17-Apr-07 4:25
mvePete O'Hanlon17-Apr-07 4:25 
AnswerRe: showing a form twice Pin
sthotakura17-Apr-07 8:25
sthotakura17-Apr-07 8:25 
AnswerRe: showing a form twice Pin
CompMan441-May-07 13:44
CompMan441-May-07 13:44 
QuestionHow to Display a dialog box for a property? Pin
aswinandaswin16-Apr-07 21:10
aswinandaswin16-Apr-07 21:10 
AnswerRe: How to Display a dialog box for a property? Pin
Kashif Iqbal Khan27-Apr-07 16:26
Kashif Iqbal Khan27-Apr-07 16:26 
QuestiondataGridView Binding Pin
Ali el16-Apr-07 21:09
Ali el16-Apr-07 21:09 
AnswerRe: dataGridView Binding Pin
Gopal.S3-May-07 7:57
Gopal.S3-May-07 7:57 
QuestionIncreasing Control Rendering Performance Pin
Cypher77716-Apr-07 7:35
Cypher77716-Apr-07 7:35 
QuestionListbox binding Pin
aweekes116-Apr-07 3:32
aweekes116-Apr-07 3:32 
AnswerRe: Listbox binding Pin
Paul Conrad13-Jul-07 13:44
professionalPaul Conrad13-Jul-07 13:44 
QuestionUnable to embed resource file Pin
Ali el15-Apr-07 22:16
Ali el15-Apr-07 22:16 
AnswerRe: Unable to embed resource file Pin
Paul Conrad13-Jul-07 13:44
professionalPaul Conrad13-Jul-07 13:44 
QuestionHow to compare two textbox values in windows forms? Pin
irkahc15-Apr-07 19:26
irkahc15-Apr-07 19:26 
AnswerRe: How to compare two textbox values in windows forms? Pin
Ali el15-Apr-07 23:04
Ali el15-Apr-07 23:04 
QuestionHow to select Multiple rows in Datagrid View In windows application Pin
TarangPandya15-Apr-07 18:53
TarangPandya15-Apr-07 18:53 

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.