Yes.
Set a reference to MS Scripting runtime (‘Microsoft Scripting Runtime’). As per @regjo’s comment, go to Tools->References and tick the box for ‘Microsoft Scripting Runtime’.
Create a dictionary instance using the code below:
Set dict = CreateObject("Scripting.Dictionary")
or
Dim dict As New Scripting.Dictionary
Example of use:
If Not dict.Exists(key) Then dict.Add key, value End If
Don’t forget to set the dictionary to Nothing
when you have finished using it.
Set dict = Nothing
Related Posts:
- What does <> mean?
- How can I remove a key from a Python dictionary?
- How can I remove a key from a Python dictionary?
- How to find a value in an excel column by vba code Cells.Find
- Check if a string contains another string
- VBScript to open a dialog to select a filepath
- In Python, when to use a Dictionary, List or Set?
- Quick Way to Implement Dictionary in C
- “Sub or Function not defined” when trying to run a VBA script in Outlook
- What is the function of FormulaR1C1?
- What exactly is the function of Application.CutCopyMode property in Excel
- What is the difference between a map and a dictionary?
- VBA Excel – Insert row below with same format including borders and frames
- Deleting a file in VBA
- Excel VBA: Can’t get a match, error “Unable to get the Match property of the WorksheetFunction class”
- How to comment and uncomment blocks of code in the Office VBA Editor
- Run-time error ‘3061’. Too few parameters. Expected 1. (Access 2007)
- Pass arguments to Constructor in VBA
- VBA array sort function?
- How to install Date Picker form control in Excel 2016
- How to install Date Picker form control in Excel 2016
- How to fill color in a cell in VBA?
- Refreshing all the pivot tables in my excel workbook with a macro
- VBA: Run time error ’91’?
- Compare Dates in VBA
- What is the difference between “Form Controls” and “ActiveX Control” in Excel 2010?
- ‘Cannot find DAO350.dll’ file error VB6
- Average in VBA in Excel
- VBA Excel “Compile error: Object Required”
- Choosing paper size (NOT DEFAULT sizes) in excel vba
- “Unable to get the VLookup property of the WorksheetFunction Class” error [duplicate]
- Paste Special error 1004 PasteSpecial method of Range class failed
- VBA: Getting run-time 1004: Method ‘Range’ of object ‘_Worksheet’ failed when using cells
- Cannot run the macro… the macro may not be available in this workbook
- What is the difference between Python’s list methods append and extend?
- Search for words with telephone numbers from 2-3-4 tree
- Iterating over dictionaries using ‘for’ loops
- How do I sort a dictionary by value?
- How do I sort a dictionary by value?
- How can I implement a tree in Python?
- How do I merge two dictionaries in a single expression (taking union of dictionaries)?
- How do I merge dictionaries together in Python?
- Difference between binary tree and binary search tree
- Python list of dictionaries search
- Updating a dictionary in python
- unhashable type: ‘dict’ Type Error [duplicate]
- Priority queue in .Net
- Explanation of runtimes of BFS and DFS
- Array versus linked-list
- A proper way to create a matrix in c++
- How to use Regular Expressions (Regex) in Microsoft Excel both in-cell and loops
- Does Java support structs?
- How to use Regular Expressions (Regex) in Microsoft Excel both in-cell and loops
- Angular map. What is it?
- Map like structure in C: use int and struct to determine a value
- What is the best way to iterate over a dictionary?
- Creating 2D dictionary in Python
- Minimum Spanning Tree: What exactly is the Cut Property?
- Converting Dictionary to List?
- How do I efficiently iterate over each entry in a Java Map?
- How can I get list of values from dict?
- Excel VBA Macro: User Defined Type Not Defined
- TypeError: string indices must be integers, not str // working with dict
- Collection was modified; enumeration operation may not execute
- VBA Runtime Error 1004 “Application-defined or Object-defined error” when Selecting Range
- How to return dictionary keys as a list in Python?
- How to save a dictionary to a file?
- How do I instantiate a Queue object in java?
- Why does “Paste Method of Worksheet class failed” occasionally occur?
- Trie complexity and searching
- How do I print the key-value pairs of a dictionary in python
- Difference between a HashMap and a dictionary ADT
- How do you sort a dictionary by value?
- How to return a result from a VBA function
- Appending values to dictionary in Python
- Use VBA to Clear Immediate Window?
- Implementing a HashMap in C
- Python Add to dictionary loop
- creating an array of structs in c++
- AttributeError: ‘str’ object has no attribute ‘items’
- convert csv file to list of dictionaries
- Declaring a multi dimensional dictionary in python
- VBA: Convert Text to Number
- VBA Error: “Compile error: Expected End Sub”
- python-How to solve KeyError: 2?
- How to search through dictionaries?
- Why is O(n) better than O( nlog(n) )?
- Loop without Do error
- How exactly do lookup tables work and how to implement them?
- What do I use for a max-heap implementation in Python?
- Why are there no hashtables in the C standard library?
- When to use a Map instead of a List in Java?
- How to Clear Office Clipboard with VBA
- invalid use of template name without an argument list
- Why does my VBA code throw an “Invalid outside procedure” error?
- Map vs Object in JavaScript
- python dictionary error AttributeError: ‘list’ object has no attribute ‘keys’
- Convert list of dictionaries to a pandas DataFrame
- C# Dictionary get item by index
- Is there a way to crack the password on an Excel VBA Project?