Click here to Skip to main content
15,895,709 members
Home / Discussions / ASP.NET
   

ASP.NET

 
AnswerRe: how to open pdf in the new tab or new browser? Pin
Parwej Ahamad27-Jun-11 19:30
professionalParwej Ahamad27-Jun-11 19:30 
GeneralRe: how to open pdf in the new tab or new browser? Pin
Dhyanga28-Jun-11 6:11
Dhyanga28-Jun-11 6:11 
GeneralRe: how to open pdf in the new tab or new browser? Pin
Parwej Ahamad28-Jun-11 6:25
professionalParwej Ahamad28-Jun-11 6:25 
GeneralRe: how to open pdf in the new tab or new browser? Pin
Dhyanga28-Jun-11 8:40
Dhyanga28-Jun-11 8:40 
GeneralRe: how to open pdf in the new tab or new browser? Pin
Parwej Ahamad28-Jun-11 8:45
professionalParwej Ahamad28-Jun-11 8:45 
GeneralRe: how to open pdf in the new tab or new browser? Pin
Dhyanga28-Jun-11 8:59
Dhyanga28-Jun-11 8:59 
AnswerRe: how to open pdf in the new tab or new browser? Pin
Vasudevan Deepak Kumar30-Jun-11 14:08
Vasudevan Deepak Kumar30-Jun-11 14:08 
QuestionFormatting data in a GridView Pin
mjackson1124-Jun-11 8:25
mjackson1124-Jun-11 8:25 
I am pulling data out of a SQL database into a GridView. The column names are dynamic so I never know what they will be (except the first column).

I would like to format the data (they are floating point numbers.)

I tried to use the RowDataBound event but it doesn't seem to do anything. Is there a way to format these numbers in a {F2} format? (I know that this code doesn't do it but I have tried a ton of things and none of them worked.)

This seems like an extremely clunky way to format the data. (We cannot format the data in SQL for other reasons.)

Thx

Mark Jackson

<code>
protected void gvFcstDmd_RowDataBound(object sender, GridViewRowEventArgs e)
{
if (e.Row.RowType == DataControlRowType.DataRow)
{
int i = 0;
DataRowView drv = e.Row.DataItem as DataRowView;

for (i = 1; i &lt; drv.Row.ItemArray.Count(); i++) // start at one to not format the first column
{
drv[i] = Convert.ToString((Decimal)drv.Row.ItemArray[i]);
}
}
}

</code>
AnswerRe: Formatting data in a GridView Pin
thatraja24-Jun-11 8:54
professionalthatraja24-Jun-11 8:54 
GeneralRe: Formatting data in a GridView Pin
mjackson1124-Jun-11 9:36
mjackson1124-Jun-11 9:36 
AnswerRe: Formatting data in a GridView Pin
mjackson1125-Jun-11 9:46
mjackson1125-Jun-11 9:46 
Questionhow to get the list of files in a folder? Pin
neodeaths23-Jun-11 9:56
neodeaths23-Jun-11 9:56 
AnswerRe: how to get the list of files in a folder? Pin
Ali Al Omairi(Abu AlHassan)23-Jun-11 10:46
professionalAli Al Omairi(Abu AlHassan)23-Jun-11 10:46 
AnswerRe: how to get the list of files in a folder? Pin
Agent__00727-Jun-11 7:18
professionalAgent__00727-Jun-11 7:18 
Questionhow to solve dynamic control panel postback problem? Pin
neodeaths23-Jun-11 9:54
neodeaths23-Jun-11 9:54 
AnswerRe: how to solve dynamic control panel postback problem? Pin
kadaoui el mehdi26-Jun-11 0:32
kadaoui el mehdi26-Jun-11 0:32 
QuestionRegex pattern Pin
padmanabhan N23-Jun-11 3:14
padmanabhan N23-Jun-11 3:14 
AnswerRe: Regex pattern Pin
Keith Barrow23-Jun-11 4:10
professionalKeith Barrow23-Jun-11 4:10 
QuestionDisplaying the image from the Sql Pin
NaveenHS23-Jun-11 2:15
NaveenHS23-Jun-11 2:15 
AnswerRe: Displaying the image from the Sql Pin
Blue_Boy23-Jun-11 4:55
Blue_Boy23-Jun-11 4:55 
AnswerRe: Displaying the image from the Sql Pin
GenJerDan23-Jun-11 6:14
GenJerDan23-Jun-11 6:14 
GeneralRe: Displaying the image from the Sql Pin
Not Active23-Jun-11 7:38
mentorNot Active23-Jun-11 7:38 
GeneralRe: Displaying the image from the Sql Pin
GenJerDan23-Jun-11 7:49
GenJerDan23-Jun-11 7:49 
GeneralRe: Displaying the image from the Sql Pin
Not Active23-Jun-11 8:03
mentorNot Active23-Jun-11 8:03 
GeneralRe: Displaying the image from the Sql Pin
GenJerDan23-Jun-11 8:08
GenJerDan23-Jun-11 8:08 

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.