This document summarizes the different data types that can be used in VBA, including string, integer, long, single, double, currency, date, boolean, and variant for basic data, as well as object types like document, range, table, row, column, cell, style, and selection that relate to Microsoft Word. Each data type is given a prefix code to identify it and a brief description of what kind of data it represents.
This document summarizes the different data types that can be used in VBA, including string, integer, long, single, double, currency, date, boolean, and variant for basic data, as well as object types like document, range, table, row, column, cell, style, and selection that relate to Microsoft Word. Each data type is given a prefix code to identify it and a brief description of what kind of data it represents.
This document summarizes the different data types that can be used in VBA, including string, integer, long, single, double, currency, date, boolean, and variant for basic data, as well as object types like document, range, table, row, column, cell, style, and selection that relate to Microsoft Word. Each data type is given a prefix code to identify it and a brief description of what kind of data it represents.
String Data str Text Integer Data int Whole numbers up to approx. 32,000 Long Data lng Whole numbers up to approx. 2 billion Single Data sng Large floating point numbers with up to 6 decimal places of accuracy Double Data dbl Even larger floating point numbers with up to 14 decimal places of accuracy Currency Data cur Monetary values up to approx. 900 trillion with up to 4 decimal places of accuracy Date Data dat Date and time Boolean Data bln True or False Variant Data vnt Indeterminate data type - any of the above
Document Word object doc A Word (open) document
Range Word object rng A text range Table Word object tbl A Word table Row Word object row A row in a table Column Word object col A column in a table Cell Word object cel A cell in a table Style Word object stl A paragraph or character style Selection Word object sel The Word object which is currently selected