VB_VarUserMemID attribute in VB6 source files

I am looking through some old VB6 code using WordPad (since I don't have VB6). After many variable declarations at the module level, I see a second line that sets some attribute for the variable, as shown in the example below. It appears that attribute number 1073741852 is the same for all ads.

Public testPath as Integer Attribute TestPath.VB_VarUserMemID = 1073741852 

Since I don't have open source in VB6, I'm not sure if attribute lines are visible in VB6 ide.

Does anyone know the value of this attribute?

+4
source share
2 answers

I looked at this page , which has the text of the base module based on VB.

And it seems the attribute should support the declaration order (?).
From the name, it looks like a member id for a variable.

Attribute lines will not be visible in VB6.

Some attributes applicable to properties / methods can be set using the "Procedure Attributes" dialog in VB6 (for example, make this property the default, hide objects in the browser, etc.).

+1
source

I was looking for a VB6 newsgroup . VB stores the attributes of procedures and public variables in strings that are not shown in the VB6 IDE. You view and edit these parameters in the VB6 IDE using the Tool Attributes dialog box - even though it also applies to public variables.

The x.VB_VarUserMemId attribute represents the procedure identifier assigned to the Property / method. Values ​​can make a difference in COM. For instance. 0 means the default property .

+1
source

Source: https://habr.com/ru/post/1285990/


All Articles