Change format from Text

thingssocomplex

Registered User.
Local time
Today, 23:44
Joined
Feb 9, 2009
Messages
178
Hi

I have the below extract of SQL that I am trying to convert from text when transferred to an Excel file.

Code:
FormatNumber(DateDiff("yyyy",CLFM.DOB,Date()),0,-1)

However when extract it remains text, can anybody help? Below is the link to the site that I tried to use but failed

http://http://office.microsoft.com/en-us/access-help/formatnumber-function-HA001228842.aspx

http://office.microsoft.com/en-us/access-help/formatnumber-function-HA001228842.aspx
 
Are you talking about from Access to Excel or from Excel to Access?

What do you mean by it remains as Text? Can you give us an example?
 
It the file comes in Access text format to retain leading zeros which are required for some outputs from Access to Excel, however for this particular output I need to convert any number (which are currently text) to a general number, which I know will drop the leading zero which needs to occur. When I send to Excel from Access and open the file, the green flag appears stating the column is set to text do you want to convert! I need to avoid this and within the query convert to a number field.
 

Users who are viewing this thread

Back
Top Bottom