Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

Dim In VB


PVJsquad
 Share

Recommended Posts

Basically, dim tells the system to reserve space for a specific data type to be used later on in the program. So once dimmed it would hold a specific data type. So, integer would hold whole numbers, long is really just int32, meaning it's an integer that can hold more numbers than the former.

Byte holds whole numbers up to 255, used when you don't need to use as much memory as an integer would, in exchange for the inability to store numbers more than 255\. An integer or long is actually made up of bytes.

A string is just an array of characters, each character being a byte large, so I would use them carefully as doing intensive operations with strings is very memory consuming. This is a string, "Hello, this is a string". so using dim as the case, to use them you would do.
```
dim tmpStr as string
tmpStr = "Everything within the quotes is part of the string"

```
This is just a brief, so as Robin said I'd probably go and google them some more to understand better.
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...