Click here to Skip to main content
15,914,074 members
Home / Discussions / C#
   

C#

 
GeneralRe: c++ and c# issue Pin
dany_ch7-Sep-07 5:30
dany_ch7-Sep-07 5:30 
GeneralRe: c++ and c# issue Pin
led mike7-Sep-07 5:55
led mike7-Sep-07 5:55 
QuestionLayout Transform v/s Render Transform Pin
KrunalC7-Sep-07 5:02
KrunalC7-Sep-07 5:02 
QuestionCheckboxes? Pin
XFighter7-Sep-07 4:43
XFighter7-Sep-07 4:43 
AnswerRe: Checkboxes? Pin
Thomas Stockwell7-Sep-07 5:13
professionalThomas Stockwell7-Sep-07 5:13 
Questionpinvoke error and struct Pin
Saamir7-Sep-07 3:34
Saamir7-Sep-07 3:34 
AnswerRe: pinvoke error and struct Pin
Giorgi Dalakishvili7-Sep-07 3:54
mentorGiorgi Dalakishvili7-Sep-07 3:54 
GeneralRe: pinvoke error and struct Pin
Saamir7-Sep-07 4:14
Saamir7-Sep-07 4:14 
Thank you Giorgi, Here is C++ dll code that I am trying to call.

typedef struct {
LPTSTR lpsRaw;
LPTSTR lpsTransit;
LPTSTR lpsAccount;
LPTSTR lpsCSN;
LPTSTR lpsAmount;
} LPMICR;

LPMICR (CALLBACK* GetParseData) ();
int (CALLBACK* ParseMICR) (LPTSTR lpStr);

Here is my C# code:

public struct pMICR
{
public StringBuilder Raw;
public StringBuilder Transit;
public StringBuilder Account;
public StringBuilder CSN;
public StringBuilder Amount;
}

[DllImport("c:\\Parser.dll")]
public static extern int ParseMICR(string Micr);
[DllImport("c:\\Parser.dll")]
public static extern pMICR GetParseData();

I am getting the following error: Method's type signature is not pinvoke compatible. This happens when I call getparse data function. Parsemicr function completes just fine.

Please advice.



sasa

GeneralRe: pinvoke error and struct Pin
Luc Pattyn7-Sep-07 5:30
sitebuilderLuc Pattyn7-Sep-07 5:30 
GeneralRe: pinvoke error and struct Pin
Saamir7-Sep-07 9:17
Saamir7-Sep-07 9:17 
GeneralRe: pinvoke error and struct Pin
Luc Pattyn7-Sep-07 9:48
sitebuilderLuc Pattyn7-Sep-07 9:48 
AnswerRe: pinvoke error and struct Pin
edu.net7-Sep-07 8:43
edu.net7-Sep-07 8:43 
GeneralRe: pinvoke error and struct Pin
Saamir7-Sep-07 9:12
Saamir7-Sep-07 9:12 
QuestionSyncfusion menubar and logo Pin
Keshav V. Kamat7-Sep-07 3:06
Keshav V. Kamat7-Sep-07 3:06 
AnswerRe: Syncfusion menubar and logo Pin
Larantz7-Sep-07 3:26
Larantz7-Sep-07 3:26 
QuestionC++ dll, again.. Pin
Dio227-Sep-07 2:56
Dio227-Sep-07 2:56 
AnswerRe: C++ dll, again.. Pin
Giorgi Dalakishvili7-Sep-07 2:59
mentorGiorgi Dalakishvili7-Sep-07 2:59 
GeneralRe: C++ dll, again.. Pin
Dio227-Sep-07 3:13
Dio227-Sep-07 3:13 
QuestionI read about this here Pin
XFighter7-Sep-07 2:53
XFighter7-Sep-07 2:53 
AnswerRe: I read about this here Pin
Giorgi Dalakishvili7-Sep-07 2:56
mentorGiorgi Dalakishvili7-Sep-07 2:56 
AnswerRe: I read about this here Pin
led mike7-Sep-07 4:36
led mike7-Sep-07 4:36 
QuestionHow to get a MenuItem's name in runtime Pin
c0rvus7-Sep-07 2:34
c0rvus7-Sep-07 2:34 
AnswerRe: How to get a MenuItem's name in runtime Pin
Giorgi Dalakishvili7-Sep-07 2:50
mentorGiorgi Dalakishvili7-Sep-07 2:50 
GeneralRe: How to get a MenuItem's name in runtime Pin
c0rvus7-Sep-07 3:28
c0rvus7-Sep-07 3:28 
AnswerRe: How to get a MenuItem's name in runtime Pin
Scott Dorman7-Sep-07 3:22
professionalScott Dorman7-Sep-07 3:22 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.