PC Review


Reply
Thread Tools Rate Thread

Cell formats change while opening the file via VB

 
 
SupperDuck
Guest
Posts: n/a
 
      8th Sep 2008
Dear all,

I have a main macro that opens some other excel files. The problem occurs
with only one book.

If we open the file with double clicking on it (no macros), the formats are
ok. But when we try to open it from another file, with the below code;

Sub a()
Set wb = Workbooks.Open(ThisWorkbook.Path & "\Bom_Zebom.xls")
wb.Activate
End Sub

The formats are being changed like;

3,97 changes to 3.970.000
40,68 changes to 40.680.000
0,61 changes to 0,610000

the last value, 0,610000 is in fact " 0,610000" which seems that the
values lower than 1 have around eight spaces within the new file while being
opened with the macro.

Just for your information;

1. The excel data is downloaded from SAP.
2. In Turkish, you use "." to show the multiplies of 1000, and "," to show
the decimal places. For example;

In English;
1,540.8 is written as 1.540,8 in Turkish. May be, the problem occurs because
of that, just an idea.

Could you please help how i can solve this problem ?

Thanks & regards,

Veysel
 
Reply With Quote
 
 
 
 
Joel
Guest
Posts: n/a
 
      8th Sep 2008
I think what is happening is when you double click the file the file is
opening with a different command line option then when you open the file
directly from excel.

Go to the following menu option
1) Right Click Start Button - Select Explore
2) Tools - Folder Options - Folder Types
3) Find XLS
4) Advance - Open - Edit

a) Post the Application used to perform Action. Include any slash options
like /e below

"C:\Program Files\Microsoft Office\Office10\EXCEL.EXE" /e

b) Is DDE checked?

c) What is the DDE message or other box info like: [open("%1")]

"SupperDuck" wrote:

> Dear all,
>
> I have a main macro that opens some other excel files. The problem occurs
> with only one book.
>
> If we open the file with double clicking on it (no macros), the formats are
> ok. But when we try to open it from another file, with the below code;
>
> Sub a()
> Set wb = Workbooks.Open(ThisWorkbook.Path & "\Bom_Zebom.xls")
> wb.Activate
> End Sub
>
> The formats are being changed like;
>
> 3,97 changes to 3.970.000
> 40,68 changes to 40.680.000
> 0,61 changes to 0,610000
>
> the last value, 0,610000 is in fact " 0,610000" which seems that the
> values lower than 1 have around eight spaces within the new file while being
> opened with the macro.
>
> Just for your information;
>
> 1. The excel data is downloaded from SAP.
> 2. In Turkish, you use "." to show the multiplies of 1000, and "," to show
> the decimal places. For example;
>
> In English;
> 1,540.8 is written as 1.540,8 in Turkish. May be, the problem occurs because
> of that, just an idea.
>
> Could you please help how i can solve this problem ?
>
> Thanks & regards,
>
> Veysel

 
Reply With Quote
 
SupperDuck
Guest
Posts: n/a
 
      9th Sep 2008
Dear Joel,

Yesterday, when i was at home i tried to look what you have asked for
(Windows XP), but at work, i could not see the information you have asked.
There could be two reasons;

1. At work, we use Vista, not XP.
2. Maybe, we are limited users (IT departmants do not give whole control to
users...)

How can i see this on Vista? Or, what can i do without knowing the
information?

Thanks & regards,

Veysel

"Joel" wrote:

> I think what is happening is when you double click the file the file is
> opening with a different command line option then when you open the file
> directly from excel.
>
> Go to the following menu option
> 1) Right Click Start Button - Select Explore
> 2) Tools - Folder Options - Folder Types
> 3) Find XLS
> 4) Advance - Open - Edit
>
> a) Post the Application used to perform Action. Include any slash options
> like /e below
>
> "C:\Program Files\Microsoft Office\Office10\EXCEL.EXE" /e
>
> b) Is DDE checked?
>
> c) What is the DDE message or other box info like: [open("%1")]
>
> "SupperDuck" wrote:
>
> > Dear all,
> >
> > I have a main macro that opens some other excel files. The problem occurs
> > with only one book.
> >
> > If we open the file with double clicking on it (no macros), the formats are
> > ok. But when we try to open it from another file, with the below code;
> >
> > Sub a()
> > Set wb = Workbooks.Open(ThisWorkbook.Path & "\Bom_Zebom.xls")
> > wb.Activate
> > End Sub
> >
> > The formats are being changed like;
> >
> > 3,97 changes to 3.970.000
> > 40,68 changes to 40.680.000
> > 0,61 changes to 0,610000
> >
> > the last value, 0,610000 is in fact " 0,610000" which seems that the
> > values lower than 1 have around eight spaces within the new file while being
> > opened with the macro.
> >
> > Just for your information;
> >
> > 1. The excel data is downloaded from SAP.
> > 2. In Turkish, you use "." to show the multiplies of 1000, and "," to show
> > the decimal places. For example;
> >
> > In English;
> > 1,540.8 is written as 1.540,8 in Turkish. May be, the problem occurs because
> > of that, just an idea.
> >
> > Could you please help how i can solve this problem ?
> >
> > Thanks & regards,
> >
> > Veysel

 
Reply With Quote
 
Joel
Guest
Posts: n/a
 
      9th Sep 2008
I have tgo try it on my daughter lap top later today. I will get back. My
other thought would be to check the version of excel using help - about for
each of the two methods you mentioned. I was thinking you may have more than
one version of excel installed on your PC.

"SupperDuck" wrote:

> Dear Joel,
>
> Yesterday, when i was at home i tried to look what you have asked for
> (Windows XP), but at work, i could not see the information you have asked.
> There could be two reasons;
>
> 1. At work, we use Vista, not XP.
> 2. Maybe, we are limited users (IT departmants do not give whole control to
> users...)
>
> How can i see this on Vista? Or, what can i do without knowing the
> information?
>
> Thanks & regards,
>
> Veysel
>
> "Joel" wrote:
>
> > I think what is happening is when you double click the file the file is
> > opening with a different command line option then when you open the file
> > directly from excel.
> >
> > Go to the following menu option
> > 1) Right Click Start Button - Select Explore
> > 2) Tools - Folder Options - Folder Types
> > 3) Find XLS
> > 4) Advance - Open - Edit
> >
> > a) Post the Application used to perform Action. Include any slash options
> > like /e below
> >
> > "C:\Program Files\Microsoft Office\Office10\EXCEL.EXE" /e
> >
> > b) Is DDE checked?
> >
> > c) What is the DDE message or other box info like: [open("%1")]
> >
> > "SupperDuck" wrote:
> >
> > > Dear all,
> > >
> > > I have a main macro that opens some other excel files. The problem occurs
> > > with only one book.
> > >
> > > If we open the file with double clicking on it (no macros), the formats are
> > > ok. But when we try to open it from another file, with the below code;
> > >
> > > Sub a()
> > > Set wb = Workbooks.Open(ThisWorkbook.Path & "\Bom_Zebom.xls")
> > > wb.Activate
> > > End Sub
> > >
> > > The formats are being changed like;
> > >
> > > 3,97 changes to 3.970.000
> > > 40,68 changes to 40.680.000
> > > 0,61 changes to 0,610000
> > >
> > > the last value, 0,610000 is in fact " 0,610000" which seems that the
> > > values lower than 1 have around eight spaces within the new file while being
> > > opened with the macro.
> > >
> > > Just for your information;
> > >
> > > 1. The excel data is downloaded from SAP.
> > > 2. In Turkish, you use "." to show the multiplies of 1000, and "," to show
> > > the decimal places. For example;
> > >
> > > In English;
> > > 1,540.8 is written as 1.540,8 in Turkish. May be, the problem occurs because
> > > of that, just an idea.
> > >
> > > Could you please help how i can solve this problem ?
> > >
> > > Thanks & regards,
> > >
> > > Veysel

 
Reply With Quote
 
SupperDuck
Guest
Posts: n/a
 
      9th Sep 2008
Hello,

I have tried on another computer, which has Win XP that is in our office.

When i try to see the properties, it seems that i do not have permission
(office rules). The picture is as below;


http://img222.imageshack.us/my.php?image=excelcs6.jpg


The data is downloaded from SAP... My computer has only one excel installed
(Office 2003 SP3).

Regards,

Veysel

"Joel" wrote:

> I have tgo try it on my daughter lap top later today. I will get back. My
> other thought would be to check the version of excel using help - about for
> each of the two methods you mentioned. I was thinking you may have more than
> one version of excel installed on your PC.
>
> "SupperDuck" wrote:
>
> > Dear Joel,
> >
> > Yesterday, when i was at home i tried to look what you have asked for
> > (Windows XP), but at work, i could not see the information you have asked.
> > There could be two reasons;
> >
> > 1. At work, we use Vista, not XP.
> > 2. Maybe, we are limited users (IT departmants do not give whole control to
> > users...)
> >
> > How can i see this on Vista? Or, what can i do without knowing the
> > information?
> >
> > Thanks & regards,
> >
> > Veysel
> >
> > "Joel" wrote:
> >
> > > I think what is happening is when you double click the file the file is
> > > opening with a different command line option then when you open the file
> > > directly from excel.
> > >
> > > Go to the following menu option
> > > 1) Right Click Start Button - Select Explore
> > > 2) Tools - Folder Options - Folder Types
> > > 3) Find XLS
> > > 4) Advance - Open - Edit
> > >
> > > a) Post the Application used to perform Action. Include any slash options
> > > like /e below
> > >
> > > "C:\Program Files\Microsoft Office\Office10\EXCEL.EXE" /e
> > >
> > > b) Is DDE checked?
> > >
> > > c) What is the DDE message or other box info like: [open("%1")]
> > >
> > > "SupperDuck" wrote:
> > >
> > > > Dear all,
> > > >
> > > > I have a main macro that opens some other excel files. The problem occurs
> > > > with only one book.
> > > >
> > > > If we open the file with double clicking on it (no macros), the formats are
> > > > ok. But when we try to open it from another file, with the below code;
> > > >
> > > > Sub a()
> > > > Set wb = Workbooks.Open(ThisWorkbook.Path & "\Bom_Zebom.xls")
> > > > wb.Activate
> > > > End Sub
> > > >
> > > > The formats are being changed like;
> > > >
> > > > 3,97 changes to 3.970.000
> > > > 40,68 changes to 40.680.000
> > > > 0,61 changes to 0,610000
> > > >
> > > > the last value, 0,610000 is in fact " 0,610000" which seems that the
> > > > values lower than 1 have around eight spaces within the new file while being
> > > > opened with the macro.
> > > >
> > > > Just for your information;
> > > >
> > > > 1. The excel data is downloaded from SAP.
> > > > 2. In Turkish, you use "." to show the multiplies of 1000, and "," to show
> > > > the decimal places. For example;
> > > >
> > > > In English;
> > > > 1,540.8 is written as 1.540,8 in Turkish. May be, the problem occurs because
> > > > of that, just an idea.
> > > >
> > > > Could you please help how i can solve this problem ?
> > > >
> > > > Thanks & regards,
> > > >
> > > > Veysel

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
"Too Many Cell Formats" Error when opening a 2007 XLS file in 2003 James Microsoft Excel Misc 0 3rd Nov 2009 02:14 AM
Can you view cell formats without opening the formatting window =?Utf-8?B?TWlrZQ==?= Microsoft Excel Misc 2 17th Nov 2007 12:31 AM
"Too many different cell formats" is preventing file from opening =?Utf-8?B?SmVk?= Microsoft Excel Misc 1 30th Sep 2005 09:40 PM
"Too many different cell formats" when opening file????? =?Utf-8?B?UiBUb3JiZXJ0?= Microsoft Excel Misc 1 20th Sep 2004 02:34 PM
Error message opening a file due to too many different cell formats lc Microsoft Excel Misc 4 16th Jul 2004 10:13 PM


Features
 

Advertising
 

Newsgroups
 


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