Skip to main content
Filter by
Sorted by
Tagged with
0 votes
0 answers
53 views

I've used the below Office Script code successfully in the past to apply a manual filter against a filter hierarchy in a pivot table using office scripts. The below works in the app version, but it is ...
Deb's user avatar
  • 3
0 votes
1 answer
84 views

I'm wondering if this is possible, as with pivot tables in excel there is an option to expand or collapse all fields. If you try to record this in Automate, it says this action cannot be recorded. A ...
Deb's user avatar
  • 3
0 votes
1 answer
91 views

I need to build an Office Script (not VBA) to help a number of users hide / show columns on a Cloud-shared worksheet, in a controlled and structured way (so, not by manually using the Excel menu Sort ...
Zirynx's user avatar
  • 15
0 votes
1 answer
259 views

I am tyring a POC where my power bi gets refreshed via ADF and then i want to trigger a power automate flow which runs a script inside my analyze excel file. When i run the script manually in desktop ...
Milind Nair's user avatar
1 vote
0 answers
77 views

I'm using Office Scripts for Excel on the web and trying to insert a logo image into the footer and apply custom text formatting (font, size, and color). So far, I've successfully set the font and ...
Suzie's user avatar
  • 123
1 vote
1 answer
69 views

I'm trying to add a formula to a specific cell in my French Excel, but I get an error when I try to run it. Any ideas on what to change? Just to add, I got this English formula by using the "...
Jeanne Perreault's user avatar
0 votes
0 answers
230 views

I am trying to compare dates in a worksheet range and am struggling to convert Today's Date into the format DD-MMM-YY (i.e. "9-Jul-25"). Can anyone help with how I need to convert this? ...
Luke K's user avatar
  • 3
0 votes
0 answers
58 views

I have an array in below format (from column A to D) in Power Automate: Not all entities will be part of a group but each group will have a group representative. A group can have just one entity and ...
Koundinya Nellutla's user avatar
0 votes
0 answers
101 views

I need to the the minimum (or maximum, or some other values) of a range of data using Office Script in Excel. My data (a column of a table) contains only numeric values or empty cells. I can loop over ...
FunThomas's user avatar
  • 31.3k
0 votes
1 answer
82 views

I recorded the macro and then did some changes so they would show the right date format. The problem is that depending on the report the dates are located in different columns, I would like to create ...
Cheker's user avatar
  • 15
0 votes
1 answer
120 views

I'm stuck with the logic in Office Scripts. Following function is running on a worksheet in a dynamic range, currently "A2:BF21" that has the data is organized in columns, with different ...
tbalci's user avatar
  • 93
0 votes
2 answers
125 views

I'm working on an Office Script and got stuck where one function returns an array correctly, whereas the other function does not return the array. Below is my complete code. cleanSheet function ...
tbalci's user avatar
  • 93
0 votes
0 answers
66 views

I have an extremely simple ExcelScript that I use to copy cells from one sheet to another. It works with zero issues when called from within Excel itself - both from the desktop application and the ...
Robert Nowlen's user avatar
1 vote
1 answer
206 views

I're recorded an action in office script and this is one part that was recorded. selectedSheet.getRange("AN4:AN5").setFormulas([["=AN2-AM2"],["=AN3-AM3"]]); I wanted to ...
Rasec Malkic's user avatar
1 vote
2 answers
202 views

I have values in range A1:E10 and I'd like to get the next empty column in that range (excluding headers). In this case last column used is "C" and next empty column would be "D". ...
Rasec Malkic's user avatar
0 votes
0 answers
82 views

Per organization policies, I can't develop Excel add-ins. I can use Office Scripts, but there are no event handlers for Excel objects via this API. Is there any use and/or is it even possible to ...
namgaw's user avatar
  • 1
1 vote
1 answer
97 views

I am trying to insert a slicer to filter a pivot table using Office Scripts. However, I always receive a run time error when using the below code. The objects passed to the add method seem to exist, ...
Seldon's user avatar
  • 25
2 votes
1 answer
232 views

Last year I wrote a simple script to keep a locked sheet protected but allow users to insert new rows into a table when they press the designated button. It always succeeded with few errors, normally ...
Daniel Rodriguez's user avatar
0 votes
0 answers
86 views

Using this and it fails to fetch. Where am I missing it? async function main(workbook: ExcelScript.Workbook) { const response = await fetch('https://postman-echo.com/basic-auth', { method: 'GET', ...
Y Shah's user avatar
  • 1
1 vote
1 answer
72 views

I'm very new to office scripts. I have 1-Dimensional array that I want to paste in a range, but I'm getting the error Line 7: Range setValues: The argument is invalid or missing or has an incorrect ...
Rasec Malkic's user avatar
0 votes
2 answers
201 views

I'm trying to determine a Row inside of an If clause, i already know the column, it will always be E, but the row will change depending on what the active cell is, this is what i have: let ...
sandro pinheiro's user avatar
2 votes
2 answers
238 views

I need help creating an Excel office script that can automate some formatting within each sheet of the workbook. I need to place a blank column in all of the worksheets within the workbook. I am ...
user29303930's user avatar
0 votes
1 answer
128 views

I'm looking to loop through each row and based on a cell value I want to move another cell's value to new cell. Example: Loop through each row if column "Method" has a value "D" ...
Morgan.Batt's user avatar
0 votes
1 answer
168 views

I'm trying to color a specific column on a column chart in Excel for web using Office Scripts. I'm able to set the color of all columns using this code: function main(workbook: ExcelScript.Workbook) { ...
shrimp's user avatar
  • 1
0 votes
1 answer
75 views

I'm trying to rewrite some old VBA code to Office Script. One of the steps is to set data validation on several columns. With the script I am able to loop all columns of a named table. So my idea was ...
Pascal's user avatar
  • 3
0 votes
0 answers
59 views

How can I multiple the selected range in Excel using Office Script by 1? I'm trying to use the Excel trick of converting dates and numbers that aren't dates and numbers into being so by multiplying by ...
bozo88's user avatar
  • 11
0 votes
2 answers
242 views

I have created a transposed HTML table in power automate that looks like the following table: My problem is trying to create an excel table in power automate to populate the above data given that the ...
Ashraf's user avatar
  • 59
0 votes
0 answers
117 views

I have a VBA macro created for excel where formula have linkage to external links so I use Myworkbook.UpdateLink Name:=Myworkbook.LinkSources Now we are planning to move the macro to OfficeScript so ...
vtcs's user avatar
  • 43
1 vote
1 answer
66 views

I cannot get my office script to write any data in the "Data" sheet. I get no errors from running the script and it does say it writes the data but then nothing is there... I've tried ...
Craig Bennett's user avatar
0 votes
1 answer
229 views

I want to automize some format work in one of my excel files. Therefore I used macros for a long time - now it's time to move to scripts I thought. In the old world the cutsom style formating was done ...
Pascal's user avatar
  • 3
0 votes
0 answers
132 views

I wrote a script with conditionalformatting rules, everything works fine. But I have some lines that don't work when I run the script... unless I go to Conditional Formating ->manage rules, where I ...
Facundooz's user avatar
0 votes
2 answers
143 views

Goal is to find any rows in a table "PO" on sheet that's value is "Cancelled," "Ordered," or "Voided" in column A, copy the row, then paste it onto the end of ...
Kat Brown's user avatar
0 votes
1 answer
81 views

I’m trying to find the addresses of all the top-level rows in hierarchies to apply conditional formatting to the pivot table. It seems that using the method below, I can only extract the definitions ...
Waqar's user avatar
  • 636
0 votes
1 answer
1k views

I am writing a program that sorts my table then splits the strings in column E of the table, cutting the values in column E down to the first 10 chars and putting the remainder in column F. function ...
Kat Brown's user avatar
1 vote
1 answer
121 views

I have some coding experience but not much with this language. I am trying to create a script that will automatically copy a formula down column H, the only problem is that it is referencing that same ...
emma's user avatar
  • 11
0 votes
1 answer
382 views

Need a sub-range of the used range (sheet.getUsedRange()) starting from a specific address (ex. A10)?
Alex Kamburov's user avatar
0 votes
2 answers
105 views

I wrote this code to create sheets taking the name from a range, i need to also change a specific cell in the new sheet with the same name of the created sheet function main(wb: ExcelScript....
Shorter11's user avatar
0 votes
1 answer
143 views

I have an Excel file - with 2 sheets - on the first sheet - with many rows with loads of data - the final row will have a dropdown selection of "None" / "Active" / "Closed&...
Vijay Bhagattjee's user avatar
0 votes
0 answers
76 views

I have an Excel spreadsheet for which I have written an office 365 addin hosted in Microsoft Azure. The addin creates a Taskpane for the user which makes their interactions with the spreadsheet more ...
Daniel's user avatar
  • 11
0 votes
1 answer
867 views

Using the "online" version of Microsoft Excel and its automation tool "Code Editor" I want to create a script which automatically selects a range and copies the values to the ...
LongTimeReaderFirstTimePoster's user avatar
1 vote
1 answer
368 views

I am trying to set up a custom format using Office scripts, so that when the number 10 is entered in a cell, it displays the string ten instead. Of course, the method will work for any number/string ...
Seldon's user avatar
  • 25
0 votes
1 answer
106 views

I have a vehicle booking sheet in excel has column A as the date range. Currently I use macros to delete any rows that are older than Today() when the excel doc is opened to remove old data. We soon ...
Deon Utber's user avatar
0 votes
1 answer
122 views

I need help on an ExcelScript where I need the Column J filter then Delete the entire Row in column J with the value "Canceled" Renamed any value in column J with "In Progress" to &...
Salahdeen Nasiru's user avatar
1 vote
2 answers
99 views

Edit: Realized the "Exclude" column in my original question wasn't contributing to the issue at all. Simplified things even more and added full code that reproduces the error. In Excel I ...
Ajschuit's user avatar
  • 173
0 votes
0 answers
227 views

I have the following code below. const SHEET_NAMES = ["BaseGraficos"]; function main(wb: ExcelScript.Workbook): string { const sheets = SHEET_NAMES.map((name) => wb.getWorksheet(name))...
parizi10's user avatar
0 votes
1 answer
790 views

function main(workbook: ExcelScript.Workbook) { let sheet1 = workbook.getWorksheet("Sheet1"); let usedRange = sheet1.getUsedRange(); let rowCount: number = usedRange.getRowCount()...
Rutuja Lamkane's user avatar
0 votes
1 answer
252 views

im relativley new to Excel Scripts and i need your help. I have build an Excel Script which i want to add to my power automate flow, to generate graphs automatically with a predefined template. In ...
KPH's user avatar
  • 3
1 vote
3 answers
728 views

I work with excel 365 online. I am trying to duplicate a certain number of times a template sheet that I then have to rename by the value of a cell. I have tried and tested several codes but currently,...
Nicolas's user avatar
  • 145
0 votes
1 answer
135 views

I work at a company who sends out birthday cards to our clients on their birthdays. Every month we grab all of the birthdays which happen during the oncoming month and place them into different excel ...
0115cg's user avatar
  • 1
0 votes
1 answer
676 views

I am trying to do a simple delete of column A through column E but can't seem to get anything working. I tried the record feature to insert code but this comment is all that gets inserted. I have ...
BeeBuzzer1995's user avatar

1
2 3 4 5
10