Solved

text field  ms excel

Posted on 2014-11-13
5
70 Views
Last Modified: 2014-11-13
q:

I want the last 4 char of a date field in ms excel.

e.g. 1/1/2012  returns 2012.  or 01/1/2012 returns 2012.


restated I want to extract the year from my date field without code.

can anyone help

thanks!
0
Comment
Question by:brianpowell
  • 3
  • 2
5 Comments
 
LVL 7

Accepted Solution

by:
tomfarrar earned 500 total points
ID: 40440586
=year(A1).  A1 being the cell the date is in.
0
 
LVL 1

Author Comment

by:brianpowell
ID: 40440594
ill try it thanks... was thinking in terms of instr.....
0
 
LVL 1

Author Comment

by:brianpowell
ID: 40440607
what does the formatting for A1 need to be:  

bp
0
 
LVL 1

Author Closing Comment

by:brianpowell
ID: 40440609
thanks!
0
 
LVL 7

Expert Comment

by:tomfarrar
ID: 40440613
If the date is text =YEAR(DATEVALUE(A1))
0

Featured Post

NAS Cloud Backup Strategies

This article explains backup scenarios when using network storage. We review the so-called “3-2-1 strategy” and summarize the methods you can use to send NAS data to the cloud

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

This article descibes how to create a connection between Excel and SAP and how to move data from Excel to SAP or the other way around.
Some code to ensure data integrity when using macros within Excel. Also included code that helps secure your data within an Excel workbook.
The viewer will learn how to use the =DISCRINV command to create a discrete random variable, use this command to model a set of probabilities and outcomes in a Monte Carlo simulation, and learn how to find the standard deviation of a set of probabil…
This Micro Tutorial will demonstrate in Google Sheets how to use the HYPERLINK function to create live links inside your spreadsheet.

832 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