{"id":20031252,"url":"https://github.com/heracliteanflux/exercises-vba","last_synced_at":"2026-06-02T21:31:36.569Z","repository":{"id":191901676,"uuid":"685702630","full_name":"heracliteanflux/exercises-vba","owner":"heracliteanflux","description":"Exercises in Visual Basic for Microsoft Excel.","archived":false,"fork":false,"pushed_at":"2023-09-04T00:30:52.000Z","size":4726,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-02T05:25:16.196Z","etag":null,"topics":["excel","git-lfs","vba","vba-excel"],"latest_commit_sha":null,"homepage":"","language":"Jupyter Notebook","has_issues":false,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/heracliteanflux.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-08-31T20:16:41.000Z","updated_at":"2023-09-04T00:30:56.000Z","dependencies_parsed_at":"2024-11-13T09:42:22.704Z","dependency_job_id":null,"html_url":"https://github.com/heracliteanflux/exercises-vba","commit_stats":null,"previous_names":["heracliteanflux/exercises-vba"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/heracliteanflux/exercises-vba","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heracliteanflux%2Fexercises-vba","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heracliteanflux%2Fexercises-vba/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heracliteanflux%2Fexercises-vba/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heracliteanflux%2Fexercises-vba/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/heracliteanflux","download_url":"https://codeload.github.com/heracliteanflux/exercises-vba/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heracliteanflux%2Fexercises-vba/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33838215,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-02T02:00:07.132Z","response_time":109,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["excel","git-lfs","vba","vba-excel"],"created_at":"2024-11-13T09:31:48.714Z","updated_at":"2026-06-02T21:31:36.543Z","avatar_url":"https://github.com/heracliteanflux.png","language":"Jupyter Notebook","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Excel \u0026 VBA\n\nExercises in VBA for Microsoft Excel.\n\n## Excel\n\n### Documentation\n\nInstallation\n* [Try Microsoft 365 for free](https://www.microsoft.com/en-us/microsoft-365/try)\n* [Download and install or reinstall Microsoft 365 or Office 2021 on a PC of Mac](https://support.microsoft.com/en-us/office/download-and-install-or-reinstall-microsoft-365-or-office-2021-on-a-pc-or-mac-4414eaaf-0478-48be-9c42-23adc4716658)\n* [Update Office with Microsoft Update](https://support.microsoft.com/en-us/office/update-office-with-microsoft-update-f59d3f9d-bd5d-4d3b-a08e-1dd659cf5282)\n\n[Excel help \u0026 learning](https://support.microsoft.com/en-us/excel)\n* [Get started with Excel](https://support.microsoft.com/en-us/office/Get-started-with-Excel-f3937fb3-0a80-4b75-b45b-cffff35c19fa)\n  * [Save a workbook in another file format](https://support.microsoft.com/en-us/office/save-a-workbook-in-another-file-format-6a16c862-4a36-48f9-a300-c2ca0065286e)\n  * [File formats that are supported in Excel](https://support.microsoft.com/en-us/office/file-formats-that-are-supported-in-excel-0943ff2c-6014-4e8d-aaea-b83d51d46247)\n* [Formulas and functions](https://support.microsoft.com/en-us/office/formulas-and-functions-294d9486-b332-48ed-b489-abe7d0f9eda9)\n  * Functions\n    * [AVERAGE](https://support.microsoft.com/en-us/office/average-function-047bac88-d466-426c-a32b-8f33eb960cf6)\n    * [COUNTIFS](https://support.microsoft.com/en-us/office/countifs-function-dda3dc6e-f74e-4aee-88bc-aa8c2a866842)\n    * [DATE](https://support.microsoft.com/en-us/office/date-function-e36c0c8c-4104-49da-ab83-82328b832349)\n    * [FILTER](https://support.microsoft.com/en-us/office/filter-function-f4f7cb66-82eb-4767-8f7c-4877ad80c759)\n    * [IFERROR](https://support.microsoft.com/en-us/office/iferror-function-c526fd07-caeb-47b8-8bb6-63f3e417f611)\n    * [MEDIAN](https://support.microsoft.com/en-us/office/median-function-d0916313-4753-414c-8537-ce85bdd967d2)\n    * [QUARTILE.EXC](https://support.microsoft.com/en-us/office/quartile-exc-function-5a355b7a-840b-4a01-b0f1-f538c2864cad)\n    * [ROUND](https://support.microsoft.com/en-us/office/round-function-c018c5d8-40fb-4053-90b1-b3e7f61a213c)\n    * [STDEV](https://support.microsoft.com/en-us/office/stdev-function-51fecaaa-231e-4bbb-9230-33650a72c9b0)\n    * [STDEV.P](https://support.microsoft.com/en-us/office/stdev-p-function-6e917c05-31a0-496f-ade7-4f4e7462f285)\n    * [STDEV.S](https://support.microsoft.com/en-us/office/stdev-s-function-7d69cf97-0c1f-4acf-be27-f3e83904cc23)\n    * [SUM](https://support.microsoft.com/en-us/office/sum-function-043e1c7d-7726-4e80-8f32-07b23e057f89)\n    * [VLOOKUP](https://support.microsoft.com/en-us/office/vlookup-function-0bbc8083-26fe-4963-8ab8-93a18ad188a1)\n    * [YEAR](https://support.microsoft.com/en-us/office/year-function-c64f017a-1354-490d-981f-578e8ec8d3b9)\n  * More functions\n    * [Round a number](https://support.microsoft.com/en-us/office/round-a-number-f82b440b-689d-4221-b21e-38da99d33435)\n* [Import and analyze data](https://support.microsoft.com/en-us/office/import-and-analyze-data-ccd3c4a6-272f-4c97-afbb-d3f27407fcde)\n  * [Import data](https://support.microsoft.com/en-us/office/import-and-analyze-data-ccd3c4a6-272f-4c97-afbb-d3f27407fcde#ID0EBBD=Import_data)\n  * [Tables](https://support.microsoft.com/en-us/office/import-and-analyze-data-ccd3c4a6-272f-4c97-afbb-d3f27407fcde#ID0EBBD=Tables)\n    * [Sort data in a table](https://support.microsoft.com/en-us/office/sort-data-in-a-table-77b781bf-5074-41b0-897a-dc37d4515f27)\n  * [Sort and filter](https://support.microsoft.com/en-us/office/import-and-analyze-data-ccd3c4a6-272f-4c97-afbb-d3f27407fcde#ID0EBBD=Sort_and_filter)\n    * [Filter data in a range or table](https://support.microsoft.com/en-us/office/filter-data-in-a-range-or-table-01832226-31b5-4568-8806-38c37dcc180e)\n  * [Charts](https://support.microsoft.com/en-us/office/import-and-analyze-data-ccd3c4a6-272f-4c97-afbb-d3f27407fcde#ID0EBBD=Charts)\n  * [PivotTables](https://support.microsoft.com/en-us/office/import-and-analyze-data-ccd3c4a6-272f-4c97-afbb-d3f27407fcde#ID0EBBD=PivotTables)\n    * [Create a PivotTable to analyze worksheet data](https://support.microsoft.com/en-us/office/create-a-pivottable-to-analyze-worksheet-data-a9a84538-bfe9-40a9-a8e9-f99134456576)\n    * [Calculate values in a PivotTable](https://support.microsoft.com/en-us/office/calculate-values-in-a-pivottable-11f41417-da80-435c-a5c6-b0185e59da77)\n    * [Change the source data for a PivotTable](https://support.microsoft.com/en-us/office/change-the-source-data-for-a-pivottable-afd93524-f7de-432c-84d0-3896fbbc2577)\n    * [Create dynamic charts by using PivotCharts](https://support.microsoft.com/en-us/office/create-a-pivotchart-c1b1e057-6990-4c38-b52b-8255538e7b1c)\n    * [Filter data in a PivotTable](https://support.microsoft.com/en-us/office/filter-data-in-a-pivottable-cc1ed287-3a97-4e95-b377-ddfafe79fa8f)\n    * [Group or ungroup data in a PivotTable](https://support.microsoft.com/en-us/office/group-or-ungroup-data-in-a-pivottable-c9d1ddd0-6580-47d1-82bc-c84a5a340725)\n  * [Data models](https://support.microsoft.com/en-us/office/import-and-analyze-data-ccd3c4a6-272f-4c97-afbb-d3f27407fcde#ID0EBBD=Data_models)\n* [Enter and format data](https://support.microsoft.com/en-us/office/enter-and-format-data-fef13169-0a84-4b92-a5ab-d856b0d7c1f7)\n  * Format\n    * [Use conditional formatting to highlight information](https://support.microsoft.com/en-us/office/use-conditional-formatting-to-highlight-information-fed60dfa-1d3f-4e13-9ecb-f1951ff89d7f)\n      * [Highlight patterns and trends with conditional formatting](https://support.microsoft.com/en-us/office/highlight-patterns-and-trends-with-conditional-formatting-eea152f5-2a7d-4c1a-a2da-c5f893adb621)\n  * Layout\n    * [Freeze panes to lock rows and columns](https://support.microsoft.com/en-us/office/freeze-panes-to-lock-rows-and-columns-dab2ffc9-020d-4026-8121-67dd25f2508f)\n      * [Freeze columns and rows in Excel](https://support.microsoft.com/en-us/topic/freeze-columns-and-rows-in-excel-e7d1fcd9-7a67-94c2-e75b-cf54cc34bb1a)\n* [Troubleshoot](https://support.microsoft.com/en-us/office/troubleshooting-and-support-278f4691-6e1d-445a-a048-a7968a047e55)\n  * [Repairing a corrupted workbook](https://support.microsoft.com/en-us/office/repairing-a-corrupted-workbook-7abfc44d-e9bf-4896-8899-bd10ef4d61ab)\n  * [Fixes or workarounds for recent issues in Excel for Windows](https://support.microsoft.com/en-us/office/fixes-or-workarounds-for-recent-issues-in-excel-for-windows-49d932ce-0240-49cf-94df-1587d9d97093)\n\n[colors](http://dmcritchie.mvps.org/excel/colors.htm)\n\n## Excel \u0026 Python\n\n[ [d](https://support.microsoft.com/en-us/office/getting-started-with-python-in-excel-a33fbcbe-065b-41d3-82cf-23d05397f53d) ][ [g](https://github.com/microsoft/python-in-excel) ] Python in Excel\n* [ [b](https://techcommunity.microsoft.com/t5/excel-blog/announcing-python-in-excel-combining-the-power-of-python-and-the/ba-p/3893439) ] Microsoft Excel. (22 Aug 2023). \"Announcing Python in Excel: Combining the power of Python and the flexibility of Excel\".\n* [ [b](https://www.anaconda.com/excel) ] Anaconda. \"The Versatility of Excel + The Power of Anaconda\".\n\n[ [h](https://www.xlwings.org/book) ] Zurnstein, Felix. (2021). _Python for Excel: A Modern Environment for Automation and Data Analysis_. O'Reilly.\n\n## VBA\n\n### Documentation\n\n[Language reference for Visual Basic for Applications (VBA)](https://learn.microsoft.com/en-us/office/vba/api/overview/language-reference)\n* [Visual Basic conceptual topics](https://learn.microsoft.com/en-us/office/vba/language/reference/user-interface-help/visual-basic-conceptual-topics)\n  * [Declaring arrays](https://learn.microsoft.com/en-us/office/vba/language/concepts/getting-started/declaring-arrays)\n  * [Declaring constants](https://learn.microsoft.com/en-us/office/vba/language/concepts/getting-started/declaring-constants)\n  * [Declaring variables](https://learn.microsoft.com/en-us/office/vba/language/concepts/getting-started/declaring-variables)\n  * [Looping through code](https://learn.microsoft.com/en-us/office/vba/language/concepts/getting-started/looping-through-code)\n  * [Using For...Next statements](https://learn.microsoft.com/en-us/office/vba/language/concepts/getting-started/using-fornext-statements)\n\n[Getting started with VBA in Office](https://learn.microsoft.com/en-us/office/vba/library-reference/concepts/getting-started-with-vba-in-office)\n\n[Concepts (Excel VBA reference)](https://learn.microsoft.com/en-us/office/vba/excel/concepts/miscellaneous/concepts-excel-vba-reference)\n* [Programming for the Single Document Interface in Excel](https://learn.microsoft.com/en-us/office/vba/excel/concepts/programming-for-the-single-document-interface-in-excel)\n\n[ [d](https://learn.microsoft.com/en-us/office/vba/api/overview/excel) ] VBA for Excel\n* [ [d](https://learn.microsoft.com/en-us/office/vba/api/excel.range(object)) ] `Range` object\n  * [ [d](https://learn.microsoft.com/en-us/office/vba/api/excel.range.autofit) ] `Range.AutoFit` method\n  * [ [d](https://learn.microsoft.com/en-us/office/vba/api/excel.range.count) ] `Range.Count` property\n  * [ [d](https://learn.microsoft.com/en-us/office/vba/api/excel.range.end) ] `Range.End` property\n  * [ [d](https://learn.microsoft.com/en-us/office/vba/api/excel.range.numberformat) ] `Range.NumberFormat` property\n    * [ [d](https://support.microsoft.com/en-us/office/number-format-codes-5026bbd6-04bc-48cd-bf33-80f18b4eae68?ui=en-us\u0026rs=en-us\u0026ad=us) ] Number format codes\n  * [ [d](https://learn.microsoft.com/en-us/office/vba/api/excel.range.numberformatlocal) ] `Range.NumberFormatLocal` property\n  * [ [d](https://learn.microsoft.com/en-us/office/vba/api/excel.range.row) ] `Range.Row` property\n  * [ [d](https://learn.microsoft.com/en-us/office/vba/api/excel.range.style) ] `Range.Style` property\n* [ [d](https://learn.microsoft.com/en-us/office/vba/api/excel.sheets) ] `Sheets` object\n* [ [d](https://learn.microsoft.com/en-us/office/vba/api/excel.style) ] `Style` object\n* [ [d](https://learn.microsoft.com/en-us/office/vba/api/excel.styles) ] `Styles` object\n* [ [d](https://learn.microsoft.com/en-us/office/vba/api/excel.worksheetfunction.match) ] `WorksheetFunction.Match` method\n* [ [d](https://learn.microsoft.com/en-us/office/vba/api/excel.worksheet) ] `Worksheet` objet\n  * [ [d](https://learn.microsoft.com/en-us/office/vba/api/excel.worksheet.name) ] `Worksheet.Name` property\n* [ [d](https://learn.microsoft.com/en-us/office/vba/api/excel.worksheets) ] `Worksheets` object\n\ndata types\n* [ [d](https://learn.microsoft.com/en-us/office/vba/language/reference/user-interface-help/currency-data-type) ] Currency\n\n[ [d](https://learn.microsoft.com/en-us/office/vba/language/reference/error-messages) ] Error messages\n* [ [d](https://learn.microsoft.com/en-us/office/vba/Language/Reference/User-Interface-Help/subscript-out-of-range-error-9) ] `Error 009` Subscript out of range\n* [ [d](https://learn.microsoft.com/en-us/office/vba/Language/Reference/User-Interface-Help/type-mismatch-error-13) ] `Error 013` Type mismatch\n* [ [d](https://learn.microsoft.com/en-us/office/vba/language/reference/user-interface-help/wrong-number-of-arguments-error-450?f1url=%3FappId%3DDev11IDEF1%26l%3Den-US%26k%3Dk(vblr6.chm1000450)%3Bk(TargetFrameworkMoniker-Office.Version%3Dv16)%26rd%3Dtrue) ] `Error 450` Wrong number of arguments\n\n\n## Terms\n\n* [ [w](https://en.wikipedia.org/wiki/BASIC) ] Basic\n* [ w ] Cell\n* [ w ] Column Label\n* [ w ] Conditional Formatting\n* [ w ] Filter\n* [ w ] Formula\n* [ w ] Freeze\n* [ w ] Function\n* [ [w](https://en.wikipedia.org/wiki/Macro_(computer_science)) ] Macro\n* [ [w](https://en.wikipedia.org/wiki/Microsoft_Excel) ] Microsoft Excel\n* [ [w](https://en.wikipedia.org/wiki/Microsoft_Office) ] Microsoft Office\n* [ w ] Module\n* [ w ] Pane\n* [ w ] Pivot Chart\n* [ [w](https://en.wikipedia.org/wiki/Pivot_table) ] Pivot Table\n* [ w ] Row Index\n* [ w ] Sheet\n* [ [w](https://en.wikipedia.org/wiki/Spreadsheet) ] Spreadsheet\n* [ w ] Subroutine\n* [ [w](https://en.wikipedia.org/wiki/Table_(information)) ] Tablular Data\n* [ [w](https://en.wikipedia.org/wiki/VBScript) ] VBScript\n* [ [w](https://en.wikipedia.org/wiki/Visual_Basic_(classic)) ] VB Visual Basic\n* [ [w](https://en.wikipedia.org/wiki/Visual_Basic_.NET) ] VB .NET\n* [ [w](https://en.wikipedia.org/wiki/Visual_Basic_for_Applications) ] VBA Visual Basic for Applications\n* [ w ] Worksheet\n\n## Notes\n\n`.xlsx` Excel Workbook\n`.xlsm` Excel Workbook (macro-enabled)\n\nModule (right-click \u003e \"Insert\" \u003e \"Module\")\n* an organizational unit of VBA code that's usually attached to a workbook or worksheet\n\nSpecify cells of a spreadsheet\n* `Cells(\u003crow\u003e, \u003ccol\u003e)` numeric, coordinate-based\n  * `Cells(1, 1)` designates row 1, col 1\n* `Ranges`\n  * `F5:F7` contiguous\n  * `R2,D2` noncontiguous\n* `.Value`\n\nclears\n* `.Clear`\n* `.ClearContents`\n* `.ClearFormats`\n* `ActiveSheet.UsedRange.Delete`\n* `Sheets(\"Sheet1\").Cells.Clear`\n\nComments `'`\n\nVariable Declaration\n`Dim \u003cname\u003e As \u003ctype\u003e`\n\nTypes\n* `Double`\n* `Integer`\n* `String`\n  * `Split`\n\nCast\n* int to string `Str()`\n* string to int `Int()`\n\nArrays\n* zero-indexed\n\nConditionals `If` `Then` `End If` `ElseIf` `Else` `And` `Or` `For` `Each`","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fheracliteanflux%2Fexercises-vba","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fheracliteanflux%2Fexercises-vba","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fheracliteanflux%2Fexercises-vba/lists"}