PC Review


Reply
Thread Tools Rate Thread

formate datagrid text columns

 
 
=?Utf-8?B?b3NjYXI=?=
Guest
Posts: n/a
 
      24th Feb 2005

i currently have a datagrid with a price column and would like to know if
there is a way to formate the column so a '$' appears in front of everything
in the column. i've seen a few of the table style utilities people have
built, but i can't help but think there should be an easy way to do it. the
datagrid gets its info from a dataview.

i'm also curious if there is a way to make a column in the dataview display
as checkboxes in the datagrid. they user will not be able to use the check
boxes, just see if it is checked or not. is this possible and if so how? i'm
currently using c# .net and it is for a windows form, not a web form.

thanx for the help
 
Reply With Quote
 
 
 
 
Dmitriy Lapshin [C# / .NET MVP]
Guest
Posts: n/a
 
      25th Feb 2005
Hi Oscar,

> i currently have a datagrid with a price column and would like to know if
> there is a way to formate the column so a '$' appears in front of
> everything
> in the column.


The DataGridTextBoxColumn has the Format and FormatInfo properties you can
use to specify data formatting.

--
Sincerely,
Dmitriy Lapshin [C# / .NET MVP]
Bring the power of unit testing to the VS .NET IDE today!
http://www.x-unity.net/teststudio.aspx

"oscar" <(E-Mail Removed)> wrote in message
news:BA3E4920-0CFD-4BB8-BFB8-(E-Mail Removed)...
>
> i currently have a datagrid with a price column and would like to know if
> there is a way to formate the column so a '$' appears in front of
> everything
> in the column. i've seen a few of the table style utilities people have
> built, but i can't help but think there should be an easy way to do it.
> the
> datagrid gets its info from a dataview.
>
> i'm also curious if there is a way to make a column in the dataview
> display
> as checkboxes in the datagrid. they user will not be able to use the
> check
> boxes, just see if it is checked or not. is this possible and if so how?
> i'm
> currently using c# .net and it is for a windows form, not a web form.
>
> thanx for the help


 
Reply With Quote
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
HOW TO FORMATE PART OF TEXT FROM TEXT STRING Vishal Microsoft Excel Misc 2 10th Jun 2008 05:18 PM
Copy DataGrid columns values to text box Soulless Microsoft C# .NET 2 1st Nov 2007 02:33 PM
text formate =?Utf-8?B?Q2hleQ==?= Microsoft Access 1 20th Apr 2006 10:31 PM
DataGrid with images or image + text columns? Jared Miniman [MVP] Microsoft Dot NET Compact Framework 2 19th Jun 2004 09:50 PM
Re: DataGrid Columns header text forecolor Nicholas Paldino [.NET/C# MVP] Microsoft C# .NET 0 25th Jul 2003 02:35 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 09:41 PM.