mIRC Homepage
Posted By: Ic3flamez c/c++ in mirc? - 05/06/03 04:34 AM
i was copieng my extern "C" code to my mirc editor and i restarted to edit my code and it was tabbed like in my c++ editor. i dunno if it is a real bug or not, but it is wierd, besides the fact mIRC was made in c++
Posted By: codemastr Re: c/c++ in mirc? - 05/06/03 04:36 AM
What?
Posted By: Ic3flamez Re: c/c++ in mirc? - 05/06/03 04:38 AM
look:
here is my code from my c++ editor:
extern "C" int __declspec(dllexport) FAR PASCAL Print(HWND mWnd, HWND aWnd,char* data,char*,BOOL,BOOL) {
PRINTDLG pd; //define the print dialog short command

// Initialize PRINTDLG
ZeroMemory(&pd, sizeof(PRINTDLG));
pd.lStructSize = sizeof(PRINTDLG);
pd.hwndOwner = aWnd;
pd.hDevMode = NULL; // Don't forget to free or store hDevMode.
pd.hDevNames = NULL; // Don't forget to free or store hDevNames.
pd.Flags = PD_USEDEVMODECOPIESANDCOLLATE | PD_RETURNDC;
pd.nCopies = 1;
pd.nFromPage = 0xFFFF;
pd.nToPage = 0xFFFF;
pd.nMinPage = 1;
pd.nMaxPage = 0xFFFF;

if (PrintDlg(&pd)==TRUE) {

// GDI calls to render output.
StartDoc(pd.hDC,pd.);
// Delete DC when done.
DeleteDC(pd.hDC);

}
return 3;
}

here is the code when i place it into mirc's editor:
extern "C" int __declspec(dllexport) FAR PASCAL Print(HWND mWnd, HWND aWnd,char* data,char*,BOOL,BOOL) {
PRINTDLG pd; //define the print dialog short command

// Initialize PRINTDLG
ZeroMemory(&pd, sizeof(PRINTDLG));
pd.lStructSize = sizeof(PRINTDLG);
pd.hwndOwner = aWnd;
pd.hDevMode = NULL; // Don't forget to free or store hDevMode.
pd.hDevNames = NULL; // Don't forget to free or store hDevNames.
pd.Flags = PD_USEDEVMODECOPIESANDCOLLATE | PD_RETURNDC;
pd.nCopies = 1;
pd.nFromPage = 0xFFFF;
pd.nToPage = 0xFFFF;
pd.nMinPage = 1;
pd.nMaxPage = 0xFFFF;

if (PrintDlg(&pd)==TRUE) {

// GDI calls to render output.
StartDoc(pd.hDC,pd.);
// Delete DC when done.
DeleteDC(pd.hDC);

}
return 3;
}
err. guess it dun support tabs... but it was spaced out
By the way:DO NOT STEAD THE CODE
Posted By: KingTomato Re: c/c++ in mirc? - 05/06/03 05:29 AM
you do realize c\c++ code does not work in mirc, correct? If you want to program in C\C++ for mirc, thats what a DLL is for.
Posted By: codemastr Re: c/c++ in mirc? - 05/06/03 05:51 PM
I haven't the slightest clue what your point is. And you don't have to worry about me "steading" your code, (stead - to provide service to).
Posted By: tontito Re: c/c++ in mirc? - 05/06/03 07:35 PM
lol, please try to read mirc.hlp
thanks smile
Posted By: Ic3flamez Re: c/c++ in mirc? - 06/06/03 02:10 AM
when i used /[function name] it said Exter, no such alias
Posted By: codemastr Re: c/c++ in mirc? - 06/06/03 03:59 AM
Question: are you drunk and/or mentally incapacitated by the use of any controlled substance? I'm talking to my dog right now, and she seems to be making more sense to me than what you are saying... "Exter"? No such alias? What are you talking about? It makes no sense whatsoever.
Posted By: KingTomato Re: c/c++ in mirc? - 06/06/03 04:07 AM
i think he's referring tot he dll export "extern" lmao -- trying to call a function written solely in c in mirc.. atleast thats what the "port over into mirc--messed up tabbing" suggests.. LMAO
Posted By: codemastr Re: c/c++ in mirc? - 06/06/03 05:41 AM
Even so, it shouldn't say "no such alias" I've never seen mIRC say that ever. If I type /extern when connected to a server I get:
EXTERN Unknown command
if not connected:
* /extern: not connected to server

Nothing about "no such alias".
© mIRC Discussion Forums