Way to create file with the box api - box-api

I there a way to create a doc, like a .boxnote into a third app with the box api ? It seems that only edit, delete update functionalities are avaible.

I would say that it is not possible.
Box Notes are created using an specific web application from Box. But Box's API only have two modules :
Box Content: for managing the upload/download of data
Box View: for converting docs to HTML

Related

How to create and inject custom fields into Google Calendar UI for certain users?

I want to be able to edit the Google Calendar UI to have custom fields show up when a user is creating an event. I know it is possible to patch events and add custom fields to it after, but I want these custom fields to be defaulted on the user's calendar so anytime they create an event, the options show up. The pop-up I'm talking about is below.
I know that you can use AppScripts to create an add-on on the side of the screen, but I would prefer to have the change made right in the user's main UI. It seems like this is possible, as there is a Zoom add-on that allows you to "Make it a Zoom Meeting" as seen in the screenshot above in the bottom right hand corner.
If anyone could point me towards an example/documentation on how to do this, that would be greatly appreciated. Thanks in advance!
There is a similar question asked here
Where a community member shared a few options such as:
Using a browser extension to inject your custom fields + the Google Calendar API + the OAuth required.
Create your own UI using Google Apps Script CardService and its HTML service.

How to get image inside a form item in google apps scripts

I have multiple multiple choice questions and checkboxes with images inside them. I am trying to compile all the questions into a doc file. How do I get the images inside the questions? They are not in a separate Image Item.
https://docs.google.com/forms/d/1qdqNcaaiKxOoi4IiNc_3xcr1X3uw84qnV7mqMzcQA-0/edit?usp=sharing (This is a sample form containing an Image inside the question in case it isn't clear from the text)
Answer:
Unfortunately, at the moment there is no way to get/set images in multiple choice questions using Apps Script.
Feature Request:
There is already a feature request for setting images using FormApp, which can be found at the following link:
Add an image to a Google Form item (different from ImageItem)
You should star this issue to let Google know that this is a highly requested feature so that they can prioritise feature requests.
Alternatively, create a second Feature request specifically about getting the image and link to this one. The link to flie a feature request for Apps Script is here.
This feature has been assigned and is expected to come soon. https://issuetracker.google.com/u/1/issues/135828271 star this issue for progress updates

Create two textBoxes/Dropdowns side by side Google App Script [Gmail Add-on]

Can anyone please suggest how to add two Widgets/InputTextBoxes side by side in a Google Apps Script [Gmail Add-on] ?
Sample Code:
var section = CardService.newCardSection();
section.addWidget(
CardService.newTextInput()
.setTitle("Title1")
.setFieldName("field1")
);
section.addWidget(
CardService.newTextInput()
.setTitle("Title2")
.setFieldName("title2")
);
The above Google Apps script code creates two InputText fields one below the other in Gmail Add-on.
Is there any way to create two TextInputFields/Dropdowns/Widgets in a same row? [next to each other]
Something like these:
Thanks,
Side-by-side (a.k.a. "in-line fields" in other products) can't currently be done, and will likely remain this way solely because of the width of the add-on sidebar. Google's style guide already recommends that you use a multi-line text input box if you are anticipating "more than a few words." I consider it unlikely for Google to extend their CardService implementation to add an "in-line" flag given their recommendation.
The reason for this restriction no doubt lies in the purpose of CardService:
The UI structures you build with this service are automatically available in both desktop and mobile devices, so you don't need to develop separate UIs for both.
and also stems from one of their "best practices":
If a given card has too many widgets, it can fill too much of the screen and become less useful. While large card sections render as collapsable UI elements, this hides information from the user. Aim to streamline your add-on and provide exactly what the user needs and no more.
With multiple text inputs on a single line, the display could become extremely crowded when viewing the add-on from a mobile device, even if it is still comfortable when viewed via desktop browser. Limitations on side-by-side layout are not unique to TextInputs. Other "side-by-side" widgets such as a Key-Value will not allow setting both a Button and a Switch.
Consider reviewing the available widgets on the Widget overview - images on the page detail the appearance of a wide variety of widgets and you may find something more suitable.
Alternately, consider creating a Feature Request for this functionality, or reviewing the existing Feature Requests in Google's Issue Tracker
Semi-related existing questions:
Any way to show two widget side by side in gmail add on?
How to create this UI in Gmail Add-on using Google Apps Script

Create a new drawing and set the page size

I use Google Drawings to annotate screenshots. Currently, my workflow is to create a new Drawing, and then set the page size via File > Page Setup > Custom.
Using the Google Apps Script, is there a way to automate this workflow? For example, I could create a simple UI, with two text boxes and a button. I enter width and height in the text boxes and then click the button to create the new Drawing.
You can create Files in DriveApp from a blob source using the .createFile() method.
One parameter in the blob object is MIME type, and there is a drawings option you can use. It doesn't look like you can pass size data into the file, though.

Autocomplete text box in Google Script

I've am new to Google App Script. I have a spreadsheet that has various fields. I need to create a text box that displays the results from a particular field as I type the characters in the text box. I can do this like type the text and then hit a button and then display the results or the rowindex. But what I need is to an instant result showing up in a drop down box. Thanks. Any information would be helpful.
This is a good application to use HtmlService with jQuery-UI. Take a look at Populate jQuery autocomplete list using value array from Google Spreadsheet for an example that does just what you're describing.
See also this library that uses UiApp only
https://sites.google.com/site/scriptsexamples/learn-by-example/uiapp-examples-code-snippets/suggest-box