• Try this:::

    declare @maxfilesize bigint

    exec @rc = sp_trace_create @TraceID output, 0, N'c:\InsertFileNameHere', @maxfilesize, NULL

    -- Please replace the text InsertFileNameHere, with an appropriate

    -- filename prefixed by a path, e.g., c:\MyFolder\MyTrace. The .trc extension

    -- will be appended to the filename automatically. If you are writing from

    -- remote server to local drive, please use UNC path and make sure server has

    -- write access to your network share

    --Ron