Skip to main content
April 22, 2008
Question

Retaining Ms Word formatting in text field capture

  • April 22, 2008
  • 2 replies
  • 322 views
I have several forms that capture an extensive amount of personnel data and one of the fields we capture is a text field that will hold interview questions and resume details, references etc. The usual process is that people will receive the information as a word document, formatted, and then have to put the information into the system for that field from a cut and paste key stroke. Now all the data is stored in SQL Server 2005 database and is being stored in a Text field type without a problem.

The problem arises when I try to display the content on that field on some display templates. The formatting is lost and there are several characters that get replaced by ~ as well as little square boxes that are a special character that I can't identify.

Is there anything anyone can suggest on how to approach this problem? is it a coldfusion administrator issue, a server setup issue, does word have to be installed on the server that the applications run? is it a setting in SQl server. I was hoping someone has had a similar problem and can point me in the right direction.

Timeyo: timeyo@gmail.com for immediate response.
This topic has been closed for replies.

2 replies

Inspiring
April 22, 2008
It sounds like the Word content includes characters like smart quotes which are not HTML friendly. You might try a UDF to replace these characters with an HTML substitute for display.

I have not used either of these samples but they may help you.
http://www.bennadel.com/index.cfm?dax=blog:1155.view
http://ipggi.wordpress.com/2008/03/11/remove-or-clean-high-extended-ascii-characters-in-coldfusion-for-xml-safeness/
Inspiring
April 22, 2008
BackInBlack wrote:
>
> The problem arises when I try to display the content on that field on some
> display templates. The formatting is lost and there are several characters that
> get replaced by ~ as well as little square boxes that are a special character
> that I can't identify.
>
> Is there anything anyone can suggest on how to approach this problem? is it a
> coldfusion administrator issue, a server setup issue, does word have to be
> installed on the server that the applications run? is it a setting in SQl
> server. I was hoping someone has had a similar problem and can point me in the
> right direction.


It is a character encoding issue. This is a big topic, but there is
plenty written up about it. You probably want to configure your
application use use window-1252 or unicode encoding format. You will
want to make sure the entire system running the application is talking
the same encoding, database web server and ColdFusion.