Well, whether or not the compiler is flagging the End Function as an error, it is. You need to resolve that issue before considering any of the other errors the compiler is throwing; sometimes, when you have certain issues with the code (like really unusual syntax errors), it can cause the compiler to get confused and it shows errors elsewhere in the code that aren’t accurate.
i did copy from another source. didn’t realized the “function” on code.
but, it’s a bug and i reported a few minutes ago.
thank you all for your, help.
Alex
I pasted your code into a Button Pressed event instead of a method, that is why it behaves different. Just wanted to test quickly.
ChatGPT loves to embed functions like that.
I know that it isn’t Xojo’s responsibility, but it would be cool if those could be identified when pasting in code and have the IDE automatically extract them into helper methods.
Again though, not really their problem.
1 Like
All LLMs do, and in fact it’s the correct way to fully describe a method or function outside of the IDE.
2 Likes