Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 Transact-SQL (2005)
 C# to SQL JOB

Author  Topic 

wtfn00b
Starting Member

6 Posts

Posted - 2008-11-20 : 07:03:27
Hellow, I have nasty code in C# and I want to run it from SQL JOB.
I don't know how to do that, can please someone help me ?

My code in C#:
string ExePath = @"C:\Program Files\CRESetup\CRE.exe";
string ExportPath = ConfigurationSettings.AppSettings["FileRoot"] + ConfigurationSettings.AppSettings["TempFilePath"];
string WebPath = "/" + ConfigurationSettings.AppSettings["TempFilePath"] + "/crexport/";
string RptPath = ConfigurationSettings.AppSettings["FileRoot"] + @"bin\crexport_export.rpt";

cognos79
Posting Yak Master

241 Posts

Posted - 2008-11-20 : 10:36:33
you cant just directly use c# code...the problem is your variables are using app variables info. sql server has no way of knowing it.
Go to Top of Page
   

- Advertisement -