473,287 Members | 1,866 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,287 software developers and data experts.

Stumped - VB6 Com Obj can't access MS Excel

This most likely belongs in another forum but I thought I'd start here. I
have a COM Object written in VB6. The DLL will access MS Excel and use it's
Object Library to write a customized report and saves it to a folder. The
DLL even writes to a log for each step it takes so we can troubleshoot the
problems (if any).

This works fine on one machine but not another. The folder the DLL is trying
to write to has full permissions assigned to and is wide open. Furthermore,
the log txt file is being written in the same folder with no problems so I
know it's not a folder permissions issue. The problem seems to be when the
DLL tries to access MS Excel. The DLL is simple told "permission denied" by
Windows.

I would appreciate any pointers!

Nov 19 '05 #1
12 2385
Joe
Permission denied to what? The Excel workbook? Directory? You don't know?

This is an off-the-cuff guess: are you creating multiple instances of Excel
and not quitting each one when done using the application?

Just a guess.

HTH,
--
Joe

VB.NET/C#/ASP.NET/ASP/VB/C++/Web and DB development/VBA Automation
"D. Shane Fowlkes" wrote:
This most likely belongs in another forum but I thought I'd start here. I
have a COM Object written in VB6. The DLL will access MS Excel and use it's
Object Library to write a customized report and saves it to a folder. The
DLL even writes to a log for each step it takes so we can troubleshoot the
problems (if any).

This works fine on one machine but not another. The folder the DLL is trying
to write to has full permissions assigned to and is wide open. Furthermore,
the log txt file is being written in the same folder with no problems so I
know it's not a folder permissions issue. The problem seems to be when the
DLL tries to access MS Excel. The DLL is simple told "permission denied" by
Windows.

I would appreciate any pointers!

Nov 19 '05 #2
I don't think so. It failed on the first attempt.

The best was I can describe it is that the DLL is being denied permission to
Excel itself. Excel is installed on the machine just for this function. The
log we have tracks every single move and action and seems to be denied
access to Excel immediately as soon as it tries to access it. I'm 99% sure
this isn't a folder permissions issue.


"Joe" <jo******@donotspam.yahoo.com> wrote in message
news:DB**********************************@microsof t.com...
Permission denied to what? The Excel workbook? Directory? You don't
know?

This is an off-the-cuff guess: are you creating multiple instances of
Excel
and not quitting each one when done using the application?

Just a guess.

HTH,
--
Joe

VB.NET/C#/ASP.NET/ASP/VB/C++/Web and DB development/VBA Automation
"D. Shane Fowlkes" wrote:
This most likely belongs in another forum but I thought I'd start here.
I
have a COM Object written in VB6. The DLL will access MS Excel and use
it's
Object Library to write a customized report and saves it to a folder.
The
DLL even writes to a log for each step it takes so we can troubleshoot
the
problems (if any).

This works fine on one machine but not another. The folder the DLL is
trying
to write to has full permissions assigned to and is wide open.
Furthermore,
the log txt file is being written in the same folder with no problems so
I
know it's not a folder permissions issue. The problem seems to be when
the
DLL tries to access MS Excel. The DLL is simple told "permission denied"
by
Windows.

I would appreciate any pointers!

Nov 19 '05 #3
Joe
Do you know that the DLL works with other apps? If not, do you have source
code?
--
Joe

VB.NET/C#/ASP.NET/ASP/VB/C++/Web and DB development/VBA Automation
"D. Shane Fowlkes" wrote:
I don't think so. It failed on the first attempt.

The best was I can describe it is that the DLL is being denied permission to
Excel itself. Excel is installed on the machine just for this function. The
log we have tracks every single move and action and seems to be denied
access to Excel immediately as soon as it tries to access it. I'm 99% sure
this isn't a folder permissions issue.


"Joe" <jo******@donotspam.yahoo.com> wrote in message
news:DB**********************************@microsof t.com...
Permission denied to what? The Excel workbook? Directory? You don't
know?

This is an off-the-cuff guess: are you creating multiple instances of
Excel
and not quitting each one when done using the application?

Just a guess.

HTH,
--
Joe

VB.NET/C#/ASP.NET/ASP/VB/C++/Web and DB development/VBA Automation
"D. Shane Fowlkes" wrote:
This most likely belongs in another forum but I thought I'd start here.
I
have a COM Object written in VB6. The DLL will access MS Excel and use
it's
Object Library to write a customized report and saves it to a folder.
The
DLL even writes to a log for each step it takes so we can troubleshoot
the
problems (if any).

This works fine on one machine but not another. The folder the DLL is
trying
to write to has full permissions assigned to and is wide open.
Furthermore,
the log txt file is being written in the same folder with no problems so
I
know it's not a folder permissions issue. The problem seems to be when
the
DLL tries to access MS Excel. The DLL is simple told "permission denied"
by
Windows.

I would appreciate any pointers!


Nov 19 '05 #4
It works on two other servers. Nothing special was done to these other
servers.

Would I need to assign or check some obscure system user account like IWAM_
special permissions or something to the EXCEL.EXE file or something? Again,
I can find anything unusual on the machines it does work on.

"Joe" <jo******@donotspam.yahoo.com> wrote in message
news:6D**********************************@microsof t.com...
Do you know that the DLL works with other apps? If not, do you have
source
code?
--
Joe

VB.NET/C#/ASP.NET/ASP/VB/C++/Web and DB development/VBA Automation
"D. Shane Fowlkes" wrote:
I don't think so. It failed on the first attempt.

The best was I can describe it is that the DLL is being denied permission
to
Excel itself. Excel is installed on the machine just for this function.
The
log we have tracks every single move and action and seems to be denied
access to Excel immediately as soon as it tries to access it. I'm 99%
sure
this isn't a folder permissions issue.


"Joe" <jo******@donotspam.yahoo.com> wrote in message
news:DB**********************************@microsof t.com...
> Permission denied to what? The Excel workbook? Directory? You don't
> know?
>
> This is an off-the-cuff guess: are you creating multiple instances of
> Excel
> and not quitting each one when done using the application?
>
> Just a guess.
>
> HTH,
> --
> Joe
>
> VB.NET/C#/ASP.NET/ASP/VB/C++/Web and DB development/VBA Automation
>
>
> "D. Shane Fowlkes" wrote:
>
>> This most likely belongs in another forum but I thought I'd start
>> here.
>> I
>> have a COM Object written in VB6. The DLL will access MS Excel and
>> use
>> it's
>> Object Library to write a customized report and saves it to a folder.
>> The
>> DLL even writes to a log for each step it takes so we can troubleshoot
>> the
>> problems (if any).
>>
>> This works fine on one machine but not another. The folder the DLL is
>> trying
>> to write to has full permissions assigned to and is wide open.
>> Furthermore,
>> the log txt file is being written in the same folder with no problems
>> so
>> I
>> know it's not a folder permissions issue. The problem seems to be when
>> the
>> DLL tries to access MS Excel. The DLL is simple told "permission
>> denied"
>> by
>> Windows.
>>
>> I would appreciate any pointers!
>>
>>
>>
>>


Nov 19 '05 #5
Joe
So if you know that this web app runs on two other servers, the problem must
be on the third server. Does that DLL automate any other apps? As far as I
know, Excel doesn't require any special permissions to run. So see what else
is different. Compare IIS permissions; unregister and reregister the DLL;
etc.

Wish I could contribute more, but there are too many unknowns.
--
Joe

VB.NET/C#/ASP.NET/ASP/VB/C++/Web and DB development/VBA Automation
"D. Shane Fowlkes" wrote:
It works on two other servers. Nothing special was done to these other
servers.

Would I need to assign or check some obscure system user account like IWAM_
special permissions or something to the EXCEL.EXE file or something? Again,
I can find anything unusual on the machines it does work on.

"Joe" <jo******@donotspam.yahoo.com> wrote in message
news:6D**********************************@microsof t.com...
Do you know that the DLL works with other apps? If not, do you have
source
code?
--
Joe

VB.NET/C#/ASP.NET/ASP/VB/C++/Web and DB development/VBA Automation
"D. Shane Fowlkes" wrote:
I don't think so. It failed on the first attempt.

The best was I can describe it is that the DLL is being denied permission
to
Excel itself. Excel is installed on the machine just for this function.
The
log we have tracks every single move and action and seems to be denied
access to Excel immediately as soon as it tries to access it. I'm 99%
sure
this isn't a folder permissions issue.


"Joe" <jo******@donotspam.yahoo.com> wrote in message
news:DB**********************************@microsof t.com...
> Permission denied to what? The Excel workbook? Directory? You don't
> know?
>
> This is an off-the-cuff guess: are you creating multiple instances of
> Excel
> and not quitting each one when done using the application?
>
> Just a guess.
>
> HTH,
> --
> Joe
>
> VB.NET/C#/ASP.NET/ASP/VB/C++/Web and DB development/VBA Automation
>
>
> "D. Shane Fowlkes" wrote:
>
>> This most likely belongs in another forum but I thought I'd start
>> here.
>> I
>> have a COM Object written in VB6. The DLL will access MS Excel and
>> use
>> it's
>> Object Library to write a customized report and saves it to a folder.
>> The
>> DLL even writes to a log for each step it takes so we can troubleshoot
>> the
>> problems (if any).
>>
>> This works fine on one machine but not another. The folder the DLL is
>> trying
>> to write to has full permissions assigned to and is wide open.
>> Furthermore,
>> the log txt file is being written in the same folder with no problems
>> so
>> I
>> know it's not a folder permissions issue. The problem seems to be when
>> the
>> DLL tries to access MS Excel. The DLL is simple told "permission
>> denied"
>> by
>> Windows.
>>
>> I would appreciate any pointers!
>>
>>
>>
>>


Nov 19 '05 #6
Thanks for your help. The problem is that the issue is on the live web
server which is run by a 3rd party. They're not inclined to address the
issue since it's such a special request. The best I can do is ask that they
check this and check that. But unless I know what is actually causing the
issues, I'm stuck. They're simply going to deny anything is wrong on their
since everything they keep checking ..things I blindy guess at....seems OK.


"Joe" <jo******@donotspam.yahoo.com> wrote in message
news:B1**********************************@microsof t.com...
So if you know that this web app runs on two other servers, the problem
must
be on the third server. Does that DLL automate any other apps? As far as
I
know, Excel doesn't require any special permissions to run. So see what
else
is different. Compare IIS permissions; unregister and reregister the DLL;
etc.

Wish I could contribute more, but there are too many unknowns.
--
Joe

VB.NET/C#/ASP.NET/ASP/VB/C++/Web and DB development/VBA Automation
"D. Shane Fowlkes" wrote:
It works on two other servers. Nothing special was done to these other
servers.

Would I need to assign or check some obscure system user account like
IWAM_
special permissions or something to the EXCEL.EXE file or something?
Again,
I can find anything unusual on the machines it does work on.

"Joe" <jo******@donotspam.yahoo.com> wrote in message
news:6D**********************************@microsof t.com...
> Do you know that the DLL works with other apps? If not, do you have
> source
> code?
> --
> Joe
>
> VB.NET/C#/ASP.NET/ASP/VB/C++/Web and DB development/VBA Automation
>
>
> "D. Shane Fowlkes" wrote:
>
>> I don't think so. It failed on the first attempt.
>>
>> The best was I can describe it is that the DLL is being denied
>> permission
>> to
>> Excel itself. Excel is installed on the machine just for this
>> function.
>> The
>> log we have tracks every single move and action and seems to be denied
>> access to Excel immediately as soon as it tries to access it. I'm 99%
>> sure
>> this isn't a folder permissions issue.
>>
>>
>>
>>
>> "Joe" <jo******@donotspam.yahoo.com> wrote in message
>> news:DB**********************************@microsof t.com...
>> > Permission denied to what? The Excel workbook? Directory? You
>> > don't
>> > know?
>> >
>> > This is an off-the-cuff guess: are you creating multiple instances
>> > of
>> > Excel
>> > and not quitting each one when done using the application?
>> >
>> > Just a guess.
>> >
>> > HTH,
>> > --
>> > Joe
>> >
>> > VB.NET/C#/ASP.NET/ASP/VB/C++/Web and DB development/VBA Automation
>> >
>> >
>> > "D. Shane Fowlkes" wrote:
>> >
>> >> This most likely belongs in another forum but I thought I'd start
>> >> here.
>> >> I
>> >> have a COM Object written in VB6. The DLL will access MS Excel and
>> >> use
>> >> it's
>> >> Object Library to write a customized report and saves it to a
>> >> folder.
>> >> The
>> >> DLL even writes to a log for each step it takes so we can
>> >> troubleshoot
>> >> the
>> >> problems (if any).
>> >>
>> >> This works fine on one machine but not another. The folder the DLL
>> >> is
>> >> trying
>> >> to write to has full permissions assigned to and is wide open.
>> >> Furthermore,
>> >> the log txt file is being written in the same folder with no
>> >> problems
>> >> so
>> >> I
>> >> know it's not a folder permissions issue. The problem seems to be
>> >> when
>> >> the
>> >> DLL tries to access MS Excel. The DLL is simple told "permission
>> >> denied"
>> >> by
>> >> Windows.
>> >>
>> >> I would appreciate any pointers!
>> >>
>> >>
>> >>
>> >>
>>
>>
>>


Nov 19 '05 #7
Source Code:
Public Function POPSpreadsheet(DB .) As Variant

'================================================= =======================

'Create the selected Program Of Projects reports on an Excel spreadsheet

'================================================= =======================

Dim xlApp As Excel.Application

Dim xlTemplate As Excel.Workbook

Dim xlSheet As Excel.Worksheet

'Begin Log entry

Call WriteLogFile(LOG_FILE_NAME,
"============================================= ")

Call WriteLogFile(LOG_FILE_NAME, "Beginning POPSpreadsheet Function. DB
= " & DB)

'Open Excel

Call WriteLogFile(LOG_FILE_NAME, "About to begin Excel.")

Set xlApp = CreateObject("Excel.Application")

Call WriteLogFile(LOG_FILE_NAME, "Excel running.")



It seems to be failing on Set xlApp = CreateObject(("Excel.Application")

Thanks again

"Joe" <jo******@donotspam.yahoo.com> wrote in message
news:B1**********************************@microsof t.com...
So if you know that this web app runs on two other servers, the problem
must
be on the third server. Does that DLL automate any other apps? As far as
I
know, Excel doesn't require any special permissions to run. So see what
else
is different. Compare IIS permissions; unregister and reregister the DLL;
etc.

Wish I could contribute more, but there are too many unknowns.
--
Joe

VB.NET/C#/ASP.NET/ASP/VB/C++/Web and DB development/VBA Automation
"D. Shane Fowlkes" wrote:
It works on two other servers. Nothing special was done to these other
servers.

Would I need to assign or check some obscure system user account like
IWAM_
special permissions or something to the EXCEL.EXE file or something?
Again,
I can find anything unusual on the machines it does work on.

"Joe" <jo******@donotspam.yahoo.com> wrote in message
news:6D**********************************@microsof t.com...
> Do you know that the DLL works with other apps? If not, do you have
> source
> code?
> --
> Joe
>
> VB.NET/C#/ASP.NET/ASP/VB/C++/Web and DB development/VBA Automation
>
>
> "D. Shane Fowlkes" wrote:
>
>> I don't think so. It failed on the first attempt.
>>
>> The best was I can describe it is that the DLL is being denied
>> permission
>> to
>> Excel itself. Excel is installed on the machine just for this
>> function.
>> The
>> log we have tracks every single move and action and seems to be denied
>> access to Excel immediately as soon as it tries to access it. I'm 99%
>> sure
>> this isn't a folder permissions issue.
>>
>>
>>
>>
>> "Joe" <jo******@donotspam.yahoo.com> wrote in message
>> news:DB**********************************@microsof t.com...
>> > Permission denied to what? The Excel workbook? Directory? You
>> > don't
>> > know?
>> >
>> > This is an off-the-cuff guess: are you creating multiple instances
>> > of
>> > Excel
>> > and not quitting each one when done using the application?
>> >
>> > Just a guess.
>> >
>> > HTH,
>> > --
>> > Joe
>> >
>> > VB.NET/C#/ASP.NET/ASP/VB/C++/Web and DB development/VBA Automation
>> >
>> >
>> > "D. Shane Fowlkes" wrote:
>> >
>> >> This most likely belongs in another forum but I thought I'd start
>> >> here.
>> >> I
>> >> have a COM Object written in VB6. The DLL will access MS Excel and
>> >> use
>> >> it's
>> >> Object Library to write a customized report and saves it to a
>> >> folder.
>> >> The
>> >> DLL even writes to a log for each step it takes so we can
>> >> troubleshoot
>> >> the
>> >> problems (if any).
>> >>
>> >> This works fine on one machine but not another. The folder the DLL
>> >> is
>> >> trying
>> >> to write to has full permissions assigned to and is wide open.
>> >> Furthermore,
>> >> the log txt file is being written in the same folder with no
>> >> problems
>> >> so
>> >> I
>> >> know it's not a folder permissions issue. The problem seems to be
>> >> when
>> >> the
>> >> DLL tries to access MS Excel. The DLL is simple told "permission
>> >> denied"
>> >> by
>> >> Windows.
>> >>
>> >> I would appreciate any pointers!
>> >>
>> >>
>> >>
>> >>
>>
>>
>>


Nov 19 '05 #8
"D. Shane Fowlkes" <sh**********@h-o-t-m-a-i-l.com> wrote in message
news:Og**************@TK2MSFTNGP09.phx.gbl...
This most likely belongs in another forum but I thought I'd start here.


Well, it clearly has little if anything to do with ASP.NET...

Did you try any of the VB6 forums? Or the Excel forums?
Nov 19 '05 #9
Joe
Shane,

Set a reference in your VB6 DLL to the Excel object library. Use that
referemnce when creating an Excel app object.

Dim xlApp as Excel.Application
Set xlApp = new Excel.Application

blah blah blah

xlApp.Quit
Set xlApp = Nothing

HTH,
--
Joe

VB.NET/C#/ASP.NET/ASP/VB/C++/Web and DB development/VBA Automation
"D. Shane Fowlkes" wrote:
Source Code:
Public Function POPSpreadsheet(DB .) As Variant

'================================================= =======================

'Create the selected Program Of Projects reports on an Excel spreadsheet

'================================================= =======================

Dim xlApp As Excel.Application

Dim xlTemplate As Excel.Workbook

Dim xlSheet As Excel.Worksheet

'Begin Log entry

Call WriteLogFile(LOG_FILE_NAME,
"============================================= ")

Call WriteLogFile(LOG_FILE_NAME, "Beginning POPSpreadsheet Function. DB
= " & DB)

'Open Excel

Call WriteLogFile(LOG_FILE_NAME, "About to begin Excel.")

Set xlApp = CreateObject("Excel.Application")

Call WriteLogFile(LOG_FILE_NAME, "Excel running.")



It seems to be failing on Set xlApp = CreateObject(("Excel.Application")

Thanks again

"Joe" <jo******@donotspam.yahoo.com> wrote in message
news:B1**********************************@microsof t.com...
So if you know that this web app runs on two other servers, the problem
must
be on the third server. Does that DLL automate any other apps? As far as
I
know, Excel doesn't require any special permissions to run. So see what
else
is different. Compare IIS permissions; unregister and reregister the DLL;
etc.

Wish I could contribute more, but there are too many unknowns.
--
Joe

VB.NET/C#/ASP.NET/ASP/VB/C++/Web and DB development/VBA Automation
"D. Shane Fowlkes" wrote:
It works on two other servers. Nothing special was done to these other
servers.

Would I need to assign or check some obscure system user account like
IWAM_
special permissions or something to the EXCEL.EXE file or something?
Again,
I can find anything unusual on the machines it does work on.

"Joe" <jo******@donotspam.yahoo.com> wrote in message
news:6D**********************************@microsof t.com...
> Do you know that the DLL works with other apps? If not, do you have
> source
> code?
> --
> Joe
>
> VB.NET/C#/ASP.NET/ASP/VB/C++/Web and DB development/VBA Automation
>
>
> "D. Shane Fowlkes" wrote:
>
>> I don't think so. It failed on the first attempt.
>>
>> The best was I can describe it is that the DLL is being denied
>> permission
>> to
>> Excel itself. Excel is installed on the machine just for this
>> function.
>> The
>> log we have tracks every single move and action and seems to be denied
>> access to Excel immediately as soon as it tries to access it. I'm 99%
>> sure
>> this isn't a folder permissions issue.
>>
>>
>>
>>
>> "Joe" <jo******@donotspam.yahoo.com> wrote in message
>> news:DB**********************************@microsof t.com...
>> > Permission denied to what? The Excel workbook? Directory? You
>> > don't
>> > know?
>> >
>> > This is an off-the-cuff guess: are you creating multiple instances
>> > of
>> > Excel
>> > and not quitting each one when done using the application?
>> >
>> > Just a guess.
>> >
>> > HTH,
>> > --
>> > Joe
>> >
>> > VB.NET/C#/ASP.NET/ASP/VB/C++/Web and DB development/VBA Automation
>> >
>> >
>> > "D. Shane Fowlkes" wrote:
>> >
>> >> This most likely belongs in another forum but I thought I'd start
>> >> here.
>> >> I
>> >> have a COM Object written in VB6. The DLL will access MS Excel and
>> >> use
>> >> it's
>> >> Object Library to write a customized report and saves it to a
>> >> folder.
>> >> The
>> >> DLL even writes to a log for each step it takes so we can
>> >> troubleshoot
>> >> the
>> >> problems (if any).
>> >>
>> >> This works fine on one machine but not another. The folder the DLL
>> >> is
>> >> trying
>> >> to write to has full permissions assigned to and is wide open.
>> >> Furthermore,
>> >> the log txt file is being written in the same folder with no
>> >> problems
>> >> so
>> >> I
>> >> know it's not a folder permissions issue. The problem seems to be
>> >> when
>> >> the
>> >> DLL tries to access MS Excel. The DLL is simple told "permission
>> >> denied"
>> >> by
>> >> Windows.
>> >>
>> >> I would appreciate any pointers!
>> >>
>> >>
>> >>
>> >>
>>
>>
>>


Nov 19 '05 #10
Thanks Joe. Not my code but will try it out.

"Joe" <jo******@donotspam.yahoo.com> wrote in message
news:95**********************************@microsof t.com...
Shane,

Set a reference in your VB6 DLL to the Excel object library. Use that
referemnce when creating an Excel app object.

Dim xlApp as Excel.Application
Set xlApp = new Excel.Application

blah blah blah

xlApp.Quit
Set xlApp = Nothing

HTH,
--
Joe

VB.NET/C#/ASP.NET/ASP/VB/C++/Web and DB development/VBA Automation
"D. Shane Fowlkes" wrote:
Source Code:
Public Function POPSpreadsheet(DB .) As Variant


'================================================= =======================

'Create the selected Program Of Projects reports on an Excel
spreadsheet
'================================================= =======================

Dim xlApp As Excel.Application

Dim xlTemplate As Excel.Workbook

Dim xlSheet As Excel.Worksheet

'Begin Log entry

Call WriteLogFile(LOG_FILE_NAME,
"============================================= ")

Call WriteLogFile(LOG_FILE_NAME, "Beginning POPSpreadsheet Function.
DB
= " & DB)

'Open Excel

Call WriteLogFile(LOG_FILE_NAME, "About to begin Excel.")

Set xlApp = CreateObject("Excel.Application")

Call WriteLogFile(LOG_FILE_NAME, "Excel running.")



It seems to be failing on Set xlApp = CreateObject(("Excel.Application")

Thanks again

"Joe" <jo******@donotspam.yahoo.com> wrote in message
news:B1**********************************@microsof t.com...
> So if you know that this web app runs on two other servers, the problem
> must
> be on the third server. Does that DLL automate any other apps? As far
> as
> I
> know, Excel doesn't require any special permissions to run. So see
> what
> else
> is different. Compare IIS permissions; unregister and reregister the
> DLL;
> etc.
>
> Wish I could contribute more, but there are too many unknowns.
> --
> Joe
>
> VB.NET/C#/ASP.NET/ASP/VB/C++/Web and DB development/VBA Automation
>
>
> "D. Shane Fowlkes" wrote:
>
>> It works on two other servers. Nothing special was done to these other
>> servers.
>>
>> Would I need to assign or check some obscure system user account like
>> IWAM_
>> special permissions or something to the EXCEL.EXE file or something?
>> Again,
>> I can find anything unusual on the machines it does work on.
>>
>>
>>
>> "Joe" <jo******@donotspam.yahoo.com> wrote in message
>> news:6D**********************************@microsof t.com...
>> > Do you know that the DLL works with other apps? If not, do you have
>> > source
>> > code?
>> > --
>> > Joe
>> >
>> > VB.NET/C#/ASP.NET/ASP/VB/C++/Web and DB development/VBA Automation
>> >
>> >
>> > "D. Shane Fowlkes" wrote:
>> >
>> >> I don't think so. It failed on the first attempt.
>> >>
>> >> The best was I can describe it is that the DLL is being denied
>> >> permission
>> >> to
>> >> Excel itself. Excel is installed on the machine just for this
>> >> function.
>> >> The
>> >> log we have tracks every single move and action and seems to be
>> >> denied
>> >> access to Excel immediately as soon as it tries to access it. I'm
>> >> 99%
>> >> sure
>> >> this isn't a folder permissions issue.
>> >>
>> >>
>> >>
>> >>
>> >> "Joe" <jo******@donotspam.yahoo.com> wrote in message
>> >> news:DB**********************************@microsof t.com...
>> >> > Permission denied to what? The Excel workbook? Directory? You
>> >> > don't
>> >> > know?
>> >> >
>> >> > This is an off-the-cuff guess: are you creating multiple
>> >> > instances
>> >> > of
>> >> > Excel
>> >> > and not quitting each one when done using the application?
>> >> >
>> >> > Just a guess.
>> >> >
>> >> > HTH,
>> >> > --
>> >> > Joe
>> >> >
>> >> > VB.NET/C#/ASP.NET/ASP/VB/C++/Web and DB development/VBA
>> >> > Automation
>> >> >
>> >> >
>> >> > "D. Shane Fowlkes" wrote:
>> >> >
>> >> >> This most likely belongs in another forum but I thought I'd
>> >> >> start
>> >> >> here.
>> >> >> I
>> >> >> have a COM Object written in VB6. The DLL will access MS Excel
>> >> >> and
>> >> >> use
>> >> >> it's
>> >> >> Object Library to write a customized report and saves it to a
>> >> >> folder.
>> >> >> The
>> >> >> DLL even writes to a log for each step it takes so we can
>> >> >> troubleshoot
>> >> >> the
>> >> >> problems (if any).
>> >> >>
>> >> >> This works fine on one machine but not another. The folder the
>> >> >> DLL
>> >> >> is
>> >> >> trying
>> >> >> to write to has full permissions assigned to and is wide open.
>> >> >> Furthermore,
>> >> >> the log txt file is being written in the same folder with no
>> >> >> problems
>> >> >> so
>> >> >> I
>> >> >> know it's not a folder permissions issue. The problem seems to
>> >> >> be
>> >> >> when
>> >> >> the
>> >> >> DLL tries to access MS Excel. The DLL is simple told
>> >> >> "permission
>> >> >> denied"
>> >> >> by
>> >> >> Windows.
>> >> >>
>> >> >> I would appreciate any pointers!
>> >> >>
>> >> >>
>> >> >>
>> >> >>
>> >>
>> >>
>> >>
>>
>>
>>


Nov 19 '05 #11

"D. Shane Fowlkes" <sh**********@h-o-t-m-a-i-l.com> wrote in message
news:Og**************@TK2MSFTNGP09.phx.gbl...
This most likely belongs in another forum but I thought I'd start here. I
have a COM Object written in VB6. The DLL will access MS Excel and use
it's Object Library to write a customized report and saves it to a folder.
The DLL even writes to a log for each step it takes so we can troubleshoot
the problems (if any).

This works fine on one machine but not another. The folder the DLL is
trying to write to has full permissions assigned to and is wide open.
Furthermore, the log txt file is being written in the same folder with no
problems so I know it's not a folder permissions issue. The problem seems
to be when the DLL tries to access MS Excel. The DLL is simple told
"permission denied" by Windows.

I would appreciate any pointers!


It sounds as though excel is indeed installed on the server.
This is just a guess, but you may have to use dcomcnfg to give permissions
to the interactive user.
Might be tough to do on someone else's server though.


Nov 19 '05 #12
Would you mind elaborating on the "interactive user"? You're on the right
track, Microsoft referrs to the dcomcnfg due to the error logged: 10003.

The server guys are in denial and I want to point them in the right
direction.

Thanks!!
"logan" <lo***@ndgkbajhajksdgvb.com> wrote in message
news:Op****************@TK2MSFTNGP14.phx.gbl...

"D. Shane Fowlkes" <sh**********@h-o-t-m-a-i-l.com> wrote in message
news:Og**************@TK2MSFTNGP09.phx.gbl...
This most likely belongs in another forum but I thought I'd start here.
I have a COM Object written in VB6. The DLL will access MS Excel and use
it's Object Library to write a customized report and saves it to a
folder. The DLL even writes to a log for each step it takes so we can
troubleshoot the problems (if any).

This works fine on one machine but not another. The folder the DLL is
trying to write to has full permissions assigned to and is wide open.
Furthermore, the log txt file is being written in the same folder with no
problems so I know it's not a folder permissions issue. The problem seems
to be when the DLL tries to access MS Excel. The DLL is simple told
"permission denied" by Windows.

I would appreciate any pointers!


It sounds as though excel is indeed installed on the server.
This is just a guess, but you may have to use dcomcnfg to give
permissions to the interactive user.
Might be tough to do on someone else's server though.

Nov 19 '05 #13

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

10
by: Manny | last post by:
I have a web form "Page1.asp" and it reads data from a database, does some calculations, and displays the records in pages. Works fine. I have a button that displays on the page, defined as...
4
by: Kathleen Turner | last post by:
I have an Excel file that has list of serial numbers followed by a 4 digit code. I have an Access database that has the serial numbers but the field for the 4 digit code is either blank, has the 4...
11
by: Mr. Smith | last post by:
Hello all, My code can successfully open, write to, format and save several worksheets in a workbook then save it by a given name, close and quit excel. My problem is that if I try and do it...
0
by: Jack | last post by:
Windows 2K Pro Access/Excel 2003 Hi there, I have a large number of password protected Excel Workbooks. The files are protected by code that runs when the workbook opens. The code asks the...
52
by: Neil | last post by:
We are running an Access 2000 MDB with a SQL 7 back end. Our network guy is upgrading to Windows Server 2003 and wants to upgrade Office and SQL Server at the same time. We're moving to SQL Server...
4
by: somanyusernamesaretakenal | last post by:
What I am trying to achieve: Basically I have generated a report in access. This report needs to be updated using excel. (Updating the new data, not changing existing data) What I did was I...
1
by: tc | last post by:
Hi. I have a customer who is running our .net application, multiple clients connecting to an Access database. This ONE customer reports a great speed degredation when more than one client is...
0
by: blainegray | last post by:
Greetings This is one of those Access is not closing Excel problems. The first time through the code works fine. The second time there is a problem. After lots of combinations, I finally...
1
by: CoolFactor | last post by:
MY CODE IS NEAR THE BOTTOM I want to export this Access query into Excel using a command button on an Access form in the following way I describe below. Below you will find the simple query I am...
0
by: MeoLessi9 | last post by:
I have VirtualBox installed on Windows 11 and now I would like to install Kali on a virtual machine. However, on the official website, I see two options: "Installer images" and "Virtual machines"....
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: Aftab Ahmad | last post by:
So, I have written a code for a cmd called "Send WhatsApp Message" to open and send WhatsApp messaage. The code is given below. Dim IE As Object Set IE =...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.