LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 279
Default user-defined data type capabilities

It seems I use Microsoft Visual Basic 6.5 from Microsoft Excel 2003.

I've just introduced my first user-defined data type (UDT) to a module.
I found it greatly simplified passing parameters.

Private Type Journey
Depart As String
Arrive As String
End Type

What can I do with such UDTs?
1) Declare functions and scalar, array, and parameter variables.
2) Assign e.g. Dim A as UDT, B as UDT: A = B
3) Not compare variables. e.g. if UDT0 = UDT1 ... gets an error.

What else can UDTs be used for?

When, in the Visual Basic Editor (VBE), I hover over code referencing a
variable or expression of a predefined type (Byte, Boolean, Integer,
....), the VBE displays its value.
Can this be extended to UDTs?
if so, how?

I assume such code would avoid the type mismatch I get if I do "?UDT" in
the immediate window.
--
Walter Briscoe
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
User defined data type (losing its data) Ludo Excel Programming 2 May 20th 09 11:34 AM
Wrong data type returned from user-defined function hooroy63 Excel Programming 9 January 13th 09 11:15 AM
Capabilities of a User-Defined Function Dennis Snelgrove[_2_] Excel Programming 3 October 18th 05 02:36 PM
User-defined data type; Error: Only User-defined types... tiger_PRM Excel Programming 1 July 18th 04 03:32 PM
User defined data type augustus108 Excel Programming 1 April 10th 04 05:11 PM


All times are GMT +1. The time now is 07:40 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"