Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Need a check

Status
Not open for further replies.

jfrost10

Programmer
Jun 3, 2001
2,004
CA
Hey guys,

So I have a datagrid with checkboxes, and when its disabled I want a column to show up with a "check" in for the text.

Does anyone know how I would do this (i.e. hex code for it, wingding something or other, etc)

I was thinking worst case I could do an image and just show/hide it, but I'd rather just do the text if its easier.

Thanks,

Jack
 
Can you use the Character map? Font Arial with a Unicode value of U+221A might work it's actually a square root sign but looks like a check mark see: ã

That is also using the Unicode character set by the way. That'l do donkey, that'l do
[bravo] Mark
 
O..
Apparently that didn't come across right though. That'l do donkey, that'l do
[bravo] Mark
 
A small 'a' in webdings is also a check mark That'l do donkey, that'l do
[bravo] Mark
 
But how do I do that in code Mark?

i.e.
dgBranch.Items(j).Cells(1).Text = CHECKGOESHERE

Thanks man,

Jack
 
I got a text box to display a check for me by doing this

textbox1.text = "
now find the check mark in the character map it's under start menu - accessories - system tools copy it, return to VS and paste "

For the webdings it's a little more programmatic.
Doesn't look as good though.

textbox1.font.name = "Webdings"
textbox1.text = "a"

HTH That'l do donkey, that'l do
[bravo] Mark
 
Hmmm...the user will need Wingding's installed on their computer for it to work though, right?

I like your first idea better
;)

Did you really have a way of doing the first one, or is that just wishful thinking?
;)

Jack
 
WHAT? Of course I did.

The code in green is the code that you need to type into your code behind page.
The black text inbetween the green quotes is the steps I followed to put the check mark there.

You are right the user would need Wingding's installed. As far as I know that is a font that is installed with windows. At least I haven't run across a machine that doesn't have it. Definetly not saying that they aren't out there.

The problem with the first method is that the user must have their encoding set to Unicode. If it was set to say Windows: Western that character doesn't exist.
Which is why I am guessing that my first post displayed a funky bunch of characters rather than a check mark.

6 of one half dozen of the other? It's up to you really. That'l do donkey, that'l do
[bravo] Mark
 
Hmmm...maybe I should look into the check image idea then, that way i wouldn't have to worry about the unicode thing or if they had wingdings installed.

Thanks mark
:)

jack
 
Personnally I would go with the webdings if you wanted a text solution, cause like I said I am pretty sure every machine has webdings installed on it.

Glad to help. That'l do donkey, that'l do
[bravo] Mark
 
i'd say go with the check image. you'll run into font incompatibilities with non-windows users; i.e. poor mac people
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top