Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Mac Mac is offline
external usenet poster
 
Posts: 213
Default Formatting a cell

I am doing a vlookup in a template that has several year sheet. The common
lookup for this template is in column A and is set up as text ex(0834563)but
when I do the lookup I get na for some of the years and some work okay. I
have tried to set up the column as general but I does not seem to work. Any
suggestions as to when I put in the lookup I get all data for the years I
want? Any help is greatly appreciated.
--
thank you mac
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 622
Default Formatting a cell

On Jun 15, 5:51 pm, mac wrote:
I am doing a vlookup in a template that has several year sheet. The common
lookup for this template is in column A and is set up as text ex(0834563)but
when I do the lookup I get na for some of the years and some work okay. I
have tried to set up the column as general but I does not seem to work. Any
suggestions as to when I put in the lookup I get all data for the years I
want? Any help is greatly appreciated.
--
thank you mac


Are you absolutely sure the lookup value matches the items in the
first column of the database? No spaces, leading zeroes, letter O
instead of numeral 0, or other typo issues.
  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Mac Mac is offline
external usenet poster
 
Posts: 213
Default Formatting a cell

Hello Spiky,

Yes, I have checked every column and the all have general as the format. If
I re-enter the cell it fixes it, but I did not want to rekey all the cells
(250 on each sheet).


thank you mac


"Spiky" wrote:

On Jun 15, 5:51 pm, mac wrote:
I am doing a vlookup in a template that has several year sheet. The common
lookup for this template is in column A and is set up as text ex(0834563)but
when I do the lookup I get na for some of the years and some work okay. I
have tried to set up the column as general but I does not seem to work. Any
suggestions as to when I put in the lookup I get all data for the years I
want? Any help is greatly appreciated.
--
thank you mac


Are you absolutely sure the lookup value matches the items in the
first column of the database? No spaces, leading zeroes, letter O
instead of numeral 0, or other typo issues.

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 360
Default Formatting a cell

If they work after re-entry, then they didn't match prior to re-
entry.

Cell formatting doesn't change the underlying data type - cells
formatted as general can have any data type in them, only the
appearance changes.

If there isn't a compelling reason to format as text, you can convert
the lookup ranges to values which should get your lookups hooked up.
Example:
Sub vert()
With Worksheets("Sheet1").Columns("A")
.NumberFormat = "General"
.Value = .Value
End With
End Sub

To "re-enter" data, you don't have to type it back into the cell -
just select the cell, hit f2 then enter.

Cliff Edwards



  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 622
Default Formatting a cell

On Jun 17, 4:45 am, mac wrote:
Hello Spiky,

Yes, I have checked every column and the all have general as the format. If
I re-enter the cell it fixes it, but I did not want to rekey all the cells
(250 on each sheet).

thank you mac

"Spiky" wrote:
On Jun 15, 5:51 pm, mac wrote:
I am doing a vlookup in a template that has several year sheet. The common
lookup for this template is in column A and is set up as text ex(0834563)but
when I do the lookup I get na for some of the years and some work okay. I
have tried to set up the column as general but I does not seem to work. Any
suggestions as to when I put in the lookup I get all data for the years I
want? Any help is greatly appreciated.
--
thank you mac


Are you absolutely sure the lookup value matches the items in the
first column of the database? No spaces, leading zeroes, letter O
instead of numeral 0, or other typo issues.


Yeah, I didn't mean formats. I meant the actual text/value in the
cell. I always find it best to copy when using Lookups so that I don't
make typos and screw up my calculations. So, enter the Lookup column
data somewhere, then always copy from that to assure 100% matching.


  #6   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 622
Default Formatting a cell

On Jun 17, 8:58 am, ward376 wrote:
If they work after re-entry, then they didn't match prior to re-
entry.



To "re-enter" data, you don't have to type it back into the cell -
just select the cell, hit f2 then enter.

Cliff Edwards


I just wanted to point out that these two comments do not work
together. If "re-entry" fixes a lookup problem because of a typo, then
F2 and Enter are not "re-entry".
  #7   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 360
Default Formatting a cell

You're right, that wasn't very clear. They weren't meant to work
together...

If they work after re-entry, then they didn't match prior to re-
entry.

Re-entering the same info into a cell will prompt Excel to convert the
data into the data type and format it thinks it is, unless the cell is
formatted as text. So re-entering the data may change the data type.

To "re-enter" data, you don't have to type it back into the cell -
just select the cell, hit f2 then enter.

This is a tip, just making sure you knew you didn't have to type every
character into cells, you can just enter edit mode with f2 to "re-
enter" if the issue is the data types not matching between the lookup
value and the lookup table. Of course typos are an entirely different
matter.

Cliff Edwards

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
Protect Cell Formatting including Conditional Formatting Mick Jennings Excel Discussion (Misc queries) 5 November 13th 07 05:32 PM
Conditional Formatting question (if cell = 0, wrap cell in quotes) Mo2 New Users to Excel 6 May 11th 07 11:06 PM
conditional Formatting based on cell formatting Totom Excel Worksheet Functions 3 January 20th 07 02:02 PM
conditional Formatting based on cell formatting Totom Excel Worksheet Functions 0 January 15th 07 04:35 PM
expanding custom formatting without removing existing cell formatting? Keith Excel Worksheet Functions 3 December 27th 06 01:54 PM


All times are GMT +1. The time now is 04:35 PM.

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"