PC Review


Reply
Thread Tools Rate Thread

Data problem

 
 
singh
Guest
Posts: n/a
 
      9th Apr 2008
Hi All

For one of my project am getting amount in a different way.
EG: If amount is $45,455.00 am getting data as $ 45'455.00.

Is there any way we can convert this data??

Thanks in advance.

 
Reply With Quote
 
 
 
 
Joel
Guest
Posts: n/a
 
      9th Apr 2008
There arre a few things to try. the number may be just formated using a
custom format. Check the cell format and change the custom format. If the
number is a string the following the steps below.

1) Use replace to remove the single quote
MyNumber = replace(MyNumber,"'","") 'you need to put the single quote
inside double quotes and replace with nothing which is the two double quotes.
2) Remove the dollar sign the same way as the single quote
MyNumber = replace(MyNumber,"$","")
3) Because there is a space between the dollar sign and the number you have
to remove the space. either of the two instructions will work
trim(MyNumber) 'removes spaces from ends of string
val(MyNumber) 'convers string to number
4) If you want to have commas in the number change the format of the cell(s)

"singh" wrote:

> Hi All
>
> For one of my project am getting amount in a different way.
> EG: If amount is $45,455.00 am getting data as $ 45'455.00.
>
> Is there any way we can convert this data??
>
> Thanks in advance.
>

 
Reply With Quote
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Memo format field data problem - Data import to Excel from databas AFSSkier Microsoft Access Queries 3 2nd Jun 2009 06:15 PM
Memo format field data problem - Data import from Access database AFSSkier Microsoft Excel Programming 0 29th Apr 2009 05:51 PM
problem with crystal report dataset: adding new set of data to existing data AboutJAV@gmail.com Microsoft C# .NET 0 16th Nov 2006 02:16 PM
problem with data adapter and data set while inserting and retrieving data aniket_sp Microsoft VB .NET 5 4th Jan 2006 07:10 AM
problem with assigning data from data reader to label control in web form mhnazly Microsoft ASP .NET 1 28th Oct 2003 12:19 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 02:17 AM.