View Single Post
  #6   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Ron Coderre
 
Posts: n/a
Default converting text to negative numbers!

I wasn't sure from your post whether you'd solved the problem or not.

i am getting a mix _repeat_ mix of "numbers" and "numbers formatted in text" <


You should be able to use the Text_to_Columns solution that I posted on the
whole column range that includes numbers and numbers formatted as text. The
numeric values will be unaffected while the numbers formatted as text
(including those with trailing minus signs) will be properly converted to
numeric values.

Does that help?

***********
Regards,
Ron

XL2002, WinXP-Pro


"via135" wrote:


sorry Dave!
i accept i am completely new to VB code!

yes RON..! while importing from a .dat file, i am getting a mix
_repeat_ mix of "numbers" and "numbers formatted in text" as given in
my example (100- , 200- , 300-). i want only those numbers to be
converted to negative numbers!

thks!

-via135


Ron Coderre Wrote:
In Excel 2002, you can do this:

Select the range you want converted from text to numbers
DataText-to-Columns
Click the [Next] button twice
Click the [Advanced..] button (on Step 3 of 3)
Check: Trailing minus for negative numbers
Click the [OK] button
Click the [Finish] button

Something you can use?

Regards,
Ron



--
via135
------------------------------------------------------------------------
via135's Profile: http://www.excelforum.com/member.php...o&userid=26725
View this thread: http://www.excelforum.com/showthread...hreadid=507807