Skip to content

Instantly share code, notes, and snippets.

@bjoerntx
Created September 28, 2016 14:50
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bjoerntx/9d7807b25f065dbd9aba65a513099e30 to your computer and use it in GitHub Desktop.
Save bjoerntx/9d7807b25f065dbd9aba65a513099e30 to your computer and use it in GitHub Desktop.
public ActionResult Index()
{
// create a new ReportingCloud object
ReportingCloud rc = new ReportingCloud("username", "password");
// read template into byte array and upload template to RC
byte[] bDocument =
System.IO.File.ReadAllBytes(Server.MapPath("/App_Data/letter.tx"));
rc.UploadTemplate("letter.tx", bDocument);
// retrieve template information
TXTextControl.ReportingCloud.TemplateInfo templateInfo =
rc.GetTemplateInfo("letter.tx");
// return template information to view
return View(templateInfo);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment