ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   start excel and decimal point (https://www.excelbanter.com/excel-programming/302598-start-excel-decimal-point.html)

tonts

start excel and decimal point
 
Hi,

Could anybody help me ?

I have a trouble with starting excel and the local parameters...

I have made a .xls file with a SAS programm. This .xls file contain numeric
fields, text fields, ... and number with decimal point.
The decimal separator is the point(".").

I'm in France, so my local parameters tells excel that the decimal separator
is the comma (",").

When I double-click on the .xls file, the result is good : all the numéric
field with decimals are change from xxx.xx th xxx,xx

But when I start excel from my application SAS and I give the file to open
(.xls), the result is that the decimal fields are not convertef
form xxx.xx to xxx,xx

You can show it if you create a .txt file with NotePad : write 12.23 in the
..txt file, then renamed it in windows in .xls file.
If you double-click on this .xls file, the result is ok : 12.23 converted
into 12,23
But if you start excel and open the .xls file, after the formatting screens,
the result is not ok : the 12.23 is not converted
into 12,23 ....

I'm in excel 2000.

I can't use VBA script or macros because I start excel from SAS.

I'm searching a trick to start excel and tell him he have to take care of
local parameters (and transforming the "." decimal into "," decimal.

Thanks you very much for your help.

Pascal




Dave Peterson[_3_]

start excel and decimal point
 
See one reply at one of your other posts.

It's not usually necessary to post to multiple groups. If you think that it is,
it would be better for you to include all the groups in one post (called
crossposting).

If you send different messages at different times (called multiposting), then it
makes it much more difficult for you to find a correct response. And it just
causes people to duplicate existing answers.

And the part that I would find the worst is that you could have different
threads in various stages of "development". Sometimes, it's very nice to see a
bunch of suggestions that build on each other.

tonts wrote:

Hi,

Could anybody help me ?

I have a trouble with starting excel and the local parameters...

I have made a .xls file with a SAS programm. This .xls file contain numeric
fields, text fields, ... and number with decimal point.
The decimal separator is the point(".").

I'm in France, so my local parameters tells excel that the decimal separator
is the comma (",").

When I double-click on the .xls file, the result is good : all the numéric
field with decimals are change from xxx.xx th xxx,xx

But when I start excel from my application SAS and I give the file to open
(.xls), the result is that the decimal fields are not convertef
form xxx.xx to xxx,xx

You can show it if you create a .txt file with NotePad : write 12.23 in the
.txt file, then renamed it in windows in .xls file.
If you double-click on this .xls file, the result is ok : 12.23 converted
into 12,23
But if you start excel and open the .xls file, after the formatting screens,
the result is not ok : the 12.23 is not converted
into 12,23 ....

I'm in excel 2000.

I can't use VBA script or macros because I start excel from SAS.

I'm searching a trick to start excel and tell him he have to take care of
local parameters (and transforming the "." decimal into "," decimal.

Thanks you very much for your help.

Pascal


--

Dave Peterson


keepITcool

start excel and decimal point
 
a quick seach with google on "excel sas decimal export" shows:
a.o.

http://www.pace.edu/nesug/proceeding.../cc/Cc4011.pdf
http://www2.sas.com/proceedings/sugi28/250-28.pdf

e.g.
this appears to be a typical SAS problem.

renaming a file to xls doesn't make a an xls file.
it will just force excel to be the opening application.

excel is reasonably clever when opening txt files, but
less so when opening .csv files.

try renaming the exported dataset to .txt before you
open it it excel.

if that works...
you might consider making a dummy file extension
(like .SASdat and associate that extension with excel.exe

since it will be an unknown datatype excel will try opening it as a
textfile.

hth



keepITcool

< email : keepitcool chello nl (with @ and .)
< homepage: http://members.chello.nl/keepitcool


"tonts" wrote:

Hi,

Could anybody help me ?

I have a trouble with starting excel and the local parameters...

I have made a .xls file with a SAS programm. This .xls file contain
numeric fields, text fields, ... and number with decimal point.
The decimal separator is the point(".").

I'm in France, so my local parameters tells excel that the decimal
separator is the comma (",").

When I double-click on the .xls file, the result is good : all the
numéric field with decimals are change from xxx.xx th xxx,xx

But when I start excel from my application SAS and I give the file to
open (.xls), the result is that the decimal fields are not convertef
form xxx.xx to xxx,xx

You can show it if you create a .txt file with NotePad : write 12.23
in the .txt file, then renamed it in windows in .xls file.
If you double-click on this .xls file, the result is ok : 12.23
converted into 12,23
But if you start excel and open the .xls file, after the formatting
screens, the result is not ok : the 12.23 is not converted
into 12,23 ....

I'm in excel 2000.

I can't use VBA script or macros because I start excel from SAS.

I'm searching a trick to start excel and tell him he have to take care
of local parameters (and transforming the "." decimal into ","
decimal.

Thanks you very much for your help.

Pascal






tonts

start excel and decimal point
 
ok, I found the solution.

Modifiyng he TAGSET in SAS and add in the head section of the Html the code
below :

style type="text/css"
table {
mso-displayed-decimal-separator: "." ;
}
</style

The numeric fields with decimals are made in SAS with the format xx.xx
(point) and excel change it into a comma (",") in both case (open excel and
load the .xls file or double-click on the .xls file).

Thanks to all




All times are GMT +1. The time now is 05:11 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com