473,320 Members | 1,949 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

GridView: Change boolean values to Yes/No?

Hi!
I have an asp.net page with a gridview. One "columnfield" in the grid
contains boolean values. Is there a nice way to map this values to a
string depending on the value. I.e I want to display the text "Yes" if
true and "No" if false.

Thanks
/ Steve
Nov 19 '05 #1
1 3496
Use a template column, wrap a simple funtion around the databind.

--
Curt Christianson
Owner/Lead Developer, DF-Software
Site: http://www.Darkfalz.com
Blog: http://blog.Darkfalz.com
"Prozon" <ss*********@hotmail.com> wrote in message
news:c0*************************@posting.google.co m...
Hi!
I have an asp.net page with a gridview. One "columnfield" in the grid
contains boolean values. Is there a nice way to map this values to a
string depending on the value. I.e I want to display the text "Yes" if
true and "No" if false.

Thanks
/ Steve

Nov 19 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
by: | last post by:
Hello, Does anyone have an idea on how I can filter the data in the gridview control that was returned by an sql query? I have a gridview that works fine when I populate it with data. Now I...
2
by: loga123 | last post by:
Hi All, I am using Link Button for DELETE on the gridview. When I click on DELETE link, I get the ArgumentOutOfRangeException. But...it deletes the record from table in the database. On...
1
by: loga123 | last post by:
Hi All, I am using Link Button for DELETE on the gridview. When I click on DELETE link, I get the ArgumentOutOfRangeException. But...it deletes the record from table in the database. On...
3
by: Richard Carpenter | last post by:
I have a simple winform with a customers combobox, a "get orders" button and an orders grid. Due to other requirements, I have implemented the form to allow the user to select a customer from the...
1
by: martin1 | last post by:
Hi, All, Anyone knows how to change gridview text info? specifically the gridview populate from sql db, first column is string rather than number, i want to change first row in first column into...
3
by: Mark Leistner | last post by:
I am having problems getting a gridview to bind to custom objects under any non-full trust level. I created a test project to verify what I am seeing isn't a side effect of other code in my...
0
by: DC | last post by:
The problem I'm using the .NET GridView and FormView objects for the first time and im getting the error "An OleDbParameter with ParameterName '@ID' is not contained by this...
0
by: troyblakely | last post by:
I have a gridview which is pulling data from a SqlDataSource, the select command queries a view and the update command is a stored procedure. I'm using a stored procedure because several tables...
2
by: Looch | last post by:
Hi, I'm filling a GridView with a simple sproc select statement. I'm trying to use the Update tab to create an update statement and using the following: Update Shipping_Requests Set Shipped...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.