Hi,
This is how you can change the Web Service URL of a data connection.
IXMLDOMDocument webserviceOperation;
WebServiceAdapter2 webserviceAdapter = (WebServiceAdapter2) thisXDocument.DataAdapters[dataAdapterName];
webserviceOperation = thisXDocument.CreateDOM();
webserviceOperation.loadXML(webserviceAdapter.Operation);
SetNodeValue(webserviceOperation.documentElement, "@serviceUrl", url);
webserviceAdapter.Operation = webserviceOperation.xml;