VBA
'''Visual Basic for Applications''' ('''VBA''') is an implementation of Microsoft's event-driven programming language Visual Basic, and associated IDE, which is built into most Microsoft Office applications. It was included in Office applications (apart from version 2008 for Mac OS X), other Microsoft applications such as MapPoint and Visio, and at least partially implemented in some other applications such as AutoCAD, WordPerfect and ArcGIS. It supersedes and expands on the capabilities of earlier application-specific macro programming languages such as Word's WordBasic, and can be used to control many aspects of the host application, including manipulating user interface features, such as menus and toolbars, and working with custom user forms or dialog boxes.
As its name suggests, VBA is closely related to Visual Basic and uses the Visual Basic Runtime, but can normally only run code within a host application rather than as a standalone application. It can, however, be used to control one application from another using OLE Automation.
VBA has some important limitations, such as restricted support for function pointers which are used as callback functions in the Windows API. It has the ability to use (but not create) (ActiveX/COM) DLLs, and later versions add support for class modules.
As far was Rosetta Code is concerned, Visual Basic and VBA are ''mostly'' interchangeable, with minimal editing necessary to move from one to the other.
Tasks
- 100 doors
- 15 Puzzle Game
- 24 game
- 9 billion names of God the integer
- A+B
- ABC Problem
- AKS test for primes
- Abbreviations, automatic
- Abbreviations, easy
- Abbreviations, simple
- Abstract type
- Abundant, deficient and perfect number classifications
- Ackermann function
- Address of a variable
- Align columns
- Aliquot sequence classifications
- Almost prime
- Amicable pairs
- Anagrams
- Angle difference between two bearings
- Anonymous recursion
- Anti-primes
- Apply a callback to an array
- Archimedean spiral
- Arithmetic-geometric mean
- Arithmetic/Integer
- Array concatenation
- Array length
- Arrays
- Assertions
- Associative array/Creation
- Associative array/Iteration
- Average loop length
- Averages/Arithmetic mean
- Averages/Mean angle
- Averages/Mean time of day
- Averages/Median
- Averages/Mode
- Averages/Pythagorean means
- Averages/Root mean square
- Averages/Simple moving average
- Babbage problem
- Balanced brackets
- Barnsley fern
- Base64 encode data
- Best shuffle
- Binary digits
- Binary search
- Binary strings
- Bitwise operations
- Boolean values
- Box the compass
- Bulls and cows
- Bulls and cows/Player
- CSV data manipulation
- CSV to HTML translation
- CUSIP
- Caesar cipher
- Call a function
- Call a function in a shared library
- Call an object method
- Case-sensitivity of identifiers
- Catalan numbers
- Catamorphism
- Character codes
- Check that file exists
- Cheryl's Birthday
- Chinese remainder theorem
- Cholesky decomposition
- Circles of given radius through two points
- Classes
- Closest-pair problem
- Collections
- Color of a screen pixel
- Combinations
- Comma quibbling
- Commatizing numbers
- Comments
- Compare a list of strings
- Compound data type
- Concurrent computing
- Conditional structures
- Continued fraction
- Convert seconds to compound duration
- Copy a string
- Count in octal
- Count occurrences of a substring
- Count the coins
- Create a file
- Create a two-dimensional array at runtime
- Create an HTML table
- Currency
- Date format
- Day of the week
- Delete a file
- Detect division by zero
- Determinant and permanent
- Determine if a string is numeric
- Digital root
- Dijkstra's algorithm
- Dining philosophers
- Dot product
- Draw a pixel
- Egyptian division
- Emirp primes
- Empty directory
- Empty program
- Empty string
- Enumerations
- Ethiopian multiplication
- Euler method
- Euler's sum of powers conjecture
- Even or odd
- Exceptions
- Exponentiation operator
- Exponentiation order
- Extensible prime generator
- Factorial
- Factors of an integer
- Fibonacci n-step number sequences
- Fibonacci sequence
- Find limit of recursion
- Find palindromic numbers in both binary and ternary bases
- Finite state machine
- Five weekends
- Fivenum
- FizzBuzz
- Floyd's triangle
- Formatted numeric output
- Fractran
- Function definition
- Gauss-Jordan matrix inversion
- Gaussian elimination
- General FizzBuzz
- Generate lower case ASCII alphabet
- Generator/Exponential
- Greatest common divisor
- Greatest element of a list
- Guess the number
- Guess the number/With feedback
- Guess the number/With feedback (player)
- Hamming numbers
- Happy numbers
- Harshad or Niven series
- Haversine formula
- Hello world/Graphical
- Hello world/Standard error
- Heronian triangles
- Higher-order functions
- Hofstadter Figure-Figure sequences
- Hofstadter Q sequence
- Hofstadter-Conway $10,000 sequence
- Holidays related to Easter
- Horner's rule for polynomial evaluation
- IBAN
- Identity matrix
- Increment a numerical string
- Input loop
- Integer comparison
- Introspection
- Jaro distance
- Jensen's Device
- Jewels and Stones
- Jump anywhere
- Knapsack problem/0-1
- Knuth shuffle
- LU decomposition
- Langton's ant
- Leap year
- Least common multiple
- Leonardo numbers
- Letter frequency
- Levenshtein distance
- Linear congruential generator
- Look-and-say sequence
- Loops/Break
- Loops/Do-while
- Loops/Downward for
- Loops/For
- Loops/For with a specified step
- Loops/Foreach
- Loops/Increment loop index within loop body
- Loops/N plus one half
- Loops/Nested
- Loops/While
- Loops/Wrong ranges
- Loops/with multiple ranges
- Luhn test of credit card numbers
- Magic squares of odd order
- Make a backup file
- Mandelbrot set
- Matrix chain multiplication
- Matrix multiplication
- Matrix transposition
- Matrix-exponentiation operator
- Middle three digits
- Minesweeper game
- Modular arithmetic
- Modular inverse
- Morse code
- Multiplication tables
- Munchausen numbers
- Musical scale
- Mutual recursion
- N'th
- N-queens problem
- Named parameters
- Narcissist
- Narcissistic decimal number
- Negative base numbers
- Nested templated data
- Non-decimal radices/Convert
- Nth root
- Null object
- Number names
- Number reversal game
- Numerical integration
- Odd word problem
- Optional parameters
- Order two numerical lists
- Ordered words
- Palindrome detection
- Pangram checker
- Parsing/RPN calculator algorithm
- Parsing/Shunting-yard algorithm
- Pascal matrix generation
- Pascal's triangle
- Password generator
- Peano curve
- Penney's game
- Pentagram
- Perfect numbers
- Perfect shuffle
- Permutations
- Pernicious numbers
- Phrase reversals
- Pick random element
- Pig the dice game
- Play recorded sounds
- Playfair cipher
- Plot coordinate pairs
- Pointers and references
- Polynomial long division
- Polynomial regression
- Population count
- Power set
- Price fraction
- Primality by trial division
- Prime conspiracy
- Priority queue
- Problem of Apollonius
- Program name
- Program termination
- Proper divisors
- Pythagorean quadruples
- Pythagorean triples
- QR decomposition
- Quaternion type
- Queue/Definition
- Queue/Usage
- Quickselect algorithm
- Quine
- Range expansion
- Range extraction
- Read a file line by line
- Reduced row echelon form
- Remove duplicate elements
- Remove lines from a file
- Repeat
- Repeat a string
- Return multiple values
- Reverse words in a string
- Roman numerals/Decode
- Roman numerals/Encode
- Roots of unity
- Run-length encoding
- Sailors, coconuts and a monkey problem
- Sattolo cycle
- Search a list
- Send email
- Set
- Set consolidation
- Seven-sided dice from five-sided dice
- Shoelace formula for polygonal area
- Short-circuit evaluation
- Show Ascii table
- Sierpinski carpet
- Sierpinski pentagon
- Sierpinski triangle
- Sieve of Eratosthenes
- Sleep
- Sort numbers lexicographically
- Sorting algorithms/Bead sort
- Sorting algorithms/Bogosort
- Sorting algorithms/Bubble sort
- Sorting algorithms/Cocktail sort
- Sorting algorithms/Comb sort
- Sorting algorithms/Counting sort
- Sorting algorithms/Gnome sort
- Sorting algorithms/Heapsort
- Sorting algorithms/Insertion sort
- Sorting algorithms/Pancake sort
- Sorting algorithms/Quicksort
- Sorting algorithms/Selection sort
- Special variables
- Spelling of ordinal numbers
- Spiral matrix
- Split a character string based on change of character
- Stable marriage problem
- Stack
- Stack traces
- Statistics/Basic
- Statistics/Normal distribution
- String append
- String case
- String concatenation
- String interpolation (included)
- String length
- String matching
- String prepend
- Strip a set of characters from a string
- Strip block comments
- Strip whitespace from a string/Top and tail
- Substring
- Suffixation of decimal numbers
- Sum and product of an array
- Sum multiples of 3 and 5
- Sum of a series
- Sum of squares
- System time
- Taxicab numbers
- Temperature conversion
- Test a function
- Text between
- The Name Game
- The Twelve Days of Christmas
- Thue-Morse
- Tic-tac-toe
- Time a function
- Tokenize a string
- Tokenize a string with escaping
- Top rank per group
- Topic variable
- Total circles area
- Totient function
- Tree traversal
- Trigonometric functions
- Twelve statements
- Two Sum
- Type detection
- UTF-8 encode and decode
- Universal Turing machine
- Van der Corput sequence
- Variables
- Vector
- Vector products
- Verify distribution uniformity/Chi-squared test
- Vigenère cipher
- Web scraping
- Window creation
- Word frequency
- Write entire file
- Write float arrays to a text file
- XML/Input
- Y combinator
- Yin and yang
- Zebra puzzle
- Zeckendorf number representation
- Zero to the zero power
- Zhang-Suen thinning algorithm
- Zig-zag matrix