Difference Between Module And Class Module In Vba















DATEDIFF Function in VBA calculates the difference between in two dates in days, months, quarters, and years. To really understand the difference you need to know a little about something called object-oriented programming ("OO"). The class types are user-defined classes, boxed value types, and delegates. Re: Userform Initialize vs Userform Show This may help you understand the difference between Show/Load and Hide/Unload Show and Load The method used to launch a UserForm can be a CommandButton placed on a Worksheet, a Custom menu bar, the standard menu bar, shortcut key etc. One of the modules is designated as the main or top-level file, and this is the one launched to start the entire program. Re: Difference between module and class module Originally Posted by radieux_scablem However the main difference between class module and standard module is that in standard module u can use directly all the procedures and functions as long as it was declared public while in class module u must first create an object of the class and then set. The Code Explorer is a bit of an hybrid between the VBE’s Project Explorer and Object Browser windows – we see all the members of every module, and we can double-click navigate anywhere. Class is a blueprint or template from which objects are created. Let’s take a look at some of the differences between the two and when they should be used. This answer assumes that you know basic functionality and application of VBA in Microsoft Excel, If not, click here. Now, in MVBA/macro I noticed that it is only using Module or Code Module. In this way, they share fundamental similarity. A default instance of the UserForm1 class is created. A class can be so much more -- it can hold its state (by keeping track of instance variables) and be duplicated as many times as you want. A property is a data element defined on a module, class, or structure. a limited part of the program over which the variable exists). I am a newbie and want to learn VBA with excel. Microsoft Access Modules (VBA) There's lots we can do with access, and most things are accomplished using tables, queries, forms and reports. The main difference between the two is that class is a blueprint which is used to create different objects of same type. Many, if not most, procedures accept input parameters that are used to calculate the result of a function or otherwise direct the action of a procedure. Open the module by a double click on it. 2 CALCULATIONS WITHOUT VBA 3 1 Introduction Visual Basic for Applications, Excel’s powerful built-in programming lan-guage, permits you to easily incorporate user-written functions into a spread-sheet. Anything that you can describe conceptually can be represented by a class. Download with Google Download with Facebook or download with email. What is the difference between Sub, Function, Module and code. Don't forget that array element numbering begins with 0 (this is standard in programming, so it's a good idea to get in the habit of working this way, even though it is actually possible to change this convention in VBA). Getting started with Python Language, Python Data Types, Indentation, Comments and Documentation, Date and Time, Date Formatting, Enum, Set, Simple Mathematical Operators, Bitwise Operators, Boolean Operators, Operator Precedence, Variable Scope and Binding, Conditionals and Loops. If the variable is declared in the declarations section of a standard code module, then there is no difference between public and global. To create a Class definition in VBA, you will select Insert / Class Module from the VBA menu (while in the correct project, of course). Difference between ByRef ByVal. Each time the procedure is called, the statements between Sub and End Sub are executed. A module can hold many procedures or just one. Visual Basic - Modules and Procedures Introduction A procedure is a unit of code enclosed either between the Sub and End Sub statements or between the Function and End Function statements. This function module can be used to Upload and Download files from/to application server. This is an object. Common data required to pass repeatedly as data sharing is not possible between modules. Should I add it "This workbook" or a new module. Let us say you want to write a function that works out someone's age after you have supplied their date of birth. Function modules are sub-programs that contain a set of reusable statements with importing and exporting parameters. Excel VBA Macro Sub or Function not defined. The Create a Macro chapter illustrates how to run code by clicking on a command button. In this tutorial we will learn how to use variables, conditions & loops in Excel VBA. The main difference between classes and modules is that classes can be instantiated as objects while standard modules cannot. 2) Object is a real world entity such as pen, laptop, mobile, bed, keyboard, mouse, chair etc. A class module allows you to create new objects, along with corresponding properties, methods, and events. The addition of standalone class modules in Visual Basic for Applications or VBA is a welcome site to users and would be developers. To enable this feature for all new modules, do the following: In the VBE, choose Tools, Options. Excel VBA Object Versus Module? 8 posts what is the difference between writing code in the Micosoft Excel Object folder OR the Module Folder? Class Module, UserForm, or code for a specific. There are a few different ways of doing so with results available in a few different formats. Class Module VBA Tutorial This video explains how to setup and use class modules in VBA (visual basic for applications). So i want to enhance my computer knowledge on VBA. Otherwise it will default to Module# vs it's saved name. When the application is finished you would write the values back to the file. Any time you refer to a procedure or public variable in a standard module, that module is automatically loaded into memory if it hasn't already been loaded. You don't want to lose work you've done, bugs you've fixed, or features you've added. The example I see in VB Help uses square brackets and a project file : MacroName() Since I want to call one subroutine from a macro in another module, I tried the following : Call AddShortcut(x, y, z) where x,y,z are the arguments passed to the. I now want to find the intersection between A2 and B2, so the class module is now initiated again by pushing the tool button X. It can be found in the directory of your xlwings installation. I am in the process of trying to create a DragNDrop feature in the Access database that I've built. In Windows Explorer, select the files you would like to drag into your project. The reason being when we press ALT+F11, displays a window. No matter how experienced you’re with VBA coding, errors are always going to be a part of it. You create Standard modules by selecting the Modules icon in the Database window and then clicking New. Training Module Facilitator’s Guide 5 Training Manuals Training manuals include selected content from the modules. Public - anywhere in the same project, from other projects that reference the project, and from any assembly built from the project. A Standard Module: A module containing only procedure, type, and data declarations and definitions. The main difference between classes and modules is that classes can be instantiated as objects while standard modules cannot. Excel VBA Object Versus Module? 8 posts what is the difference between writing code in the Micosoft Excel Object folder OR the Module Folder? Class Module, UserForm, or code for a specific. In this blog I have assumed the user is comfortable with Visual Basic and creating VBA macros in Excel. Thus an abstract class can implement methods but an interface can not implement methods. Last week we have seen how to insert a Click Event Procedure in a Form Module with a Function. This has been a guide to VBA Class. By default the number of years, months, weeks, days, hours, minutes, and seconds are calculated, and the first non zero unit is displayed. So far you have added style to various elements in your portfolio page, but the styles you've added have affected all elements of a particular type. I'll also cover a lot of practical examples on using Worksheets. When the program is generated, the source code in the modularization unit is treated as though it were actually. Note: This example not Export/Import the code in sheet modules and from the Thisworkbook module. (2) In hardware, a module is a self-contained component. Place a command button on your worksheet and add the following code. When you've typed a name, click the Open button. Please follow the below steps to execute the VBA code to save the excel file. Modules do not support inheritance or implement interfaces. Now, in MVBA/macro I noticed that it is only using Module or Code Module. 6 Microsoft Access 2010 VBA Macro Programming. When I said "private module", I didn't mean that its functions and methods would be inaccessible from outside. Babel is a free and open-source JavaScript transpiler. Module level Variables in VBA. In the example, the specified employee name is "Benson, Paul", and so the VBA Vlookup function returns the value $32. We can save N number of Function Modules in a Function Group. We use Excel as a tool for processing our applied data. The difference between a class and an object is that a class does nothing and consumes no. In Visual Basic Applications Function and sub Procedures plays vital roles as we know that Microsoft Application like Excel and word contains a lot of functions and by using it we can perform our complex tasks in a simple way and VBA provides a facility to create our own function or sub procedure and perform our task and reuse code inside our Application. Visual Basic for Applications (VBA) is an implementation of Microsoft's event-driven programming language Visual Basic 6, Visual Basic for Applications enables building user-defined functions (UDFs), automating processes and accessing Windows API. Copy Excel VBA Code to a Worksheet Module Another type of Excel code is Event code, which runs automatically when something specific occurs in the workbook. They are a class module. Within a project, code is placed in separate code files called modules, and within each module, the Visual Basic code is further separated into self contained and re-usable procedures. The difference is that Global variables can only be used in modules, whereas Public can be used in all contexts/scopes e. In addition, it greatly increases the accuracy and reliability of using VBA in Excel. some variables I use in my module turn to "out of context" when I return to (not a class) module: Just for information sakes, what's the difference between a. > Thanks > Vilem Sova. These procedures are called property procedures or property accessors. VBA will pass over to the SecondCode Sub whatever is inside of these variables. Modules cannot be instantiated like classes. I need to create a very simple database that would just store records and produce a couple of reports. A worksheet module (e. Under the covers, there is no difference between a class used as an interface and a regular class, other than that the procedures defined within an. This website uses cookies so that we can provide you with the best user experience possible. A class module contains code that's either attached to an existing form or report or is its own entity in the Navigation pane. Add new command bars and their buttons, handle events, create custom ribbon tabs and ribbon controls, task panes and context menus etc. Class and Object are two most important concept of Object oriented programming language. So far you have added style to various elements in your portfolio page, but the styles you've added have affected all elements of a particular type. DiffEngineX is a software application which finds the differences between the VBA (Visual Basic for Application) macros, classes and modules embedded in two different Microsoft Excel workbooks. You don't want to lose work you've done, bugs you've fixed, or features you've added. Userform and Class Module are not relevant now, we are going to learn about them later. and you can even customize them. The difference between a novice and an expert VBA programmer is that the expert programmers know how to effectively handle and use errors. There are tasks you can create and a To-Do list in the left hand side bar. ) Because you can put as many macros into one module as you like, you'll usually get along with just that one module. In fact, pretty much the only significant difference between a Form (class) module and an external Class Module is a Class Module has Initialize and Terminate events. Usually a class module has data and methods for working with that data. Step 3: Insert a code module from then insert menu. In VBA a module is essentially a text file integrated into the parent application. Am I correct? Also, can you please tell me what is the keyword used to define a new class?. Getting started with Python Language, Python Data Types, Indentation, Comments and Documentation, Date and Time, Date Formatting, Enum, Set, Simple Mathematical Operators, Bitwise Operators, Boolean Operators, Operator Precedence, Variable Scope and Binding, Conditionals and Loops. But its harder to learn how to make object then learn how to make function. We use procedures and functions to create modular programs. VBA is used for automation operations in applications such as Microsoft Excel and also expands it's capabilities. In this tutorial we will learn how to use variables, conditions & loops in Excel VBA. The VBA Object model allows one to access the full power of VBA and the methods of Excel. As always, we will use an easy example to make things more clear. If any variable is used anywhere in the program without. I'll also cover a lot of practical examples on using Worksheets. Right click on an ActiveX control and select View Code: The shell of the default procedure is inserted into the code module of the object the control is embedded within (i. VBA Class Modules | One Min. Free VBA Training Course You can easily learn VBA by working your way through the variety of free lessons that we offer. Module-level variables can be declared with a Dim or Private statement at the top of the module above the first procedure definition. A command launched from a single entry point; Allows replaying a set of actions typically recorded via the user interface; VBA. Between the Type line and the End Type line, you can declare one or more existing types as variables. Chapter 1: Where VBA Fits In 13 The main difference between a standard module and a class module is one of scope. 0 by David Musgrave (thank you David!) In the GP Software Development Kit (SDK), you can the document this posting was copied from, as well as a sample report using each one of these functions You can find the SDK in the Tools. As always, we will use an easy example to make things more clear. We are going to insert a new Module to the Objects. In VBA the class name is the Class Module name so you don't have a function statement like in C++. Published byLily Lamb Modified over 4 years ago. Lists, strings and tuples are ordered sequences of objects. One of the big differences between setting up a Sub and setting up a Function is the return type at the end. Click the Editor tab. But basically, the Variable declared at the top (Private) is only exposed to that module. You will notice that these objects have Methods that you can call (Sub-Routines or Functions) and they also have Properties that you can read/write. You start by creating a new Class Module, using either the Insert menu or the toolbar button to insert a new Class Module into your VBA Project. Apart from the obvious (A form has a UI), this is the main difference. So here comes my question; How am I able to call function 2 in module 2 from the function 1 which is located inside module 1? So I need to deliver parameters between these functions which are located in different modules. Relative dates are always a string indicating the difference between the date and right now. I know this question should have already played in your mind. The main difference between VBA Sub procedures and Function procedures is the following:. Difference between Module and Class | Module vs Class. In Excel Visual Basic, a set of commands to perform a specific task is placed into a procedure, which can be a Function procedure or a Sub procedure (also known as functions and subroutines). Set mainworkBook = ActiveWorkbook. I don’t say that the frm. When you look at the macro code in the Project Explorer, there is no visible difference between old VBA macro code and new VBA macro code. All you need for it to work is the class module -- it is completely independent of everything else in the database. By writing simple class modules that contain just attributes with a few simple methods, one can create data structures that allow easy loading and storing of data into VBA's memory. Because there is only one copy of a standard module's data, when one part of your program changes a public variable in a standard module, any other part of the program gets the same value if it then reads that variable. In addition, it greatly increases the accuracy and reliability of using VBA in Excel. Complete the following code: Option Compare Database Option Explicit Public OrderID As Long Public CustomerName As String Public Value As Currency. cannot be called from anywhere in a project. Programs are composed of one or more independently developed modules that are not combined until the program is linked. In VBA, a class is defined in class module and serves as a template for an object. If chunk is a string, the second parameter specifies how to encode it into a byte stream. Use only code here that you use yourself and not code that you use in files that you distribute to other users. What is the difference between a procedure and a function?. However, it is a global variable within the module. This solves the problem of repeated function entry by automating functions and actions. A process typically operates at a higher level, possibly across many functions, and may cross department lines. Kim explains how the module system works in Node. When the UserForm is displayed you read from the class to the UserForm controls. The words macro and function are often used interchangeably to refer to procedures written in Visual Basic For Applications (VBA). 3 What Are Access Class Modules, Standard Modules, Form Modules, and Report Modules? 1. But I wanted the difference. Maybe it's just because of the work I do, but I find I have no reason to use classes or even modules most of the time, unless I want a public function between different forms. Financial Accounting module helps one to get real-time financial position of an enterprise in the market. Hello, I need your help in creating multiple team center schema in single oracle database. Info: Properties are meant to replace getters and setters. Perhaps I'm not understanding the big difference between where my code is and where it should be. Exported Module Code for BangDemo. Right click on an ActiveX control and select View Code: The shell of the default procedure is inserted into the code module of the object the control is embedded within (i. You left out one more way of importing and exporting modules and userforms. The difference between the two are how they are invoked, and their ability to change the working environment. “Const” stands for “Constants” in VBA. Object Modules in Excel are: ThisWorkbook module, Sheet modules (worksheets and chart sheets), UserForm modules and Class modules. Data Dictionaries are like enhanced Collections. Unfortunately, I haven't found a single source that documents the entire object. At the module level, there is no difference between Dim and Private. This is a module definition. Term Definitions Macros. Excel's forum. What’s the difference between a Python module and a Python package? difference between a library and a module. Used only in a class module. There are 2 main differences between VBA Procedures (Subs) and VBA Functions: VBA Functions return values, VBA Subs don't; You can execute a VBA Sub, you can't execute VBA Functions - they can only be executed by VBA Subs. Difference Between Ranges Will compare two ranges of the same shape and output a list of all the differences and their the VBE insert a Module (not a Class Module. Once the 'Require Variable Declaration' option is selected, the Option Explicit will automatically be inserted at the top of all new modules in the VBA Editor. All VBA code that is called by your application is immediately ready for execution. Last week we have seen how to insert a Click Event Procedure in a Form Module with a Function. CLAP_DDB_GET_BUFFER_PARAMS to read the material characteristic values in buffer. Modules (or more specifically the VBA code in them) is why Access has become so popular among developers - it is possible to perform some extremely sophisticated, complicated processes in Access using VBA code, Windows API calls, etc. Spreadsheet's Bookshelf) - Michael Alexander. In this example the BAPI BAPI_USER_GET_DETAIL is executed. Also, we will use the term 'interface module' when refering to a class module that is used as an interface, and 'class module' when refering to a regular class module. Look at the below image. After you insert the control on your sheet you can add the code in the worksheet module. 1) Object is an instance of a class. But that you can access the class instance from another library once that has been done. In addition, it greatly increases the accuracy and reliability of using VBA in Excel. If you are used to using VBA in Excel, you will have noticed that each workbook and worksheet has its own module and the structure of modules reflects the sheets in your workbook. Class modules include ThisWorkbook, Sheet1 (and other sheet modules), Userforms, and class modules that you create. just get debug errors on things where I cant see any difference between what I am doing. I have some forms where I have deleted all their VBA code; is there a way I can now delete the modules from my Microsoft Visual Basic window? (folder at top of hierarchy is Microsoft Office Access Class Objects). The class module then terminates. To create a Class definition in VBA, you will select Insert / Class Module from the VBA menu (while in the correct project, of course). If you are used to using VBA in Excel, you will have noticed that each workbook and worksheet has its own module and the structure of modules reflects the sheets in your workbook. Python's re module can use Unicode strings. Understand the difference between CEO pay and CEO wealth. If the table exists then drop table, if not exists do something else. The journal consolidates research activities in photochemistry and solar energy utilization into a single and unique forum for discussing and sharing knowledge. You use the VBA IDE to add new modules to a file (such as an Access database or an Excel workbook) and write your VBA code in the module, using the text editor buil. strName = "B" aryEmployees(1). Class Modules are outside the scope of this post. Sheet1) is actually a class module. So, for my own documentation, I decided to write this. Publish a standard set of parameters that the VBS routine users can use to access the VBA code modules. To really understand the difference you need to know a little about something called object-oriented programming ("OO"). Class modules are used for defining classes or objects. To name the class, change the name of the class from "Class1" to the desired name in the Properties Pane. After you have installed the VBA Converter Pack, you must export each module sheet in the Visual Basic Project Explorer, remove the module sheet, and then import that module back into the workbook. Then, instead of placing all of the statements in your main program, you just call the module. So those centuries are now known as "The Darker Ages". Its how this code is used which is very different. , we get this result:. Bottom line: In this post we compare the different places to store macros, functions, & VBA code in Excel. I have gone to the VBA help files to try to find the difference and I am no better now than before. The modDateTime module provides extensive code to deal with date and time values. Maybe it's just because of the work I do, but I find I have no reason to use classes or even modules most of the time, unless I want a public function between different forms. Could someone guide me when is the best situation to use Module or Class. Difference Between Clear & Delete Methods. js, providing a better understanding of the difference between module. T-codes for Function Modules and Function groups are SE37 OR SE80. 9 Executing Procedures from the Module Window. What difference does it make if one runs a VBA code in "Sheets", in "ThisWorkbook", and in "Modules"? Ask Question Asked 6 years, 11 months ago. Best Answer: Very little, but mostly a module is used for non-object oriented programming, and class is used for object oriented programming. Subroutines are normally called internally, that is, they contain sections of code or algorithms that are used frequently locally. Let's assume that I have function 1 in module 1, function 2 in module 2 and function 3 in module 3. Examples: Definition of variables/objects: in VBA it is very common to use “Dim var1 as String” notation. A code module is referred to as a standard module in later versions of Visual Basic. Advanced Topics in Corporate Finance. VBA has no ROUND function, but Excel does. These code units are called standard modules, or sometimes general modules or global modules. Look at the below image. Modules & VBA :: Drop Table Using If Argument Oct 1, 2013. Property Procedures - Passing Information to and from Forms A userform is a convenient, professional-looking interface between a VBA procedure and the user. When you use the method "Delete" it will delete the cell and the below cell will take over the position of the deleted cell. 1) Object is an instance of a class. This module covers the topics for data manipulation, setting source for chart data and accessing different chart properties like series color, legends, axis formatting, overall general formatting. A module does not exist within a form, so that context is not available. DATEDIFF Function in VBA calculates the difference between in two dates in days, months, quarters, and years. However, you need to remember that a VBScript class doesn't support events. The file contains code (VBA in the case of an. Class 10c is a private bushfire shelter. The main problem that people first experience with event macros is installing them in a standard module where they will simply be ignored. By default it create infodba schema in oracle with some tablespace when you install teamcenter, If I want to do another installation on same database it’ll overwrite the existing infodba schema. An add-in can be useful when you have to repeat tasks. VBA code in a standard module has a global scope, which means that the code can be accessed by every object in the database. The variable can then be used from any procedure within the module, and it retains its value from one procedure to another. General vba code in respect of events not associated with a particular object (like workbook or worksheet) are placed in the Standard Code Module. Modules (or more specifically the VBA code in them) is why Access has become so popular among developers - it is possible to perform some extremely sophisticated, complicated processes in Access using VBA code, Windows API calls, etc. I cover Function procedures in this separate Excel tutorial. This is great news for all of the nearby PASS User Groups and DBA’s. We can use the same code we use in normal modules. i know about let get property but i don’t know how much data we can store in a class could you give me a brief on how much data we can store in class and a class instant how much take place in memory. Could someone guide me when is the best situation to use Module or Class. If you plan to use Excel in your job, than learning VBA has its advantages! Enroll in this course to automate, and customize your Excel 2007, 2010, 2013, or 2016 files with hours of Video Lectures, 40+ Articles, and 90+ Supplemental Resources. Also, it will allow to enhance the existing objects. We specifically look at the Code Modules, Sheet Module, and ThisWorkbook Module to learn the differences between how each works. Difference Between Processes and Procedures What Is a Process? A process is the conversion of an input into an output. In Excel Visual Basic, a set of commands to perform a specific task is placed into a procedure, which can be a Function procedure or a Sub procedure (also known as functions and subroutines). Check out our other blog posts for help with VBA in Excel. (For more information about the differences between. 6 Using the Line Continuation Character 1. In Excel VBA and VB6. At the module level, there is no difference between Dim and Private. All open modules are included in the Modules collection, whether they are uncompiled, are compiled, are in break mode, or contain the code that's running. For an example look at the below image. It can be something as simple as an alert to the user. However, while you create macros in Access by selecting from a list of macro actions, VBA (Visual Basic for Applications) programming language is used for writing modules. How To Create a Class Module in VBA - Duration:. Its helps us automating Microsoft applications and provide customized soulutions. answer to I am new in VBA. Hi, I'd like to call a macro from a different project so that I can reuse code. We will be learning how to use statements like Dim, IF THEN, ElSE, FOR Loop, For Each Loop and INPUTBOX function in this. com VBA Class Modules Versus VBA Normal Modules. So I wrote some code to find it. This module-based services model turns out to be the core idea behind program architecture in Python. Microsoft Access is a unique tool released by Microsoft that provides both the functionality of a database and the programming capabilities to create end-user screens. The main aim of machine learning is to learn from past data that able us to predict the future and upcoming data. The 12-month programme gives you the option to study the Investment Analysis Dissertation (45 credits) plus five optional modules or the Management Dissertation (30 credits) with seven optional modules. We can have multiple modules in visual basic editor window in Excel. We can use the same code we use in normal modules. I am new to Visual Basic 6 Class Modules and am having difficulty constructing a certain class. DATEDIFF Function in VBA calculates the difference between in two dates in days, months, quarters, and years. Step 1: Open any existing Excel Application. Excel VBA Macro Sub or Function not defined. It is a mixture of the class mechanisms found in C++ and Modula-3. What is the difference between a standard Module and a Class Module? A Class instance is basically and Object and has all the properties of Objects in VBA. , worksheets) within which they are embedded, or written in class modules. Its helps us automating Microsoft applications and provide customized soulutions. Last week we have seen how to insert a Click Event Procedure in a Form Module with a Function. Like Tony, I've never seen any measurable difference between the two, but it makes sense that Late Binding will take a little bit longer to initialize (because of needing to go through the Registry in order to get the information required to instantiate, as opposed to simply using a library). You need to create an empty frame control on your form where the Calendar Class will be placed. The difference between a class and an object is that a class does nothing and consumes no. Modules & VBA :: Drop Table Using If Argument Oct 1, 2013. @PredeclaredId: a simple parameterless annotation that translates into a VB_PredeclaredId (class) module attribute with a value of True, which is how UserForm objects can be used without Newing them up: the VBA runtime creates a default instance, in global namespace, named after the class itself. VBA will pass over to the SecondCode Sub whatever is inside of these variables. Here we learn how to create and use Class Module in Excel VBA and also the difference between the class module and object along with examples & downloadable templates. Each module contains different types of variables. Global variables are most likely kept for backwards compatibility (older versions of Excel) so I recommend you stick to using only Public variables. Properties and Methods. Visual Basic - Modules and Procedures Introduction A procedure is a unit of code enclosed either between the Sub and End Sub statements or between the Function and End Function statements. a relational database in Microsoft Access. (1) In software, a module is a part of a program. Class Module vs. Please follow the below steps to execute the VBA code to save the excel file. We derive a consistent pricing mechanism for the general class of fixed income (bond) assets; we then examine issue such as bonds with embedded derivatives, bonds with special provisions, bonds with equity. A class module contains code that's either attached to an existing form or report or is its own entity in the Navigation pane. Difference between Module and Class | Module vs Class. The only difference between the Windows versions is the user interface of Excel where you might find buttons in a different place (but they should all be there) while the Visual Basic editor is the same for all Windows Excel versions. MS Excel VBA Interview Questions and Answers with Examples. In this tutorial, I will show you various ways you can use to. (VB) or Visual Basic for Applications (VBA) involves manipulating various types of objects, each of which may have several different properties and methods. The difference between a novice and an expert VBA programmer is that the expert programmers know how to effectively handle and use errors. The main difference between classes and modules is that classes can be instantiated as objects while standard modules cannot. The urllib2 module defines functions and classes which help in opening URLs (mostly HTTP) in a complex world — basic and digest authentication, redirections, cookies and more. In this VBA tutorial, I focus on VBA Sub procedures.