Excel Adds Python Editor 27 Days After Python Debuts - Episode 2625

preview_player
Показать описание
Microsoft Excel Tutorial: Microsoft Labs in Cambridge releases a great Python editor for Excel.

Just 27 days after Python preview appears in Excel, Microsoft has added a dramatically better Python editor.

Welcome to episode 2625 of the MrExcel netcast, where we explore all things Excel. In today's episode, we're diving into the exciting news that Excel has added a Python editor just 27 days after Python's debut in the program. This is a game-changing addition for all Excel users, and we can't wait to show you all the amazing features it has to offer.

There are a few theories as to why the editor was added just 27 days after Python's debut. One possibility is that the editor simply took longer to develop. But another theory is that the team at Excel Labs in Cambridge saw the debut of Python and thought, "We can make this even better." If that's the case, then kudos to them for developing and testing the editor in just 27 days.

To access the Python editor, simply go to the Get Add-Ins option, which can be found on either the Insert or Home tab, depending on your version of Excel. From there, search for Excel Labs and click on the Advanced Formula Environment. If you already have this add-in, you may need to update it to access the Python editor.

Once you have the editor open, you'll notice that it has a similar layout to the formula bar, but with some major improvements. For starters, you can choose to work in either one specific cell or all Python cells in your workbook. The code is also color-coded, making it much easier to read and navigate. And perhaps the most exciting feature - auto-complete is now available when writing Python code in Excel.

But that's not all - the Python editor also has a scratch pad feature, allowing you to save your code in the task pane and come back to it later. You can even switch to manual calculation mode to only run specific Python cells, saving you time and effort. Overall, this is a huge improvement from the Excel Labs team and we can't believe we've been writing Python without it.

Thank you for tuning in to today's episode of the MrExcel netcast. If you enjoyed this video, please don't forget to like, subscribe, and ring the bell for notifications on future episodes. And as always, feel free to leave any questions or comments down below. See you next time!

This new editor in the task pane offers AutoComplete, Intellisense, and automatic code coloring. Take a walkthrough the editor in today's video.

#excel
#microsoft
#microsoftlabs
#microsoftexcel
#exceltricks
#excelpython
#microsoft365
#walkthrough

Table of Contents
(0:00) Python Editor Added to Excel
(0:10) Free Silo Photos
(0:20) Theories on backstory
(0:59) Get Add-Ins moving from Insert to Home tab
(1:22) Update Excel Labs add-in twice
(1:49) Open Excel Labs & Python Editor
(2:00) Contrast Formula Bar editor to Python Editor
(2:17) Expand Editor
(2:33) Pane shows preview of data frame
(2:45) Color coded
(3:00) Images won't render in editor
(3:10) Adding a new Python cell
(3:24) AutoComplete
(3:45) Choose Python object or Excel values
(3:56) Easier to use XL function in formula bar than python editor
(4:50) Sorting in Python
(5:40) Scratchpad without committing the code
(6:03) In Manual Calculation mode, only one cell calculates when committing code
(6:34) Wrap-up

Рекомендации по теме
Комментарии
Автор

If you press F4 inside AFE, you can click in the grid to insert a cell reference. This should work in Python mode, or plain-old AFE for formulas.
(Some of AFE's shortcuts are listed in its right-click context menu; all should be listed in the command palette, which is Ctrl-Shift-O followed by ">".)
In Python mode, you can also type "xl" and select "xl(...)" from the autocomplete menu to enter the same selection mode (where changing the grid selection inserts/edits the cell reference in AFE).

queutaih
Автор

Wow this is so cool, I never even thought to look in the AFE for a python IDE. The guys at Excel Labs have excelled themselves to get this out so quickly. What a treat to have your code highlighted and predictive text. The only other thing I would like to see, is the ability to connect a local Python Environment instead of sending everything to the cloud

roywilson
Автор

It is going to get only better. Great video!

Chillman
Автор

Very nice indeed. I was hoping that bringing up this advanced formula editor in the main formula bar is what they'd use the clicking on the function button for (when you choose either value or data frame). It seems, to me, that this would be the ideal place for it, and from that point your given a floating, dockable formula bar. The ability to switch between languages (python, dax, M, VBA, future stuff such as R could all have been incorporated in the bar too).
I'll have to play around with python now that I finally have it, but I'm thinking that it could be a replacement for VBA in many instances. Perhaps even PQ in others.

ricos
Автор

This is very cool. Feels like I blink and miss major Excel functionality nowadays.

Any ETA on similar integration of R like this Python mini-IDE and cell integration? I know there are some tools (BERT = Basic Excel R Toolkit), but don't seem as integrated. Tools like Tableau, SQL Server are integrating Python and R together... curious how Excel will handle that.

MikeDolanFliss
Автор

Yeah thought about the editor. The formula bar, and power query also need better editors.

defaultHandle
Автор

it possible to assing Python code to a button?
I mean I work with SAP and I would love to use python instead of VBA for SAP Scripting.

ExcelInstructor
Автор

Eventually microsoft will remove excel

mcafalchio