[SOLVED] WORDLIB

Got a LiveCode personal license? Are you a beginner, hobbyist or educator that's new to LiveCode? This forum is the place to go for help getting started. Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller

Post Reply
hoburne
Posts: 40
Joined: Tue Oct 04, 2011 11:13 am

[SOLVED] WORDLIB

Post by hoburne » Wed Oct 12, 2011 11:21 am

Hi,

I have a couple of questions regarding WORDLIB:-

1) I have purchased the plugin via the runrev store and got a license key, Where do I use this to register?

2) I am able to use the following to open a word document, however it doesnt keep any of the document formating - it seems like wordlib isnt being used to open the document?

Code: Select all

on mouseup
   global rootPath
  
   
   put label of me into theFile
   
   set the itemdelimiter to tab
   split theFile by tab
   put theFile[2] into theFile
   set the itemdelimiter to " "
   split theFile by " "
   put theFile[3] into theFile
   
   
   put rootPath & theFile into theFile
   
   put htmlTextOfDocument (theFile) into theImport
   
   if item 1 of theImport is "error" then
      -- display error message
      answer error item 3 to -1 of theImport
   else
      -- display document in field
      set htmlText of field "docField" to theImport
   end if
   

   
end mouseup
Basically - this card has an rTree which points to a specific folder, when clicking on a file it actions the code above. The result is the contents of the word file is displayed as a plain text list and no formatting.

Can anybody help?

Thanks.
Last edited by hoburne on Thu Jan 12, 2012 2:45 pm, edited 1 time in total.

hoburne
Posts: 40
Joined: Tue Oct 04, 2011 11:13 am

Re: WORDLIB - Doesnt seem to work?

Post by hoburne » Thu Oct 13, 2011 12:16 pm

Update:

Still not entirley working but im getting closer i think.

I have changed the code to:

Code: Select all

on nodeUp theButton theNodeID theTreeID
   
   
   get the sourcePath_of_node_ID_[theNodeID] of me
   put it into theFile
   
   #Load contents of file into variable
   put htmlTextOfDocument (theFile) into theImport
   
   if item 1 of theImport is "error" then
      -- display error message
      answer error item 3 to -1 of theImport
   else
      -- display document in field
      if wordLibSupports(theFile) then
         set htmlText of field "docField" to htmlTextOfDocument (theFile) 
      else 
         answer error "Not a valid file"
      end if
   end if
 
end nodeUp
This loads the content of the document into the field but as plain text, see image attached.

Also - I still have no idea how to register my purchased version?

Thanks.
Attachments
wordlib-issue.png

Klaus
Posts: 14177
Joined: Sat Apr 08, 2006 8:41 am
Contact:

Re: WORDLIB - Doesnt seem to work?

Post by Klaus » Thu Oct 13, 2011 4:40 pm

Hi,

I think you should contact RunRev support@runrev.com or the author himself:
http://curryk.com/


Best

Klaus

hoburne
Posts: 40
Joined: Tue Oct 04, 2011 11:13 am

Re: WORDLIB - Doesnt seem to work?

Post by hoburne » Fri Oct 14, 2011 8:24 am

Hi klaus,
Thanks for the advice. I have contacted both, no replies yet but will post any response I get.
Thank.

Curry
Posts: 111
Joined: Mon Oct 15, 2007 11:34 pm
Contact:

Re: WORDLIB - Doesnt seem to work?

Post by Curry » Sat Oct 15, 2011 12:07 am

(I became aware of this forum topic today due to your email! For support issues remember to contact me directly as per the User Guide.)

Full formatting is supported for Word 2007 up (DocX) and Open Office (ODT), while legacy .doc format has limited support currently, as listed in the web site and User Guide. The .doc import on Mac is better than on Windows, by the way. Hopefully full .doc support will be coming for a future update. The other two modern file formats are extensively supported with almost every feature possible to display natively in a LiveCode text field.

It's possible that you did not receive some of the registration materials, so I will be sending those and checking with RunRev to see that these are being distributed with purchases!

Best wishes,

Curry K.
Best wishes,

Curry Kenworthy

LiveCode Development, Training & Consulting
http://livecodeconsulting.com/

WordLib: Conquer MS Word & OpenOffice
SpreadLib: "Excel-lent" spreadsheet import/export
http://livecodeaddons.com/

hoburne
Posts: 40
Joined: Tue Oct 04, 2011 11:13 am

Re: WORDLIB - Doesnt seem to work?

Post by hoburne » Mon Oct 17, 2011 9:28 am

Hi Curry,

Thank-you for getting back to me - I have also received your email with the registered user guide.
I used the code included to register my copy of Wordlib - thanks.

i understand that formatting of the .doc is not 100% - no problem, I will convert the files to .docx. The .docx I tested wasnt 100% but i'm sure theres an explanation.

I have attached an image of the ODT file you included with wordlib - obviosuly this looks fine on your 'try wordlib' stack, but looks a mess in my stack. (I figure this would be a good test to compare your stack to mine.) Would there be any reason for this? I am using the following command:

Code: Select all

 set htmlText of fld "docField" to htmlTextOfDocument(theFile)
Note: 'theFile' is the path to the file.

Thanks.
Attachments
Capture3.PNG

Curry
Posts: 111
Joined: Mon Oct 15, 2007 11:34 pm
Contact:

Re: WORDLIB - Doesnt seem to work?

Post by Curry » Mon Oct 17, 2011 9:42 am

Howdy,

You might want to email me your stack or one with the relevant card containing your import field! I'll have a look tomorrow. (Bedtime!)

Best,

Curry K.
Best wishes,

Curry Kenworthy

LiveCode Development, Training & Consulting
http://livecodeconsulting.com/

WordLib: Conquer MS Word & OpenOffice
SpreadLib: "Excel-lent" spreadsheet import/export
http://livecodeaddons.com/

hoburne
Posts: 40
Joined: Tue Oct 04, 2011 11:13 am

Re: WORDLIB - Doesnt seem to work?

Post by hoburne » Mon Oct 17, 2011 9:43 am

Thanks Curry - Will do.

hoburne
Posts: 40
Joined: Tue Oct 04, 2011 11:13 am

Re: WORDLIB - Doesnt seem to work?

Post by hoburne » Tue Oct 18, 2011 8:42 pm

Hi Curry,
Did you get the stack ok?
Thanks.

hoburne
Posts: 40
Joined: Tue Oct 04, 2011 11:13 am

Re: [SOLVED] WORDLIB

Post by hoburne » Thu Jan 12, 2012 2:47 pm

Thanks to CurryK for great help and support - my original project now works great using Wordlib.

FourthWorld
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 10043
Joined: Sat Apr 08, 2006 7:05 am
Contact:

Re: [SOLVED] WORDLIB

Post by FourthWorld » Thu Jan 12, 2012 4:12 pm

hoburne wrote:Thanks to CurryK for great help and support - my original project now works great using Wordlib.
+100

One of the products I develop uses WordLib extensively, and I should note that with all the commercial products we make we're very finicky about the quality of the code, the quality of the support, and the availability of source just in case we ever need it.

On all three levels, Curry has exceeded expectations.

In fact, he's so impressed my client that we've contracted him for custom extensions as well, and his rates are as favorable as everything else he does.

IMNSHO, Mr. Kenworthy is one of the finest examples how deploying components should be. Easy-to-use APIs that are extensible, willingness to listen to suggestions for new features, diligence implementation, and friendly conversation throughout the process.

Curry rocks!
Richard Gaskin
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn

FourthWorld
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 10043
Joined: Sat Apr 08, 2006 7:05 am
Contact:

Re: [SOLVED] WORDLIB

Post by FourthWorld » Thu Jan 12, 2012 4:13 pm

FourthWorld wrote:
hoburne wrote:Thanks to CurryK for great help and support - my original project now works great using Wordlib.
+100

One of the products I develop uses WordLib extensively, and I should note that with all the commercial products we make we're very finicky about the quality of the code, the quality of the support, and the availability of source just in case we ever need it.

On all three levels, Curry has exceeded expectations.

In fact, he's so impressed my client that we've contracted him for custom extensions as well, and his rates are as favorable as everything else he does.

IMNSHO, Mr. Kenworthy is one of the finest examples how deploying components should be. Easy-to-use APIs that are extensible, willingness to listen to suggestions for new features, diligence in implementation, and friendly conversation throughout the process.

Curry rocks!
Richard Gaskin
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn

Post Reply