none
The new type of Word-add ins - Very broad questions RRS feed

  • Question

  • Hello all,

    passing through WordBasic, VBA and VSTO, I now face the new Word add-in environment witch requires JavaScript. I see the obvious advantages with the multi platform capabilities. I also see possible concerns with different capabilities between the platforms - Word Online and desktop Word PC/Mac. I have a few general questions that maybe some of you have run into and at least briefly could respond to. Thanks in advance.

    1. Can you access the Active Directory from within JavaScript?
    2. Can you use ADODB or similar to access a SQL Server or an Access database?
    3. Can you read or write the registry?
    4. Can you access the local hard drive?
    5. Can you make use of building blocks?
    6. Does the new platform support document and application events?
    7. Does the new platform support both document and application level solutions?
    8. Word Online - how to deploy corporate templates?

    Peeter

    Tuesday, December 12, 2017 3:43 PM

Answers

  • Hello,

    With Office Add-ins, you can use familiar web technologies such as HTML, CSS, and JavaScript to extend and interact with Office. An Office Add-in includes two basic components: an XML manifest file, and your own web application. The manifest is an XML file that specifies settings and capabilities of the add-in. You could use any technologies, both client and server side, that your hosting provider supports (such as ASP.NET, PHP, or Node.js).

    So the answer to your Q1-Q4 is yes as we could access them in web applications.

    For your Q5-Q7, please check Word JavaScript API reference and Shared API.

    Word JS API does not support building blocks now. You may submit a feedback on https://officespdev.uservoice.com/

    Office JS API only provides few events for document and few object like bindings and custom setting. Please visit https://dev.office.com/reference/add-ins/shared/document

    We do not specify document level and application level in Office add-ins. I think we could say it supports both document and application level, we could also say it is application level. The add-in could be deployed to your application, we could load it for all documents. After loading, it interacts with content in active document.

    Sorry that I am not clear about your last question. I suggest you create a new thread and provide detail information about your expected result. It is not recommended to discuss serveal different issues in one thread.

    Regards,

    Celeste  


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    • Proposed as answer by Chenchen LiModerator Tuesday, December 19, 2017 2:59 AM
    • Marked as answer by pemok Tuesday, January 9, 2018 7:55 AM
    Wednesday, December 13, 2017 8:50 AM
    Moderator

All replies

  • Hello,

    With Office Add-ins, you can use familiar web technologies such as HTML, CSS, and JavaScript to extend and interact with Office. An Office Add-in includes two basic components: an XML manifest file, and your own web application. The manifest is an XML file that specifies settings and capabilities of the add-in. You could use any technologies, both client and server side, that your hosting provider supports (such as ASP.NET, PHP, or Node.js).

    So the answer to your Q1-Q4 is yes as we could access them in web applications.

    For your Q5-Q7, please check Word JavaScript API reference and Shared API.

    Word JS API does not support building blocks now. You may submit a feedback on https://officespdev.uservoice.com/

    Office JS API only provides few events for document and few object like bindings and custom setting. Please visit https://dev.office.com/reference/add-ins/shared/document

    We do not specify document level and application level in Office add-ins. I think we could say it supports both document and application level, we could also say it is application level. The add-in could be deployed to your application, we could load it for all documents. After loading, it interacts with content in active document.

    Sorry that I am not clear about your last question. I suggest you create a new thread and provide detail information about your expected result. It is not recommended to discuss serveal different issues in one thread.

    Regards,

    Celeste  


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    • Proposed as answer by Chenchen LiModerator Tuesday, December 19, 2017 2:59 AM
    • Marked as answer by pemok Tuesday, January 9, 2018 7:55 AM
    Wednesday, December 13, 2017 8:50 AM
    Moderator
  • Hi Peeter,

    Do you have any issue with this thread?
    If not, I would suggest you mark the helpful reply as answer to close this thread.

    Regards,

    Tony


    Help each other

    Tuesday, January 9, 2018 7:05 AM
  • Sorry for not responding, but thought there might be more answers coming in. Now marked.

    Peeter

    Tuesday, January 9, 2018 7:55 AM
  • Hi pemok

    You might try asking some of these questions in the forum on StackOverflow dedicated to the Office JS technology:

    https://stackoverflow.com/questions/tagged/office-js

    This is where the 'Softies hang out that develop/support it.

    FWIW I don't agree with the answer you got about 3 & 4 being supported. Last I checked, a JS Add-in has NO access to the user's machine, whether Registry or file system (without explicit user permission, anyway) - this for security reasons.

    As an alternative to the built-in building blocks you should be able to insert Word Open XML using JS to create content in the document.

    If the company has SharePoint I believe you can access "templates" that way. Otherwise, you can use the Word Open XML approach to insert content, as above.


    Cindy Meister, Office Developer/Word MVP, <a href="http://blogs.msmvps.com/wordmeister"> my blog</a>

    Thursday, January 11, 2018 4:15 PM
    Moderator
  • Thanks Cindy,

    for your input. And I will look in your suggested forum.

    Peeter

    Friday, January 12, 2018 8:47 AM