show diff on word documents - version-control

I'm designing a web application that will enable users to upload docx documents and will the show the diff between each revision.
I don't know how to approach the problem. Is it a bitmap, how do I decode the doc to show changes. Do Microsoft has an API I can use to simply send 2 word docs, and it will return the changes between the two?
I also have the same question on google docs. I think with google drive it's simpler. Saw this API
If anyone has done something similar or has an example to some similar app, I would be grateful.

Have you looked at Word's Compare tool? See under Review|Compare. Word's API also support the compare tool's automation (e.g. via VBA).
To use Word's API, you'll need to automate Word. For the details of the method, see: https://msdn.microsoft.com/en-us/library/office/hh128820(v=office.14).aspx
See also: https://code.msdn.microsoft.com/windowsdesktop/Compare-Two-Word-Documents-043b2e1d

Related

Is there official clipboard access from office-js for Word add-in?

I have reviewed the office-js docs and not found any formal way of working with the clipboard through a Word add-in.
I attempted to use the newer navigator.clipboard.writeText but it is automatically rejected by the internal Word browser (where the add-in is hosted) without prompting the user (like a browser does). I have not seen any associated support for permissions policy that can be used to communicate with Word that the add-in would like clipboard permissions.
So, I am resorting to the deprecated document.executeCommand('copy') for now, but am concerned that will get my add-in rejected by the MS App Store.
Is there an official/sanctioned way to use the clipboard from within a MS Word add-in?
OfficeJS doesn't provide anything for that. You may sill use the Document.execCommand() API which includes "copy", "cut" and "paste". But it was deprecated and may not work in the web browsers any longer.
Feature requests on Tech Community are considered, when the dev team go through the planning process. Use the github label: Type: product feature request at https://aka.ms/M365dev-suggestions .
It seems like there's one method Range.copyFrom of Excel rich client api. I can't find the alternatives either. Maybe you can ask to provide the new feature. Whether it could be in the future feature list or not may also take some time.

How to tag the code of a website for structured data recognition by Google SEO?

we're just completing a new site build. With the current theme, we have had issues with structured data (we've highlighted it on Webmasters tools, and weeks later had to re-highlight it, and even then the highlighting prediction is not where we would like it to be).
It seems like Google is not able to find our Title, author, categories, content, featured image, date very easily. I'd expect to be able to communicate this to Google with 100% accuracy, since its so simple and we use the same format for all our articles). So maybe our theme is missing something by way of tags or something in the code to point to and identify this data?
Is that the case? Could someone please tell me what this aspect is called (so I can research it by its term), explain what I need to do with the new build, point me in the direction of an authoritative explanation/tutorial?
The site in question is a WordPress site, but I also am working on some php sites and would like to use this information on all sites, if it can be applied this way.
Thanks
You can use micro-data to mark-up the structured data. Also Google will really like your site if you show him (with a code) everything about the site - navigation, sidebar (aside), content (article) and so on. I suggest you to read about schema.org and micro-formats.
Here is an usefull article about your problem and how to implement micro-formats to your site.

Google Docs API - Spreadsheets which are Form Responses

So, I'm using the Google Docs API to extract spreadsheets programmatically.
However, I'm only interested in spreadsheets which are live feeds from form responses (survey responses). Is there a way of detecting this? So far the only approach I have is that the spreadsheet has a 'Form Responses 1' tab, which is quite a long way into the process; ideally I'd like to know before I download the file.
I'd be overjoyed by solutions which start with the form and tell you the relevant spreadsheet; ones which verify if a spreadsheet is a form's output are okay; knowing it's impossible would be helpful.
It is possible to get a list of the worksheets by using the Spreadsheets API.
Here is a link to the relevant documentation.
https://developers.google.com/google-apps/spreadsheets/#retrieving_information_about_worksheets
The only way I know this is possible is by using Apps Script, which is Google Apps's scripting language based on Javascript.
You can use Form.getDestinationId() to find the target spreadsheet, like in this example :
function myFunction() {
var form = FormApp.openById('1af5Ur_7IPHOXxdyqVXFF4tFA4WHx6PLf9uL56iPLMgI');
Logger.log(form.getDestinationId())
}
More info about Apps Script's Form capabilities here.
Note that Apps Script has very limited integration capabilities, so if you're trying to build an integrated webapp it might get complicated (but not impossible).

Bing Image Search API autocorrect feature...?

I am trying to use BING's image search api, but the problem is when I miss-spell something it automatically corrects the and doesn't tell me that "Hey we have auto-corrected your query!" , I want to know if my query has been auto corrected and what's the replacement word they have used.. Has anyone done this before...?
This is the query I am using.. note "Aemrica" has been mis-spelled deliberately but it still it gives me results for "America"
https://api.datamarket.azure.com/Data.ashx/Bing/Search/v1/Image?Query=%27Aemrica%27&$top=50&$format=JSON
but does not tell anything that the word has been replaced. Is there any way around it..?
i am using the response for iPhone.
No there is no way around this. Even the SearchResponse.Query.SearchTerms response parameter appears to still be the incorrectly spelt version.
I would suggest contacting Microsoft if this is a big issue for you.
EDIT: If you upgrade to the new Bing Search API based on the Azure marketplace, you can now get this data by first making a call to the SpellingSuggestions endpoint.

How to search Feeds?

I want to create an iPhone project which search feeds, like in google reader if we search for some word in "Add a subsciption" tab it will display all feeds related to that so we can add feeds easily. Any Idea how it can be done.
Thanks in advance,
Google Reader, presumably, relies on Google's own vast collection of known feeds and its search engine to locate relevant ones. My guess is you'd probably need to do the same (maybe use their FeedBurner API) unless you plan to create and maintain a service to collect, categorize, and offer up feeds to searches.
I have used http://code.google.com/apis/ajaxfeeds/documentation/reference.html#findFeeds
And it worked for me.