Solved

datagrid binding

Posted on 2004-09-15
4
245 Views
Last Modified: 2010-04-23
hi

   I have a datagrid. There is a field in datagrid corresponding to "Status" field in database which is either 0 or 1.

but when i bind that to datagrid in that field i want to display either "on" or "Off" corresponding to o or 1.

any idea how to do that.

thanks
sandeep
0
Comment
Question by:sandeep437
4 Comments
 
LVL 2

Accepted Solution

by:
ahmadfuwad earned 125 total points
ID: 12072707
Just write this querry for getting on and off instead of 0 and 1

select case when status=0 then 'on' else 'off' end Col from customer
0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
VB.NET 1 28
VB.net Progress Bar - Maximum Value too large 2 15
Iteration Help (Asp.net VB) 5 24
Access/Visual Basic Question 3 23
If you're writing a .NET application to connect to an Access .mdb database and use pre-existing queries that require parameters, you've come to the right place! Let's say the pre-existing query(qryCust) in Access takes a Date as a parameter and l…
1.0 - Introduction Converting Visual Basic 6.0 (VB6) to Visual Basic 2008+ (VB.NET). If ever there was a subject full of murkiness and bad decisions, it is this one!   The first problem seems to be that people considering this task of converting…
This video shows how to use Hyena, from SystemTools Software, to bulk import 100 user accounts from an external text file. View in 1080p for best video quality.
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…

807 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question