Equivalent of the Office.Application.CompareDocuments in Office.js - ms-word

I do not see any office.js api exposed to compare the documents. Similar api in native office add-in is https://msdn.microsoft.com/en-us/library/office/ff195665.aspx
Any way to achieve this?

It depends on what you mean by "compare". If you're trying to compare in the sense of "is the SHA1 of these documents identical", then you could use the getFileAsync API on both documents (assuming there's an add-in in both) and/or the Files REST API (if your file is stored in the cloud).
If by "compare" you mean a more fine-grained comparison, you could compare many of the properties by going sheet-by-sheet and comparing the values/formulas/numberFormat/etc. properties on the used range of each sheet.
If you need something in-between (and I'd be curious what it is), please suggest it on UserVoice and post a link here for reference. https://officespdev.uservoice.com/

Related

Validate if English word is valid as in found in dictionary Flutter Dart

Developing a Dart Flutter app. I need to validate if an English word that the user inputted is in the dictionary or not.
Is there a package or API interface to Wordnet or similar dictionary?
Is it possible to get from the dictionary of word is verb, adjective or noun?
First of all you will have to find an API, if you find one, then you will have to communicate with it by using the 'http' package of Flutter and by creating your implementation.
If no API is available and I think it is the case (I'm not 100% sure), then you have two options.
The first one is to create a scraper for the dictionaries or the website, you can use the WordNet web interface(http://wordnetweb.princeton.edu/perl/webwn) and use the web_scraper plugin to try to access and retrieve the data (make sure you have the rights to do so).
The second option (for me the best), is to create your own API knowing that WordNet offers to download their database file under license.(https://wordnet.princeton.edu/download)
You can use a web framework(Express.Js https://expressjs.com/fr/ is quite simple) depending on the language you use to create your api rest using the WordNet database file or by creating a database with this file.
Clearly, it's complicated but not impossible, the last option is the most complex and the first one is rather unstable...
I specify that this answer is only my opinion and maybe there is another solution, if yes I let then other person answer.

Koha RESTful api

I've been looking around the internet for information on Koha ILS restful api but I haven't found anything concrete. There is this link which talks about its HTTP API: http://wiki.koha-community.org/wiki/Koha_/svc/_HTTP_API but there are no examples and I'm quite confused with the MARCXML format required.
What I want to do is use this API to create biblio records into a remote Koha ILS system. If I understand correctly, using these services I can create records (probably using a JSON-to-MARC convert tool) but will I be able to also upload pdf files of each record in BASE64 format? It doesn't look like this is possible using this API although I'm not really sure.
The HTTP API available in Koha is a well-established protocol, called SRU, for searching library catalogs. This is protocol is meant only for searching, not for updating records.
Secondly, even though SRU 2.0 provides option for transmission of records in JSON format, most implementations do not support it yet.
Coming back to your use case, Koha cannot store PDF documents. It is a process automation tool in a library for physical collections, which deals only with metadata records. For storing digital documents you should look for document management solutions, such as DSpace, or smaller and easier Omeka. DSpace provides its own REST API for searching as well as supports SWORD protocol for uploading documents.

Document versioning with MarkLogic REST API

We're currently using MarkLogic's dls functions to handle document versioning, and are trying to switch over to use the REST API. The document endpoint doesn't use versioning by default, and I can't figure out a way to get it to. I'm referring to the dls functions for keeping multiple document versions, btw, not the new "content versioning" the REST API documentation mentions. In fact, the only reference to document versions in the REST API docs seems to be a line saying that content versioning isn't the same thing.
The only solution we've been able to come up with is to write a custom endpoint that duplicates everything the existing document endpoint's PUT does, plus document management. I'd rather avoid that if possible, especially when looking at MarkLogic 7's partial document updates. We're using MarkLogic 6 now, if it matters, but it doesn't look like 7 has any new features related to this.
Is there a way to do this using MarkLogic's existing endpoints?
You can write a REST API extension that automates the DLS operations. See http://docs.marklogic.com/guide/rest-dev/extensions. You will largely end up duplicating a lot of the same things, but this will plug into the existing endpoints.
Yes, MarkLogic 7 added content versioning to make refreshing of caches easier. And unfortunately, the DLS library hasn't been integrated into the REST api so far. You can file a feature request at support if you like.
In the mean time, the best suggestion I can give is use a separate route to do document updates using DLS (your current route or a limited custom endpoint that only supports the DLS functions you need for doc updates), and do anything else (as far as possible) using the existing REST api. You can look at this other stackoverflow question to see how to limit searches to the latest doc versions:
Marklogic REST API search for latest document version
HTH!
A member of MarkLogic has put together a REST extension to provide better DLS support in the REST-api. Hopefully that makes working with DLS over the MarkLogic REST-api a lot easier:
https://github.com/sanjuthomas/marklogic-dls-rest-extension
HTH!

Programmatic export/dump/mass data retrieval (BaaS)

Does anyone have experiences with programmatic exports of data in conjunction with BaaS providers like e.g. parse.com or StackMob?
I am aware that both providers (as far as I can tell from the marketing talk) offer a REST API which will allow for queries against the database, not only to be used by mobile clients but also by e.g. custom web apps.
I am also aware that both providers offer a manual export of data (parse.com via their web interface, StackMob via support).
But lets say I would like to dump all data nightly, so that I can import it into a reporting system for instance. Or maybe simply to have an up-to-date backup.
In this case, I would need a programmatic way to export/replicate the data stored in the backend. Manual exports are not an option for obvious reasons.
The REST APIs offered however seem to be designed for specific queries, not for mass reads (performance?). Let alone the pricing - I assume none of the providers would be happy about a nightly X Gigabyte data export via their REST API, so their probably will be a price tag.
I just couldn't find any specific information on this topic so far, so I was wondering if anyone else has already gone through this. Also, any suggestions on StackMob/parse alternatives are welcome, especially if related to the data export topic.
Cheers, Alex
Did you see the section of the Parse REST API on Batch operations? Batch operations reduce the number of API calls needed to grab data so that you are not using a call for every row you retrieve. Keep in mind that there is still a limit (the default is 100, but you can set it to a maximum of 1000). That means you are still limited to pulling down 1000 rows per API call.
I can't comment on StackMob because I haven't used it. At my present job, we are using Parse and we wrote a C# app which compares the data in a Parse class with a SQL table and pulls down any changes.

How to merge dynamic forms with Adobe Livecycle?

I have a number PDF documents which are dynamic forms. I want to make one document that contains all pages of the fist document, then all pages of the second, and so on. How can I do it programmatically with the Java API of Adobe Livecycle Enterprise Server?
I found documentation here, but it does not work for dynamic forms. Maybe I can convert the dynamic forms to static forms first? How can I do that?
http://livedocs.adobe.com/livecycle/8.2/programLC/programmer/help/wwhelp/wwhimpl/common/html/wwhelp.htm?context=sdkHelp&file=001473.html
Thanks in advance for your answers.
Cheers,
Arne
It depends on how many of these you need to create. I assume you are going to be making large numbers of these PDF's. The correct thing to use is Adobe LC Output ES2. The process is first to render your dynamic XFA based forms to static PDF using the Output service with whatever data you have and then to assemble them with the Assembler service (requires a DDX file with the rules for the assembly).
There are APIs (inc. Java) to call these services directly or you can write an orchestration(in Workbench) that does all the steps and you can call the orchestration from various API's including Java. The short lived orchestration capability is also licensed with Output.
This sample would be a good thing to review to see how to construct the orchestration (service) XDP and DDX.
http://help.adobe.com/en_US/livecycle/9.0/samples/ServiceUsageSampleOutputLetterWithAttachment.html
Places to review invoking orchestrations in Java are:
http://help.adobe.com/en_US/livecycle/9.0/programLC/help/000495.html
Best of luck C.
This is how I did it:
Add a numeric field to the master pages
Mark it as calculated - read only
Select current page number, in the menu below. you can also have another with total number of pages.