Plugin Developer Discussion

Discussion for FogBugz Plugin developers

Is there a way to output directly into response stream?

I need to output pdf stream to a user from wihnin the plugin.
Is there a way to output directly into response stream from within a plugin? Some analog to the asp.net code:

Context.Response.ClearContent();
Context.Response.ContentType = "application/pdf";
Context.Response.BinaryWrite(GetPdfContent());
Context.Response.End();

If not, how I can do that?
Yuriy Baltovsky Send private email
Wednesday, July 22, 2009
 
 
You can do the equivalent of this using IPluginBinaryPageDisplay (see W14).  Your code would look something like this:

public byte[] BinaryPageDisplay()
{
    api.Response.ContentType = "application/pdf";
    return GetPdfContent();
}
David Fullerton Send private email
Wednesday, July 22, 2009
 
 

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics
 
Powered by FogBugz