embedding office functionality into application
-
How might one go about embedding certain Office features into a C# application? More specifically, I would like to be able to visually paste, resize, and crop images into a control in my application. Are there components I can simply include into my application to accomplish this? If so, can I also put them into an .ASPX page? Thanks!
-
How might one go about embedding certain Office features into a C# application? More specifically, I would like to be able to visually paste, resize, and crop images into a control in my application. Are there components I can simply include into my application to accomplish this? If so, can I also put them into an .ASPX page? Thanks!
If you customize your toolbox to include the OCW (Office Components for the WEb) you can embed them as ActiveX controls as you would with other ActiveX controls, but you can't just take functionality like paste, resize, and cropping images. That type of implementation is not simply reusable components most often, at least not with Office (Office apps share functionality, but not always in a way you can reuse). Especially with copy/paste and drag/drop that functionality is very specific to an application, as far as what storage mediums and clipboard formats it supports (and .NET exposes only supports a few
STGMEDIUM
s, excludingTYMED_ISTREAM
andTYMED_ISTORAGE
). You can embed the OCWs into any web page. Remember that ASP.NET describes server-side functionality, hence being called Active Server Pages (.NET). Only minimal client-side script is used to support server-side state. You could embed OCWs even into pages generated from PHP running in Apache on a linux machine and it wouldn't make a bit of difference. Anything a client views in a browser is downloaded from the server to the client application. That's how HTTP along with most other protocols work. This posting is provided "AS IS" with no warranties, and confers no rights. Software Design Engineer Developer Division Sustained Engineering Microsoft [My Articles]