Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Eric
 
Posts: n/a
Default Adding text before a function

How do you add text before you run a function? For instance, I want
to put a + prior to running a datedif function so the out come comes
back +7 days.

i.e. Taking the date range in A1 as 15-Oct and A2 20-Oct i want it to
display +5 days. I have it so that I can do it as 5 days, but I want
the "+" in there as well: datedif(A1,A2,"d")&" days"


Any ideas?
  #2   Report Post  
Ken Wright
 
Posts: n/a
Default

Seeing as you have already made your data text

="+"&datedif(A1,A2,"d")&" days"

Format / Cells / Custom and +0 "Days" would have done the same
leaving it as a numeric field.

--
Regards
Ken....................... Microsoft MVP - Excel
Sys Spec - Win XP Pro / XL 97/00/02/03

----------------------------------------------------------------------------
It's easier to beg forgiveness than ask permission :-)
----------------------------------------------------------------------------



"Eric" wrote in message
om...
How do you add text before you run a function? For instance, I want
to put a + prior to running a datedif function so the out come comes
back +7 days.

i.e. Taking the date range in A1 as 15-Oct and A2 20-Oct i want it to
display +5 days. I have it so that I can do it as 5 days, but I want
the "+" in there as well: datedif(A1,A2,"d")&" days"


Any ideas?



---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.788 / Virus Database: 533 - Release Date: 01/11/2004


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
adding to a number containing text R D S Excel Discussion (Misc queries) 4 January 21st 05 04:55 AM
Adding Leading Zeros to Text Jenn Excel Discussion (Misc queries) 4 January 12th 05 07:51 PM
Read Text File into Excel Using VBA Willie T Excel Discussion (Misc queries) 13 January 8th 05 01:37 AM
Macro or Function to make text size to suite text Length? lbbss Excel Discussion (Misc queries) 4 December 14th 04 08:53 PM
Adding a text label to a line. Neil Charts and Charting in Excel 1 December 4th 04 09:41 PM


All times are GMT +1. The time now is 09:34 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"