I have posted the same topic under ASP-NET-Developers but had no reply;
I then posted it under ASP.Net Community and had also no reply.
Hence, i'm posting it here to prevent the impression of spam post ...
I have created a SqlContextTrigger using ADO.NET 2.0 to create a
trigger on
SQL Server 2005.
In the class, I create a file and specify its path to be in the
Application
Domain base directory such as:
String Path = AppDomain.CurrentDomain.BaseDirectory.ToString()
However, the path is always the SQL Server Binn Directory. I'd like to
tell
the program that I want the path to be related not to SQL Server Binn
Directory but to Visual Studio Solution's Project Bin Directory.
How do I do that?
Best regards> However, the path is always the SQL Server Binn Directory. I'd like to
> tell
> the program that I want the path to be related not to SQL Server Binn
> Directory but to Visual Studio Solution's Project Bin Directory.
I doubt that you will find anything built-in that will do this. The trigger
thread is running in SQL Server and has no knowledge of your client folder
structure nor a means to access it.
One method to accomplish the desired result is to store the desired target
path in a table so that you can retrieve the value from within your trigger
code. If the path is remote, you'll need to use a UNC path and additional
security considerations apply.
I'm not sure what you are trying to do but you might take a look at Service
Broker.
--
Hope this helps.
Dan Guzman
SQL Server MVP
"coosa" <coosa76@.gmail.com> wrote in message
news:1136546993.487438.187050@.o13g2000cwo.googlegr oups.com...
> Hi all,
> I have posted the same topic under ASP-NET-Developers but had no reply;
> I then posted it under ASP.Net Community and had also no reply.
> Hence, i'm posting it here to prevent the impression of spam post ...
> I have created a SqlContextTrigger using ADO.NET 2.0 to create a
> trigger on
> SQL Server 2005.
> In the class, I create a file and specify its path to be in the
> Application
> Domain base directory such as:
> String Path = AppDomain.CurrentDomain.BaseDirectory.ToString()
> However, the path is always the SQL Server Binn Directory. I'd like to
> tell
> the program that I want the path to be related not to SQL Server Binn
> Directory but to Visual Studio Solution's Project Bin Directory.
> How do I do that?
> Best regardssql
No comments:
Post a Comment