Click here to Skip to main content
12,397,610 members (65,001 online)
Rate this:
Please Sign up or sign in to vote.
See more: C#
Hi all,

i am currently experiencing some difficulties in getting arrow characters to display in a list view sub item. The code i am using is below:

lis = new ListViewItem(1.ToString());//(i + 1).ToString());
  if (targets[i].ApproachDirection.ToString().Equals("Forward"))
      // up
      // down = '↓';

This looks fine but displays an unsupported char rectangle when displayed in the form.

Does anyone know how this can be resolved?

Thanks George
Posted 22-Feb-11 22:30pm
Rate this: bad
Please Sign up or sign in to vote.

Solution 3

I just tried it - added a listview to a form, set the "View" to "List", and added this code:
It worked: what are you doing differently?
SAKryukov 23-Feb-11 14:50pm
Griff, missing part can by just font, see, I answered.
Rate this: bad
Please Sign up or sign in to vote.

Solution 1

These discussion should help you out:
Similar discussion 1[^]
Similar idea different scenario[^]

I guess, it's the font settings that make it look like a box. Trying setting the font via CSS to a valid family that shows an arrow.
Rate this: bad
Please Sign up or sign in to vote.

Solution 4

They will. You just need appropriate font. You can examine which font support what using standard application which comes with Windows installation: Character Map.

Make sure you use right Unicode characters; they are x2190 to x21EA, in the range called "Arrows".


This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month

Advertise | Privacy | Mobile
Web02 | 2.8.160721.1 | Last Updated 23 Feb 2011
Copyright © CodeProject, 1999-2016
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100