Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Infopath cannot connect to data source - Web Service

97 views
Skip to first unread message

Natalie Lewis

unread,
Jul 6, 2007, 4:50:01 PM7/6/07
to
We have a web service set up to generate an unique ID to be used in an
Infopath form. The web service is installed on our sharepoint server 2007
and it can be accessed from multiple computers. However, when we create a
new form from the InfoPath form library on Sharepoint we receive the
following error:

Form template:
http://mossdev.dci.com/ind/ddTestReq/Disk%20Drive%20Test%20Lab%20Request%20Form/Forms/template.xsn
The following DataObject either cannot be created or cannot be initialized:
NextDDSerialNumber
The query cannot be run for the following DataObject: NextDDSerialNumber
InfoPath cannot run the specified query.
InfoPath either cannot connect to the data source or the service has timed
out.

S.Y.M. Wong-A-Ton

unread,
Jul 8, 2007, 3:46:02 AM7/8/07
to
Is it a browser form making use of the web service? And how does the web
service generate the unique ID? Does it access a database? The error could
have many causes, so it's difficult to say what is going wrong, but one of
these causes can be denial of access to network resources.
---
S.Y.M. Wong-A-Ton

Natalie Lewis

unread,
Jul 9, 2007, 9:24:00 AM7/9/07
to
It is an Infopath form being opened in Infopath. The webservice increments
an ID in a text file on a network path. I think it's a security issue, but
I've tried several things and nothing seems to work.

S.Y.M. Wong-A-Ton

unread,
Jul 10, 2007, 3:30:00 AM7/10/07
to
I think so too! Did you test the web service independently of InfoPath? Does
it work? How are you calling the web service in InfoPath? Through code?

Natalie Lewis

unread,
Jul 10, 2007, 9:24:02 AM7/10/07
to
It works as a web service if I'm running it as me from my machine. If I try
to access it from another computer, I can navigate to the web service page,
but I can't run it. From everything I've read, its got to be related to the
text file that has to be written to be the webservice. I've tried giving the
application pool the web service runs under, aspnet, computername_User and
authenticated users access to the folder to write to it. I can get to the
point where it looks like it will work - but then it either gives me the
error above or an access is denied error. (I'm not a programmer by training,
so this is a bit of a hunt and peck expedition for me...) Thanks for your
help!

S.Y.M. Wong-A-Ton

unread,
Jul 10, 2007, 10:44:01 PM7/10/07
to
For a non-programmer you know quite a bit. :) You gave permissions on the
folder, but how about the file itself? And what OS is the web service running
on? If it is running on Win 2003 server, you may want to try giving write
permission to the Network Service account if your web service is not
impersonating any user account.

Natalie Lewis

unread,
Jul 11, 2007, 10:24:00 AM7/11/07
to
I gave permissions for aspnet and network service to the folder and the file.
The webservice is running on a Win 2003 server. I've read that you should
have the config file impersonate the network service, but I'm not sure how to
do that.

S.Y.M. Wong-A-Ton

unread,
Jul 11, 2007, 7:44:03 PM7/11/07
to
If you haven't changed the default user account on the application pool the
web service is using, Network Service should be the default account being
used on a Win 2K3 server box. So you need not impersonate the Network Service
account. However, if you want to let the web service run under a different
account than the Network Service account, you can set this on the application
pool or impersonate a user in the web.config of the web service using the
<identity> element (see http://support.microsoft.com/kb/315736).

Another question: Is anonymous access enabled on your web service? If it
isn't and you're calling the web service from code, you need to specify valid
credentials to access it.

0 new messages