Reduce VBA Errors by 90% (with this little-known Method)
Reduce VBA Errors by 90% (with this little-known Method)
In this video I'm going to show you a little-known method for reducing errors in your code by 90%. This method that I'm referring to is the Debug.Assert statement. You may have come across the Debug.Assert statment but you probably don't know how powerful it is when you use it correctly.
In this video I'm going show how, when used correctly, Debug.Assert can help you identify and remove errors within seconds of them occurring. You can give you code to the user safe in the knowledge that it isn't full of errors.
SUBSCRIBE TO THE CHANNEL: https://bit.ly/36hpTCY
DOWNLOAD THE DEMO WORKBOOK: Get the VBA code for this video here: https://bit.ly/38dLTSr
Related Post: VBA Assert – How To Make Your Code BulletProof(https://excelmacromastery.com/vba-assert/)
Related Training
The Excel VBA Handbook Course(https://TheExcelVBAHandbook.com)
Free Excel VBA Resources
Excel VBA Articles (https://excelmacromastery.com/vba-articles/)
Useful VBA Shortcut Keys
========================
Debugging:
Compile the code: Alt + D + C OR Alt + D + Enter
Run the code from the current sub: F5
Step into the code line by line: F8
Add a breakpoint to pause the code: F9(or click left margin)
Windows:
View the Immediate Window: Ctrl + G
View the Watch Window: Alt + V + H
View the Properties Window: F4
Switch between Excel and the VBA Editor: Alt + F11
View the Project Explorer Window: Ctrl + R
Writing Code:
Search keyword under cursor: Ctrl + F3
Search the word last searched for: F3
Auto complete word: Ctrl + Space
Get the definition of the item under the cursor: Shift + F2
Go to the last cursor position: Ctrl + Shift + F2
Get the current region on a worksheet: Ctrl + Shift + 8(or Ctrl + *)
To move lines of code to the right(Indent): Tab
To move lines of code to the left(Outdent): Shift + Tab
Delete a Line: Ctrl + Y(note: this clears the clipboard)
Table of Contents:
00:00 - Introduction
00:57 - 3 Error Types
01:07 - Syntax Errors
02:16 - Compile Errors
03:33 - Runtime Errors
04:53 - Runtime Errors - Logical
08:22 - Debug Assert Application Example
10:27 - Debug.Assert Guidelines
12:15 - Turn off Debug.Assert
14:54 - Summary of Debug.Assert
16:51 - Download the source code
Видео Reduce VBA Errors by 90% (with this little-known Method) канала Excel Macro Mastery
In this video I'm going to show you a little-known method for reducing errors in your code by 90%. This method that I'm referring to is the Debug.Assert statement. You may have come across the Debug.Assert statment but you probably don't know how powerful it is when you use it correctly.
In this video I'm going show how, when used correctly, Debug.Assert can help you identify and remove errors within seconds of them occurring. You can give you code to the user safe in the knowledge that it isn't full of errors.
SUBSCRIBE TO THE CHANNEL: https://bit.ly/36hpTCY
DOWNLOAD THE DEMO WORKBOOK: Get the VBA code for this video here: https://bit.ly/38dLTSr
Related Post: VBA Assert – How To Make Your Code BulletProof(https://excelmacromastery.com/vba-assert/)
Related Training
The Excel VBA Handbook Course(https://TheExcelVBAHandbook.com)
Free Excel VBA Resources
Excel VBA Articles (https://excelmacromastery.com/vba-articles/)
Useful VBA Shortcut Keys
========================
Debugging:
Compile the code: Alt + D + C OR Alt + D + Enter
Run the code from the current sub: F5
Step into the code line by line: F8
Add a breakpoint to pause the code: F9(or click left margin)
Windows:
View the Immediate Window: Ctrl + G
View the Watch Window: Alt + V + H
View the Properties Window: F4
Switch between Excel and the VBA Editor: Alt + F11
View the Project Explorer Window: Ctrl + R
Writing Code:
Search keyword under cursor: Ctrl + F3
Search the word last searched for: F3
Auto complete word: Ctrl + Space
Get the definition of the item under the cursor: Shift + F2
Go to the last cursor position: Ctrl + Shift + F2
Get the current region on a worksheet: Ctrl + Shift + 8(or Ctrl + *)
To move lines of code to the right(Indent): Tab
To move lines of code to the left(Outdent): Shift + Tab
Delete a Line: Ctrl + Y(note: this clears the clipboard)
Table of Contents:
00:00 - Introduction
00:57 - 3 Error Types
01:07 - Syntax Errors
02:16 - Compile Errors
03:33 - Runtime Errors
04:53 - Runtime Errors - Logical
08:22 - Debug Assert Application Example
10:27 - Debug.Assert Guidelines
12:15 - Turn off Debug.Assert
14:54 - Summary of Debug.Assert
16:51 - Download the source code
Видео Reduce VBA Errors by 90% (with this little-known Method) канала Excel Macro Mastery
Показать
Комментарии отсутствуют
Информация о видео
Другие видео канала
How to Design and Code an Excel VBA Application Like a ProHow VBA Objects Really Work in MemoryHow to easily automate boring Excel tasks with Power Query!Office Scripts vs Excel VBA (Everything you need to know)VBA Error Handling Explained in Plain English (with examples)How to make your Excel VBA code run 1000 times faster.How to Use Arrays Instead of Ranges in Excel VBAMaster Excel MACROS & VBA in ONLY 1 HOUR!How to Solve a VBA Error in Less Than a MinuteExcel VBA: Copy Data Between ANY Two SheetsHow to Build a Trading Simulator using Excel VBAHow to use ADO and VBA to Read from WorksheetsVBA Advanced Filter - The FASTEST way to Copy and Filter Data5 Killer Excel VBA Tips Everyone Should KnowHow to Use Class Interfaces in Excel VBAHow to Automate Your Work with an Office Script Bot7 Simple Practices for Writing Super-Readable VBA CodeWhich Excel VBA Method is the FASTEST for summing data?Excel VBA Collections: How to use Collections (1/5)Excel VBA: The Little-known secrets of ByVal and ByRef