Opened 13 years ago
Closed 13 years ago
#2444 closed Bug (No Bug)
GUICtrlCreateMenuItem -- should the 2nd param be a default?
| Reported by: | Owned by: | guinness | |
|---|---|---|---|
| Milestone: | Component: | AutoIt | |
| Version: | 3.3.9.20 | Severity: | None |
| Keywords: | Cc: |
Description
The helpfile says this:
GUICtrlCreateMenuItem ( "text", menuID = -1 [, menuentry = -1 [, menuradioitem = 0]] )
It seems like menuID should be a default parameter.
Attachments (0)
Change History (8)
comment:1 by , 13 years ago
| Milestone: | → 3.3.9.21 |
|---|---|
| Owner: | set to |
| Resolution: | → Completed |
| Status: | new → closed |
comment:2 by , 13 years ago
you talk about this:
GUICtrlCreateMenuItem ( "text" [, menuID = -1 [, menuentry = -1 [, menuradioitem = 0]]] )
If the answer is yes
then I wait too long -- it was on my list.
comment:3 by , 13 years ago
| Resolution: | Completed |
|---|---|
| Status: | closed → reopened |
Changing the doc is not enough. AutoIt code want really 2 parameters.
What is the menuID you expect to use by default?
I reopen the ticket as doc change is not enough
comment:5 by , 13 years ago
It was a mistake from the previous commit 7893. The "default" parameter should have never been added.
comment:6 by , 13 years ago
Yes Mlipok that is what I mean and I meant make it a default in both the au source and doc.
Jpm, I guess it should stay -1 but it should be such that it can be written like this:
GUICtrlCreateMenuItem("MyMenuItemText")
comment:7 by , 13 years ago
But of course I now see the reason why it isn't a default parameter.
GuiCtrlCreateMenu("MyMenu")
GuiCtrlCreateMenuItem("MyMenuItem1")
GuiCtrlCreateMenuItem("MyMenuItem2") ; now -1 refers not to the menu but the 1st menu item.
GuiCtrlCreateMenuItem("MyMenuItem3") ; now -1 refers not to the menu but the 2nd menu item.
Sorry for wasting time.

Removed by revision [8970] in version: 3.3.9.21