473,511 Members | 14,933 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

DCOM errors while running as domain user - scheduled task

Hi guys,

I'm having a bit of a problem getting a VB .NET console app to run happily
as a scheduled task. The app itself generates a bunch of word documents on a
file share on another server by reading from a template file and inserting
text at bookmark locations (with details pulled from a table in the
database). I'm running the app under a regular domain account that isn't an
administrator on the server. The read/execute permissions are set on the
console app/directory just fine, and likewise for the export folder on the
file share on the other server.

Firstly, here's a bit of background on the problem and what I've tried so
far:

- Running the console app from a command prompt (logged in as the user with
a Start -> Run -> runas /user:DOMAIN\username cmd) results in the
application running just fine. It writes the files out to the share no
problems at all.
- Running the console app as a scheduled task (with the correct domain user
profile details) results in an "0xe0434f4d" error showing up in the task
scheduler, and the following error in the System event log (Event ID 10003):

Access denied attempting to launch a DCOM Server. The server is:
{000209FF-0000-0000-C000-000000000046}
The user is <username>/<domain>, SID=S-1-5-<etc...>

After this we edited the DCOM permissions by doing the following:

* Start -> Run -> dcomcnfg.exe
* Expand "Component Services"
* Expand "Computers"
* Right-click "My Computer" -> Properties
* Default COM security tab
* Edit both "Access Permissions" and "Launch Permissions", adding in the
user running the scheduled task in both sections.

This got rid of that DCOM error, and the scheduled task attempted to run.
Unfortunately now I faced a new error when the app tries to access the Word
object. The code in question is:

Dim objWord As New Microsoft.Office.Interop.Word.Application
objWord.DisplayAlerts = WdAlertLevel.wdAlertsNone
objWord.Documents.Add() <------ Exception thrown on this line

The exception message is:

There is insufficient memory. Save the document now.

at Microsoft.Office.Interop.Word.Documents.Add(Object & Template, Object&
NewTemplate, Object& DocumentType, Object& Visible)
at AutomatedRetryLetters.AutomatedRetryLetters.Main() in
AutomatedRetryLetters.vb:line 52

Needless to say, there's plenty of available memory. Also, if I add the
domain user as a local administrator on the machine it works without a
problem.

Does anyone have any suggestions as to what I could do next? I'm not keen on
leaving this account as an administrator on the box as it has no real need.
Jul 22 '05 #1
2 5830
did you ever figure this one out on your own? I am having a very similar
problem and cannot find any help on the issue anywhere. Thanks.
Aug 11 '05 #2
The original post was actually made on my behalf, and no...no solution thus
far I'm afraid. Still running under a local admin account to keep it working
unfortunately.

- James

"keith moran" wrote:
did you ever figure this one out on your own? I am having a very similar
problem and cannot find any help on the issue anywhere. Thanks.

Aug 12 '05 #3

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

Similar topics

0
1251
by: exchange | last post by:
I'm running a VB.net exe which reads a xml document via a URL using the XmlDocument Load method under framework 1.1. It runs correctly via a scheduled task running as user admin who is a member of...
0
4138
by: Erik Anderson | last post by:
There is a COM object (written in ATL) that I have been using for a little while (in scheduled events mostly) that I am very interested in getting to run inside of an ASP page. This site uses...
5
6360
by: Sergey V | last post by:
Having following problem 1. Client: ASP application with anonymous access to be running as DOMAIN\my_user on WinXP 2. Server: DCOM NT Service runs on remote host (W2K Server) under the same...
12
2482
by: Russ | last post by:
Hello. My new dev machine is running XP Pro. In the past all equipment has only used Windows 2000. I have had a lot of problems getting my projects up and running on the new machine. The current...
3
709
by: David Olive | last post by:
Hi guys, I'm having a bit of a problem getting a VB .NET console app to run happily as a scheduled task. The app itself generates a bunch of word documents on a file share on another server by...
4
3227
by: RSH | last post by:
I have an application that creates an Access version of a SQL Server database and then it moves the resulting database to an ftp server for the client to download and run reports against etc. The...
2
4724
by: mscurto | last post by:
Is there a way to set up access to open and run a query in a particular database at a particular time each day? This would be run from a Windows 2000 desktop.
6
2018
by: Mantorok | last post by:
Hi all I have a console application that runs every night via a scheduled task, there is a try-catch block in my Main class, whenever an error is caught it is written to a log file and then...
2
4168
by: kplkumar | last post by:
Hi all I am fairly new to windows scheduler. I have an .exe console application that needs to be run 1st of every month. I created a scheduled task in Windows Schduler and called the .exe. ...
0
7237
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7137
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7349
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7506
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5659
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
5063
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
4734
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3219
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
3210
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?

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.