![]() |
|
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Hobbyist Programmer
Join Date: Oct 2004
Location: England, UK
Posts: 139
Rep Power: 0
![]() |
Hey guys, a simple question but i can't seem to find the answer on the net.
The question is how can I get the '£' character. Whenever I type it it comes out as a U with a squiggle on it. I think it's probally a special character but I'm not sure how to get the £ out. thanks in advance Ade ![]()
__________________
Don't wound what you can't kill |
|
|
|
|
|
#2 |
|
Hobbyist Programmer
Join Date: Nov 2004
Location: 1691 miles East of L.A.
Posts: 159
Rep Power: 4
![]() |
£ is displayed by holding alt then typing 156...alt-156. I reckon this is what you wanted?
__________________
-- lostcauz Stepped in what?... Behind whose barn?... I didn't even know they had a cow! |
|
|
|
|
|
#3 |
|
Newbie
|
Hey plz clearly state ur problem do u want to print on console or jst want it in ur program.
|
|
|
|
|
|
#4 |
|
Expert Programmer
|
If you are using a console to output the text you need to find a way to translate all your output to the proper codepage which your console is using, this is an indepth process and I am not willing to explain it here.
A better alternative would be to learn to create and compile your code to work with UNICODE based input and output, there are many articles on the interweb about this, actually I once was writing a book on the topic, but lack the time to complete it. When you look at UNICODE, if you have question about how things are done, feel free to ask and I can probably help you out in a little more detail. Good luck with your project.
__________________
Clifford Matthew Roche <geek@cliffordroche.com> Web Hosting: http://www.crd-hosting.com Consulting: http://www.crdev-consulting.com |
|
|
|
|
|
#5 |
|
Programming Guru
![]() Join Date: Oct 2004
Location: namespace std
Posts: 1,246
Rep Power: 5
![]() |
as far as console output, this works, don't know if that's what you want though...
#include <stdio.h>
int main()
{
printf("%c", 156);
return 0;
}note: in C. :ph34r:
__________________
i put on my robe and wizard hat... Have you ever heard of Plato, Aristotle, Socrates?...Morons. |
|
|
|
|
|
#6 |
|
Programming Guru
![]() Join Date: Oct 2004
Location: namespace std
Posts: 1,246
Rep Power: 5
![]() |
oh sorry, for C++
#include <iostream>
using namespace std;
int main()
{
cout<<(char) 156;
return 0;
}:ph34r:
__________________
i put on my robe and wizard hat... Have you ever heard of Plato, Aristotle, Socrates?...Morons. |
|
|
|
|
|
#7 |
|
Hobbyist Programmer
Join Date: Oct 2004
Location: England, UK
Posts: 139
Rep Power: 0
![]() |
That's wicked mate thanks.
![]()
__________________
Don't wound what you can't kill |
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|