scripting.filestream object. is there a .NET function that can be used instead?

  • i want to avoid using the old OLE objects as, well, they are old and i want to use somthing that will be around for a few years more. is there a way of doing this using .NET functions?

    instead of using

    sp_OACreate 'Scripting.FileSystemObject', @oFS OUTPUT

    is there a dot net function?

  • You could write a CLR stored procedure.

    If you do this, I think you may need to enable unsafe assemblies - I don't think the system IO namespace is allowed otherwise.

  • Michael Earl (6/17/2008)


    You could write a CLR stored procedure.

    If you do this, I think you may need to enable unsafe assemblies - I don't think the system IO namespace is allowed otherwise.

    I think you can also use EXTERNAL_ACCESS for that, as long as you're using .NET components.

    ----------------------------------------------------------------------------------
    Your lack of planning does not constitute an emergency on my part...unless you're my manager...or a director and above...or a really loud-spoken end-user..All right - what was my emergency again?

  • i was afraid of that. unsafe assemblies is disabled on my system for security reasons. thanks anyway

Viewing 4 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic. Login to reply