[RESOLVED] Need help with this assignment.
I'm doing a project where we are re-creating a very old system.
The client wants the same base functionality and some improvements.
One of the things I'm currently working on is the note-system. These are used as flags of some sort, but are also used as a comment field for some products or client profiles.
In the old system you could write the text and save it like you would get in a .txt file. They want the new one to be able to do word formatting such as:
Different font sizes (Only some parts of the text)
Different font colours (Only some parts of the text)
Underlining of words
Bolding
Italics
Tab-spaces
Those are the specs they want. What I need to know is the following:
1) How do I do that?
2) Currently they store all these files on the server as text files and the database have paths that refers to each file. I want to be able to save a text file with that formatting to the HDD of the server like in the old system.
3) If possible I would like to save that text to the database with the formatting.
Any help would be very much appreciated.
Re: Need help with this assignment.
Why don't you save the formatted file as Word Document ?
Re: Need help with this assignment.
Quote:
Originally Posted by
amrita
Why don't you save the formatted file as Word Document ?
And, taking this one step further, saving that Word document, as a BLOB, in a SQL Server database table.
Re: Need help with this assignment.
Ok, saving it as a BLOB in SQL. So what are my file-size limits here?
And how do I pass it with the formatting? Currently I read everything into a string and do a normal insert into...
Re: Need help with this assignment.
You can use the Rich Text Box control, you will easily be able to save the text with all formatting. An rtf document is supported by word.
You would need to create the buttons for formatting like bold etc with different code.
But then use
Code:
RichTextBox1.SaveFile("\\serverpath\textfilename.rtf")
function and load in the similar format.
-Dual
Re: Need help with this assignment.
Re: Need help with this assignment.
Quote:
Originally Posted by
tgf-47
Ok, saving it as a BLOB in SQL. So what are my file-size limits here?
And how do I pass it with the formatting? Currently I read everything into a string and do a normal insert into...
using a rtb, the rtb.rtf property contains the formatted text, so you could save that + reload it that way too
Re: Need help with this assignment.
+1 more for the RTB ... simplest way to go to get that function.
-tg