{"id":3156,"date":"2019-06-24T17:48:45","date_gmt":"2019-06-25T01:48:45","guid":{"rendered":"https:\/\/developer.microsoft.com\/en-us\/office\/blogs\/?p=3156"},"modified":"2019-06-24T17:48:45","modified_gmt":"2019-06-25T01:48:45","slug":"office-add-in-development-community-pnp-june-2019-update","status":"publish","type":"post","link":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/office-add-in-development-community-pnp-june-2019-update\/","title":{"rendered":"Office Add-in Development Community (PnP) &#8211; June 2019 update"},"content":{"rendered":"<p><span data-contrast=\"auto\">We&#8217;re excited to announce two new solutions for Office Add-ins Patterns and Practices. These were recently put together for the Excel custom functions feature that was released to general availability (GA) on May 6.\u00a0<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><\/p>\n<h2><span data-contrast=\"none\">Custom function batching pattern<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559738&quot;:240,&quot;335559739&quot;:0,&quot;335559740&quot;:259}\">\u00a0<\/span><\/h2>\n<p><span data-contrast=\"auto\">If your custom functions call a remote service<\/span><span data-contrast=\"auto\">,<\/span><span data-contrast=\"auto\">\u00a0you may want to use a batching pattern to reduce the number of network calls to the remote service. This is useful when a spreadsheet recalculates<\/span><span data-contrast=\"auto\">,<\/span><span data-contrast=\"auto\">\u00a0and it contains many of your custom functions. Recalculate will result in many calls to your custom functions, but you can batch them into one or a few calls to the remote service.\u00a0<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><\/p>\n<ul>\n<li data-leveltext=\"\uf0b7\" data-font=\"Symbol\" data-listid=\"2\" data-aria-posinset=\"1\" data-aria-level=\"1\"><span data-contrast=\"auto\">Try the code:<\/span><span data-contrast=\"none\">\u00a0<\/span><a href=\"https:\/\/github.com\/OfficeDev\/PnP-OfficeAddins\/tree\/master\/Excel-custom-functions\/Batching\"><span data-contrast=\"none\">Custom function batching pattern<\/span><\/a><span data-ccp-props=\"{&quot;134233279&quot;:true,&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><\/li>\n<li data-leveltext=\"\uf0b7\" data-font=\"Symbol\" data-listid=\"2\" data-aria-posinset=\"1\" data-aria-level=\"1\"><span data-contrast=\"auto\">Read the d<\/span><span data-contrast=\"auto\">ocs<\/span><span data-contrast=\"auto\">:<\/span><span data-contrast=\"auto\">\u00a0<\/span><a href=\"https:\/\/docs.microsoft.com\/office\/dev\/add-ins\/excel\/custom-functions-batching\"><span data-contrast=\"none\">Batching custom function calls for a remote service<\/span><\/a><span data-ccp-props=\"{&quot;134233279&quot;:true,&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><\/li>\n<\/ul>\n<h2><span data-contrast=\"none\">Use\u00a0<\/span><span data-contrast=\"none\">storage to share data between custom functions and the task pane<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559738&quot;:240,&quot;335559739&quot;:0,&quot;335559740&quot;:259}\">\u00a0<\/span><\/h2>\n<p><span data-contrast=\"auto\">If you need to share data values between your custom functions and the task pane, you can use the\u00a0<\/span><b><span data-contrast=\"auto\">OfficeRuntime.storage<\/span><\/b><span data-contrast=\"auto\">\u00a0object. Custom functions and\u00a0<\/span><span data-contrast=\"auto\">task\u00a0<\/span><span data-contrast=\"auto\">panes\u00a0<\/span><span data-contrast=\"auto\">do not share the same runtime and cannot access the same data.\u00a0<\/span><b><span data-contrast=\"auto\">OfficeRuntime.storage<\/span><\/b><span data-contrast=\"auto\">\u00a0saves simple key\/value pairs that you can access from both custom functions and the task pane.\u00a0<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><\/p>\n<ul>\n<li data-leveltext=\"\uf0b7\" data-font=\"Symbol\" data-listid=\"2\" data-aria-posinset=\"2\" data-aria-level=\"1\"><span data-contrast=\"auto\">Try the code:<\/span><span data-contrast=\"auto\">\u00a0<\/span><a href=\"https:\/\/github.com\/OfficeDev\/PnP-OfficeAddins\/tree\/master\/Excel-custom-functions\/Storage\"><span data-contrast=\"none\">Using storage to share data between custom functions and the task pane<\/span><\/a><span data-ccp-props=\"{&quot;134233279&quot;:true,&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><\/li>\n<li data-leveltext=\"\uf0b7\" data-font=\"Symbol\" data-listid=\"2\" data-aria-posinset=\"3\" data-aria-level=\"1\"><span data-contrast=\"auto\">Read the\u00a0<\/span><span data-contrast=\"auto\">docs<\/span><span data-contrast=\"auto\">:\u00a0<\/span><a href=\"https:\/\/docs.microsoft.com\/office\/dev\/add-ins\/excel\/custom-functions-save-state\"><span data-contrast=\"none\">Save and share state in custom functions<\/span><span data-contrast=\"none\">\u00a0<\/span><\/a><span data-ccp-props=\"{&quot;134233279&quot;:true,&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><\/li>\n<\/ul>\n<h2><span data-contrast=\"none\">C<\/span><span data-contrast=\"none\">ontributors from Microsoft<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559738&quot;:240,&quot;335559739&quot;:0,&quot;335559740&quot;:259}\">\u00a0<\/span><\/h2>\n<p><span data-contrast=\"none\">Here\u2019s the list of Microsoft people who have been closely involved with the PnP work during last month.<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><\/p>\n<ul>\n<li data-leveltext=\"\uf0b7\" data-font=\"Symbol\" data-listid=\"2\" data-aria-posinset=\"1\" data-aria-level=\"1\"><span data-contrast=\"none\">Michelle\u00a0<\/span><span data-contrast=\"none\">Scharlock<\/span><span data-contrast=\"none\">\u00a0<\/span><span data-contrast=\"none\">@<\/span><span data-contrast=\"none\">mscharlock<\/span><span data-ccp-props=\"{&quot;134233279&quot;:true,&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><\/li>\n<li data-leveltext=\"\uf0b7\" data-font=\"Symbol\" data-listid=\"2\" data-aria-posinset=\"2\" data-aria-level=\"1\"><span data-contrast=\"none\">Zlatko\u00a0<\/span><span data-contrast=\"none\">Michailov<\/span><span data-contrast=\"none\">\u00a0@<\/span><span data-contrast=\"none\">zlatok-michailov<\/span><span data-ccp-props=\"{&quot;134233279&quot;:true,&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><\/li>\n<li data-leveltext=\"\uf0b7\" data-font=\"Symbol\" data-listid=\"2\" data-aria-posinset=\"3\" data-aria-level=\"1\"><span data-contrast=\"none\">Michael Zlatkovsky<\/span><span data-contrast=\"none\">\u00a0<\/span><span data-contrast=\"none\">@<\/span><span data-contrast=\"none\">zlatkovsky<\/span><span data-ccp-props=\"{&quot;134233279&quot;:true,&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><\/li>\n<li data-leveltext=\"\uf0b7\" data-font=\"Symbol\" data-listid=\"2\" data-aria-posinset=\"3\" data-aria-level=\"1\"><span data-contrast=\"none\">David\u00a0<\/span><span data-contrast=\"none\">Chesnut<\/span><span data-contrast=\"none\">\u00a0<\/span><span data-contrast=\"none\">@<\/span><span data-contrast=\"none\">davidchesnut<\/span><span data-ccp-props=\"{&quot;134233279&quot;:true,&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><\/li>\n<li data-leveltext=\"\uf0b7\" data-font=\"Symbol\" data-listid=\"2\" data-aria-posinset=\"3\" data-aria-level=\"1\">Hidetake Jo<\/li>\n<\/ul>\n<h2><span data-contrast=\"none\">About\u00a0<\/span><span data-contrast=\"none\">Office Add-ins\u00a0<\/span><span data-contrast=\"none\">Patterns &amp; Practices (PnP)<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559738&quot;:240,&quot;335559739&quot;:0,&quot;335559740&quot;:259}\">\u00a0<\/span><\/h2>\n<p><span data-contrast=\"auto\">Office Add-ins<\/span><span data-contrast=\"auto\">\u00a0PnP\u00a0<\/span><span data-contrast=\"auto\">is a Microsoft led, community driven effort that helps developers extend, build, and provision customizations\u00a0<\/span><span data-contrast=\"auto\">on the Office platform\u00a0<\/span><span data-contrast=\"auto\">the right way by providing guidance and help through official documentation and open source initiatives<\/span><span data-contrast=\"auto\">.<\/span><span data-contrast=\"auto\">\u00a0The source is maintained\u00a0<\/span><span data-contrast=\"auto\">i<\/span><span data-contrast=\"auto\">n GitHub where anyone can participate. You can provide contributions to the samples, reusable components, and documentation.\u00a0<\/span><span data-contrast=\"auto\">Office<\/span><span data-contrast=\"auto\">\u00a0<\/span><span data-contrast=\"auto\">Add-ins\u00a0<\/span><span data-contrast=\"auto\">PnP is owned and coordinated by Office engineering teams, but the work is done by the community for the community.<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><\/p>\n<p><span data-contrast=\"auto\">You can find\u00a0<\/span><span data-contrast=\"auto\">code\u00a0<\/span><span data-contrast=\"auto\">samples for Office Add-in development\u00a0<\/span><span data-contrast=\"auto\">in<\/span><span data-contrast=\"auto\">\u00a0the\u00a0<\/span><a href=\"https:\/\/github.com\/OfficeDev\/PnP-OfficeAddins\"><span data-contrast=\"none\">Office Add-ins PnP repo<\/span><\/a><span data-contrast=\"auto\">.\u00a0<\/span><span data-contrast=\"auto\">Some samples are also documented in the\u00a0<\/span><a href=\"https:\/\/docs.microsoft.com\/office\/dev\/add-ins\/\"><span data-contrast=\"none\">Office Add-ins docs<\/span><\/a><span data-contrast=\"auto\">, such as\u00a0<\/span><a href=\"https:\/\/docs.microsoft.com\/office\/dev\/add-ins\/excel\/custom-functions-batching\"><span data-contrast=\"none\">Batching custom function calls for a remote service<\/span><\/a><span data-contrast=\"auto\">.<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><\/p>\n<h2><span data-contrast=\"none\">SharePoint PnP<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559738&quot;:40,&quot;335559739&quot;:0,&quot;335559740&quot;:259}\">\u00a0<\/span><\/h2>\n<p><span data-contrast=\"auto\">Office Add-ins PnP and\u00a0<\/span><span data-contrast=\"auto\">SharePoint PnP\u00a0<\/span><span data-contrast=\"auto\">are both related community driven efforts. SharePoint PnP\u00a0<\/span><span data-contrast=\"auto\">provides community solutions for developers building on SharePoint.\u00a0<\/span><span data-contrast=\"auto\">\u00a0For\u00a0<\/span><span data-contrast=\"auto\">more information about<\/span><span data-contrast=\"auto\">\u00a0<\/span><span data-contrast=\"auto\">SharePoint PnP, see\u00a0<\/span><a href=\"https:\/\/docs.microsoft.com\/en-us\/sharepoint\/dev\/community\/community\"><span data-contrast=\"none\">https:\/\/docs.microsoft.com\/en-us\/sharepoint\/dev\/community\/community<\/span><\/a><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><\/p>\n<h2><span data-contrast=\"none\">Additional resources<\/span><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><\/h2>\n<ul>\n<li data-leveltext=\"\uf0b7\" data-font=\"Symbol\" data-listid=\"2\" data-aria-posinset=\"1\" data-aria-level=\"1\"><span data-contrast=\"auto\">Get started with Office development by\u00a0<\/span><a href=\"https:\/\/developer.microsoft.com\/en-us\/office\/dev-program\"><span data-contrast=\"none\">joining the Office 365 developer program<\/span><\/a><span data-contrast=\"auto\">.<\/span><span data-ccp-props=\"{&quot;134233279&quot;:true,&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><\/li>\n<li data-leveltext=\"\uf0b7\" data-font=\"Symbol\" data-listid=\"2\" data-aria-posinset=\"2\" data-aria-level=\"1\"><span data-contrast=\"auto\">Try out some samples and get coding quickly with Office add-ins by\u00a0<\/span><a href=\"https:\/\/www.microsoft.com\/en-us\/garage\/profiles\/script-lab\/\"><span data-contrast=\"none\">downloading Script lab<\/span><\/a><span data-contrast=\"auto\">.<\/span><\/li>\n<li data-leveltext=\"\uf0b7\" data-font=\"Symbol\" data-listid=\"2\" data-aria-posinset=\"2\" data-aria-level=\"1\"><span data-contrast=\"auto\">Learn more by joining the monthly\u00a0<\/span><a href=\"https:\/\/aka.ms\/officeaddinscommunitycall\"><span data-contrast=\"none\">Office Add-ins community call<\/span><\/a><span data-contrast=\"auto\">.<\/span><span data-ccp-props=\"{&quot;134233279&quot;:true,&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><\/li>\n<\/ul>\n<p><span data-ccp-props=\"{&quot;201341983&quot;:0,&quot;335559739&quot;:160,&quot;335559740&quot;:259}\">\u00a0<\/span><\/p>\n","protected":false},"excerpt":{"rendered":"<p>We&#8217;re excited to announce two new solutions for Office Add-ins Patterns and Practices! Learn about batching custom function calls and how to save and share state in custom functions. This blog links to the complete code samples and docs for both solutions.<\/p>\n","protected":false},"author":69076,"featured_media":25159,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[11],"tags":[132,18,12,127],"class_list":["post-3156","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-office-add-ins","tag-add-ins","tag-excel","tag-outlook","tag-pnp"],"acf":[],"blog_post_summary":"<p>We&#8217;re excited to announce two new solutions for Office Add-ins Patterns and Practices! Learn about batching custom function calls and how to save and share state in custom functions. This blog links to the complete code samples and docs for both solutions.<\/p>\n","_links":{"self":[{"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/posts\/3156","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/users\/69076"}],"replies":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/comments?post=3156"}],"version-history":[{"count":0,"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/posts\/3156\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/media\/25159"}],"wp:attachment":[{"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/media?parent=3156"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/categories?post=3156"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/tags?post=3156"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}