0

I am using glimpse.mvc in an ASP.NET MVC 3 application. I have a ReportController with an action called Generate that returns a PDF. This action is called from a view with a form like this:

<form target="_blank" method="get" class="inline"
    action="/Report/Generate/154">
...

Inside "Generate" I put several traces like this:

Public Function Generate(
        id As Int64,
        conns As IList(Of Int64),
        parms As IDictionary(Of Int64, String),
        outputtype As String
) As ActionResult
    Try
        Trace.TraceInformation("Generating report...")
        ...
        Return File(output, mimetype, filename)

Since the output of the action is a file, there is no glimpse button to press after the action is done, so I tried opening the "remote" tab from the page that submits the form. But I can't find the call to "Generate" in the list.

How can I see the trace information that I wrote during "Generate"?

Endy Tjahjono
  • 24,120
  • 23
  • 83
  • 123

1 Answers1

0

Found the answer here:

I have to add some lines in the web.config because by default glimpse only tracks text/html outputs, so if I want it to also track PDF, I should add:

<glimpse enabled="true">
    <contentTypes>
        <add contentType="application/pdf" />
    </contentTypes>
</glimpse>
Community
  • 1
  • 1
Endy Tjahjono
  • 24,120
  • 23
  • 83
  • 123
  • Glad you where able to find the answer. Also there is more detail here - http://getglimpse.com/Help/Configuration – anthonyv Jul 12 '11 at 10:27