Book Image

Data Analysis and Business Modeling with Excel 2013

Book Image

Data Analysis and Business Modeling with Excel 2013

Overview of this book

Table of Contents (18 chapters)
Data Analysis and Business Modeling with Excel 2013
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
10
Creating Interactive Spreadsheets Using Tables and Slicers
Index

Text to dates


Dates are one of those words that can either make you smile or make you frown. In the past I have had many issues dealing with dates but without them, I would not be able to answer the questions I was tasked with. One of the most common issues is having your dates formatted as strings. In Excel, if your dates are treated as strings, any formulas that are meant for date cells will fail. The following steps will help you get around this issue:

  1. Open the spreadsheet in the Chapter 03 folder named Chapter 3 – Lesson 7.xlsx.

    You will have a dataset that is similar to the one in the following screenshot:

    Figure 3.48

    Notice that we added a single quote in front of the strings to trick Excel into thinking that these are strings and not dates.

  2. Select cell A2 and press Ctrl + 1 on your keyboard. You will get a dialog box telling you what the data type of cell A2 is, as shown in the following screenshot. It says that the cell is of the General category. This basically means that it treats the...