Defined Enum's used in Function Calls don't seem to work anymore. Has something changed?

Mackeral

Board Regular
Joined
Mar 7, 2015
Messages
174
This an example of an Enum definition
VBA Code:
Enum XXX
    X1 = 1
    X2 = 2
End Enum

I will define a function I will call "Test
VBA Code:
Function Test(Arg as XXX)
   ' Some Code
End Function

When I type in
VBA Code:
Call Test(
all I see is
VBA Code:
Test:Display as XXX)
and no drop-down list appears where I use to see a Dropdown list where I could select either "X1" and "X2".

If you use a VBA non-Enum term like "Boolean" as in "Call Test(Arg as Boolean)", you see
a Dropdown list showing"True" and "False".

Any idea what I have done wrong, or has something changed in VBA?
 

Attachments

  • 210613 Drop Down.jpg
    210613 Drop Down.jpg
    10.2 KB · Views: 1

Excel Facts

Copy PDF to Excel
Select data in PDF. Paste to Microsoft Word. Copy from Word and paste to Excel.

footoo

Well-known Member
Joined
Sep 21, 2016
Messages
3,323
Office Version
  1. 2016
Platform
  1. Windows
Instead of :
VBA Code:
Call Test(
Try :
VBA Code:
Call Test(xxx
 

Mackeral

Board Regular
Joined
Mar 7, 2015
Messages
174
I don’t understand how this is not monitored. I am a “Board Regular” and have been for years.

Could you please explain.

Thanks,

Mackeral
 

Mackeral

Board Regular
Joined
Mar 7, 2015
Messages
174
After much energy trying to figure this out, I find that if I start a new workbook, everything works fine. However when I try to do the same thing in the original workbook it doesn't.

So if something looks impossible, try testing it in a new workbook.
 
Last edited:
Solution

Forum statistics

Threads
1,147,518
Messages
5,741,636
Members
423,674
Latest member
Charles2dodo

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top