SQL XML Bulk Load 4.0 problem with asp.net 1.1

G

Guest

Hi i am trying to get working sqlxmlbulkload4.0 with asp.net 1.1
i am using that code with windows application and its working fine but when
i try with asp.net application it give me that error
it open debugger windows with that error An unhandled expection
("System.Runtime.InteropServices.COMException")
occurred in aspnet_wp.exe [2760

my code is below
using System;
using System.Data;
using System.Data.SqlClient;
using System.Configuration;
using System.Threading;
namespace SQLXMLBulkLoadWeb
{
/// <summary>
/// Summary description for XMLBulkLoad.
/// </summary>
public class XMLBulkLoad
{
public XMLBulkLoad()
{
//
// TODO: Add constructor logic here
//
}


public static void XMLBulkLoadStart()
{
SQLXMLBULKLOADLib.SQLXMLBulkLoad4Class objBL = new
SQLXMLBULKLOADLib.SQLXMLBulkLoad4Class();

objBL.ConnectionString
="Provider=sqloledb;Server=server1;uid=test;pwd=test;Database=TestBulkLoad;Trusted_Connection=False;";

objBL.KeepIdentity = false;
objBL.CheckConstraints=false;
objBL.IgnoreDuplicateKeys=false;
objBL.KeepNulls=true;


objBL.Execute
(@"http://Localhost/SQLXMLBulkLoadWeb/RawData_PCIP.XSD",@"http://Localhost/SQLXMLBulkLoadWeb/RawData_PCIP.XML");
}
}
public class XMLThread
{
public XMLThread()
{

}
[STAThread]
public static void StartXMLThread()
{


Thread t=new Thread(new ThreadStart(XMLBulkLoad.XMLBulkLoadStart));
t.ApartmentState=System.Threading.ApartmentState.STA;
t.Start();

}

}
}



any body has any idea .. i tried several methods of path like
Server.Map(FileName);
but no luck
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,743
Messages
2,569,478
Members
44,898
Latest member
BlairH7607

Latest Threads

Top