Solved

different currency symbols in VB 2010

Posted on 2012-03-31
4
431 Views
Last Modified: 2012-08-13
Hello,

I am writing a VB program to convert USD to various foreign currencies:
India Rupee, Canada Dollar, Eurozone Euro, Japan Yen, Mexico Peso, SouthAfrica Rand, and United Kingdom Pound.

The user will type in an amount in USD and select one of the above countries from a radio button.  The output should display the conversion with the appropriate currency symbol.  I can get everything to work except the currency symbol.  

Any suggestions?
Thanks!
0
Comment
Question by:crockettebhc
  • 2
4 Comments
 
LVL 35

Expert Comment

by:Robert Schutt
Comment Utility
Most symbols shouldn't be too hard but India Rupee is a relatively new unicode symbol and not every computer will have it. Mine doesn't but it should work if your computer has the latest fonts, with this code:

        Dim strsymbol As String
        If Me.RadioButton1.Checked Then strsymbol = ChrW(Convert.ToInt16("20B9", 16))

Open in new window


The code for euro is "20AC", the rest can be done directly in a string "$", "R", "£", "¥"
0
 
LVL 8

Expert Comment

by:Wiesje
Comment Utility
Off topic question: Do not forget you will also need up to date currency converter rates. I always get mine from: http://www.xe.com/ucc/
0
 
LVL 35

Accepted Solution

by:
Robert Schutt earned 500 total points
Comment Utility
Update: apparently the India Rupee not displaying correctly had nothing to do with my computer at home, it's just not officialized yet it seems. There's a workaround with a font (Rupee.ttf or Rupee_foradian.ttf) you can download but that's far from ideal of course...

By the way, in some circles it's perfectly acceptable to use the official abbreviations/ISO codes like INR for Indian Rupee, but I'm guessing that's not what you were shooting for?


UPDATE 2: No scratch that, it IS available, but only in certain fonts like Arial.

If not on your system, this article explains how to get it and use it: http://www.labnol.org/india/windows-fonts-for-rupee/18964/
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Suggested Solutions

This article explains how to create and use a custom WaterMark textbox class.  The custom WaterMark textbox class allows you to set the WaterMark Background Color and WaterMark text at design time.   IMAGE OF WATERMARKS STEPS Create VB …
The ECB site provides FX rates for major currencies since its inception in 1999 in the form of an XML feed. The files have the following format (reducted for brevity) (CODE) There are three files available HERE (http://www.ecb.europa.eu/stats/exch…
In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're interested in additional methods for monitoring bandwidt…
When you create an app prototype with Adobe XD, you can insert system screens -- sharing or Control Center, for example -- with just a few clicks. This video shows you how. You can take the full course on Experts Exchange at http://bit.ly/XDcourse.

743 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

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now