Hi Tony,

Regarding "The problem is the multi-line text cannot be copy-pasted
directly into the command line as the first newline will terminate the
command."

I don't know what operating system you're using.  If it's not a tiny
embedded OS, I wondered if you might want to use one of the many sqlite GUI
utilities available.

If that's not suitable, and you're on windows, there's a chance a small
batch file along the lines below would help.  It automatically pastes the
clipboard into a file.


First, make a general-purpose cmd file named "getClip.cmd" containing:
============================
@echo off
(
echo set objHTML = CreateObject("htmlfile"^)
echo ClipboardText = objHTML.ParentWindow.ClipboardData.GetData("text"^)
echo set objFSO = CreateObject("Scripting.FileSystemObject"^)
echo set objFile = objFSO.OpenTextFile("clip.txt", 2, true^)
echo objFile.WriteLine ClipboardText
echo objFile.Close
) > "%temp%\clip.vbs"
"%temp%\clip.vbs"
=================================
Now create a little batch file for your particular purpose along the lines
of:
=================================
rem Send clipboard contents to the file "clip.txt"
call getClip.cmd
IF ERRORLEVEL 1 GOTO :ClipEmpty

rem Now invoke sqlite3.exe to use readfile() to import clip.txt into a blob.
etc. etc.

=================================
(I used to use a nice free utility named "ClipOut.exe" instead of the
"getClip" above, but it worked only with older Windows versions.)

Just a guess,  Linux may have a more elegant solution.


Donald
_______________________________________________
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to