Sqlite3 databases and the program to manipulate them with the possibility to export them with their content as RTF

General TRichView support forum. Please post your questions here
Post Reply
orion87
Posts: 4
Joined: Thu Aug 29, 2019 7:24 pm

Sqlite3 databases and the program to manipulate them with the possibility to export them with their content as RTF

Post by orion87 » Thu Aug 29, 2019 7:52 pm

Hi, I'll say I'm an amateur in programming. Reading the site and the forum I realized that there is the method "TDBRichViewEdit" to manipulate databases with RVF content. I have sqlite3 databases with RVF content as a BLOB format. Is there someone who can upload a demo of some sqlite3 database editor already compiled, so that it can modify the content and eventually export the database with RTF content? I also say that I tried to compile the database editor included in TRichView myself, but I didn't really understand something. I just found some small program which has inside its folder a database called "SampleTable.db", without even the possibility of export. I would like something more complex. Also, I tried to insert some sqlite3 database into the folder, named it in "SampleTable.db" and tried to start the database editor, but it gives an error that says "corrupted header file etc." or something like that.
I also wanted to know if the editor works with compressed databases, and I know that the compression format of some databases I have (not those I tried to open with your editor) is a simple Gzip. Thanks in advance.
Last edited by orion87 on Sat Aug 31, 2019 9:15 am, edited 2 times in total.

Sergey Tkachenko
Site Admin
Posts: 14552
Joined: Sat Aug 27, 2005 10:28 am
Contact:

Re: Sqlite3 databases and the program to manipulate them with the possibility to export them as RTF

Post by Sergey Tkachenko » Fri Aug 30, 2019 7:00 am

Sorry, I do not understand. If you have a database with RVF documents, but without an editor for this database, how could you create this database?

orion87
Posts: 4
Joined: Thu Aug 29, 2019 7:24 pm

Re: Sqlite3 databases and the program to manipulate them with the possibility to export them as RTF

Post by orion87 » Fri Aug 30, 2019 9:29 am

Sergey Tkachenko wrote:
Fri Aug 30, 2019 7:00 am
Sorry, I do not understand. If you have a database with RVF documents, but without an editor for this database, how could you create this database?
These databases are created with the Bible software named theWord: https://www.theword.net/
This software uses the source code of TRichView and is able to create modules (sqlite3) with the content in RVF and RTF format, saved as BLOB format. The problem is that I need to convert RVF into RTF, and this program (theWord) doesn't allow me to do that.

Sergey Tkachenko
Site Admin
Posts: 14552
Joined: Sat Aug 27, 2005 10:28 am
Contact:

Re: Sqlite3 databases and the program to manipulate them with the possibility to export them as with their content as RT

Post by Sergey Tkachenko » Sat Aug 31, 2019 7:52 am

The program that converts fields to RTF is very simple.

Let Table is a dataset that opens a table containing this field.
Let DBRVE: TDBRichViewEdit is linked to the field.

This code converts this field to RTF:

Code: Select all

DBRVE.AutoDeleteUnusedStyles := True;
DBRVE.FieldFormat := rvdbRTF;
Table.First;
while not Table.EOF do
begin
  Table.Edit;
  DBRVE.Change;
  Table.Post;
  Table.Next;
end;

orion87
Posts: 4
Joined: Thu Aug 29, 2019 7:24 pm

Re: Sqlite3 databases and the program to manipulate them with the possibility to export them as with their content as RT

Post by orion87 » Sat Aug 31, 2019 9:05 am

Ok, but since I am a beginner in programming, I wanted a compiled DEMO which does this without inserting codes. I wanted a program with a GUI which opens sqlite3 databases and with one click converts them into RTF. More or less like database manager such as DB Browser: https://sqlitebrowser.org/. This because I do not even know where to put the code you have inserted.

orion87
Posts: 4
Joined: Thu Aug 29, 2019 7:24 pm

Re: Sqlite3 databases and the program to manipulate them with the possibility to export them with their content as RTF

Post by orion87 » Sat Aug 31, 2019 10:14 am

I discovered another problem: the text is encrypted. So there is nothing to do without decrypting it. Thanks anyway for your information.

Post Reply