11

I am working on a contract management system on c# form application, one of the main parts of the project is to create a letter.

In this part of the application a user can send a letter with in the shape he or she wants, so I need an editor like FCK in html, because my users should be able to insert table insert image and etc.

Any idea how to get this working? Any concerns?

Patrick Hofman
  • 153,850
  • 22
  • 249
  • 325
  • 2
    Well, you already nailed it, FCK is a pretty good Wysiwyg editor if that's what you want/need. Keep in mind that Wysiwyg is always tricky, so I personally always try do do without it. As you're talking about a letter, I even wonder if that's what you really need. Will the content edited by the user be displayed on the web, or be printed ? – Laurent S. Nov 20 '13 at 18:17
  • the main part that my users should be able to use that is table ,they should be able to change font and size of text .and user's size (font) should be printed –  Nov 20 '13 at 18:22
  • If the final destination is a print, I think you're going to have even more trouble using a wysiwig editor as input. Selecting fonts may also be tricky, especially if you wish them to use fonts from their computer (I don't want to say it's impossible cause I'm not sure, but almost). Would editing the document offline in an actual document format (.doc for example) and then upload it to your system be a possibility ? It would definitely be better for both the user (using Wysiwyg can be a total pain in the a**) and you (rendering HTML for print is not funnny neither) – Laurent S. Nov 20 '13 at 18:28
  • yes my final destination is print .i download a html editor in c# :http://code.msdn.microsoft.com/windowsdesktop/WinForms-HTML-Editor-01dbce1a,so do you have any idea ? –  Nov 20 '13 at 18:34
  • 1
    Idea of what ? I think I made it pretty clear already. Wysiwyg editors = pain in the a**. Making layout for print in html+css = pain in the a** too. Using the first one to perform the latter = a very bad idea if you ask me. Now you're free to go and try, but be prepared to spend a lot of time on SO, and maybe fail anyway eventually. You could probably manage to tap a nail with a screwdriver, but it will be very painfull, that's why hammers exist – Laurent S. Nov 20 '13 at 18:43
  • i want to use doc process,it means my application open ms word .and mu users be able to edit their letter in ms word and after that i save the word file in database ,so can i save word file it database ? –  Nov 20 '13 at 18:49
  • Yes you can. But users will need to save the file and then Upload it. Then you can save this into, for example, a BLOB object (although I would advice to save the file as such in the file syste outside the webroot). There's no way you're going to open word and use the "save" command from word to save it in a server database. – Laurent S. Nov 20 '13 at 18:56
  • yes i want to save my word file in database as an byte file,so opening the ms word my users can make their letter and after save i can send the file to database .i don't want to save my file in server –  Nov 20 '13 at 19:12
  • Suggest them to use that thing called email. – MatteoSp May 04 '15 at 08:18

2 Answers2

5

You could indeed use a HTML WYSIWYG editor, but depending on the quality of it, it might raise problems when converting the output of it to print. This may also depend on the framework used to generate the Word document.

In one of our environments, we use CKEditor and JasperReports. That combination is suitable to export to Word, since JasperReports supports reading HTML and convert that to Word.

However, the best solution may depend on your business requirements and personal preferences.


If the application is a business application, another option is to let them edit the document in Word. Our company (disclaimer: I am biased) has build a product that supports editing a Word document from a template loaded and filled from a database (or multiple databases). However, if it is useful to you depends on your business requirements.

Patrick Hofman
  • 153,850
  • 22
  • 249
  • 325
0

FCK is history now and as mentioned by others CKEditor is the successor. TinyMCE would be another alternative, or any other might be..

But what I want to mention is along with possible printing issues (that I have never dealt with) I want to underline another aspect:

my users should be able to insert table insert image and etc.

uploading and inserting images might be another issue...they don't come with a built in uploader, they sell it. you have the option to buy CKFinder along with CKEditor and Moxiemanager along with TinyMCE unless you choose to handle upload and insert into the editor process yourself.

wooer
  • 1,677
  • 2
  • 16
  • 27