Created
July 22, 2019 14:20
-
-
Save bjoerntx/1f364c548b1ad1444c1ffbe4f7bd1f3e to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[System.Web.Http.HttpGet] | |
public HttpResponseMessage LoadDocument(string ConnectionID, string DocumentName) | |
{ | |
// connect the WebSocketHandler with the ConnectionID | |
WebSocketHandler wsHandler = WebSocketHandler.GetInstance(ConnectionID); | |
// the document directly server-side | |
wsHandler.LoadText(System.Web.Hosting.HostingEnvironment.MapPath("~/App_Data/" + DocumentName), | |
StreamType.WordprocessingML); | |
return new HttpResponseMessage() | |
{ | |
StatusCode = HttpStatusCode.OK | |
}; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment