16,004,806 members
Sign in
Sign in
Email
Password
Forgot your password?
Sign in with
home
articles
Browse Topics
>
Latest Articles
Top Articles
Posting/Update Guidelines
Article Help Forum
Submit an article or tip
Import GitHub Project
Import your Blog
quick answers
Q&A
Ask a Question
View Unanswered Questions
View All Questions
View C# questions
View C++ questions
View Javascript questions
View Visual Basic questions
View .NET questions
discussions
forums
CodeProject.AI Server
All Message Boards...
Application Lifecycle
>
Running a Business
Sales / Marketing
Collaboration / Beta Testing
Work Issues
Design and Architecture
Artificial Intelligence
ASP.NET
JavaScript
Internet of Things
C / C++ / MFC
>
ATL / WTL / STL
Managed C++/CLI
C#
Free Tools
Objective-C and Swift
Database
Hardware & Devices
>
System Admin
Hosting and Servers
Java
Linux Programming
Python
.NET (Core and Framework)
Android
iOS
Mobile
WPF
Visual Basic
Web Development
Site Bugs / Suggestions
Spam and Abuse Watch
features
features
Competitions
News
The Insider Newsletter
The Daily Build Newsletter
Newsletter archive
Surveys
CodeProject Stuff
community
lounge
Who's Who
Most Valuable Professionals
The Lounge
The CodeProject Blog
Where I Am: Member Photos
The Insider News
The Weird & The Wonderful
help
?
What is 'CodeProject'?
General FAQ
Ask a Question
Bugs and Suggestions
Article Help Forum
About Us
Search within:
Articles
Quick Answers
Messages
Comments by ms0482828 (Top 3 by date)
ms0482828
3-Jun-21 9:15am
View
Understand, thank you very much :D
I think there is only this way, the error message makes me tired
ms0482828
2-Jun-21 22:50pm
View
Thanks for your help, KarstenK. I have put the data in the same folder, and create an empty project to test. I think there is no have mixed x86 and x64 files in the empty project. But the Error still exists.
ms0482828
2-Jun-21 22:42pm
View
Thanks for your help, Richard McCutchan. But the project still doesn't work
I have tried to change the path and use Marshal.StringToBSTR(String) Method like this:
[DllImport("D:\\image_16bit_code\\MoveFullImageByFirstImage.dll", CallingConvention = CallingConvention.Cdecl)]
public static extern IntPtr Open16BitGrayImage(IntPtr imgFile);
string imgUrl = "Image_Mapping/MRI-PDI_Axial-Z/MRI-PDI_Axial-Z_0110.png";
IntPtr BSTR_imgUrlt = Marshal.StringToBSTR(imgUrl);
Am I using it incorrectly? Error still exists.
char * whether the return should not be used IntPtr?