Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error compiling the Winforms example. #1

Open
Spoiledpay opened this issue Dec 5, 2023 · 3 comments
Open

Error compiling the Winforms example. #1

Spoiledpay opened this issue Dec 5, 2023 · 3 comments

Comments

@Spoiledpay
Copy link

1 - I downloaded the Winform Odin clone to a directory.
Odin1

2 - I entered the command line inside the directory and tried to compile and it was not compiled. Like? odin build app.odin -file

odin2

3 - It didn't generate the executable code as an example, what could you have done wrong, can you help?

@kcvinker
Copy link
Owner

kcvinker commented Dec 12, 2023

Hi, Thanks you for trying the sample code. I think you probably used the old sample code with updated lib.
This is how the new sample code looks. I have changed the menu module a little bit. Please download and try the latest version.
image

There are 3 overloads for a menubar_add_items proc.

  1. menubar_add_items :: proc(this: ^MenuBar, menuTxts: ..string)
  2. menubar_add_items :: proc(this: ^MenuBar, parentIndex: int, menu_txts: ..string)
  3. menubar_add_items :: proc(this: ^MenuBar, parentMenu: ^MenuItem, menu_txts: ..string)

@Spoiledpay
Copy link
Author

Hello!
I'm using the version in the repository, what would be the newer version? Not on GITHUB?

@kcvinker
Copy link
Owner

Can you please check the code in 'menu.odin' ? Check for menubar_add_items proc. It has 3 overloads. Just check the parameters. In my previous reply, I 've added signatures for all the three overloads. Just make sure you are using latest version.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants