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

IL2CPP does not support marshaling delegates that point to instance methods to native code #139

Open
Graylington opened this issue Apr 1, 2024 · 3 comments

Comments

@Graylington
Copy link

Graylington commented Apr 1, 2024

After converting my Unity project to IL2CPP, I receive the following error when trying to load a file

NotSupportedException: IL2CPP does not support marshaling delegates that point to instance methods to native code. The method we're attempting to marshal is: System.Windows.Forms.CommonDialog::OwnerWndProc at System.Windows.Forms.CommonDialog.ShowDialog (System.Windows.Forms.IWin32Window owner) [0x00000] in <00000000000000000000000000000000>:0 at SFB.StandaloneFileBrowserWindows.OpenFilePanel (System.String HOMKPMAEFCI, System.String DKDBCAEHMJI, SFB.ExtensionFilter[] FDMFDONNFPK, System.Boolean BGHPAMDHIGC) [0x00000] in <00000000000000000000000000000000>:0 at SFB.StandaloneFileBrowser.OpenFilePanel (System.String HOMKPMAEFCI, System.String DKDBCAEHMJI, SFB.ExtensionFilter[] FDMFDONNFPK, System.Boolean BGHPAMDHIGC) [0x00000] in <00000000000000000000000000000000>:0

@Graylington Graylington changed the title After converting my Unity project to IL2CPP, I receive the following error when trying to load a file IL2CPP does not support marshaling delegates that point to instance methods to native code Apr 1, 2024
@SinForLove
Copy link

same issue

@mountainlord
Copy link

Has anyone fixed this?

@DustinMerrell
Copy link

Has anyone made changes for this to static so that it will work?

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

4 participants