MLUCS2ErrorMessage (C 函数)
MLUCS2ErrorMessage 已经被 WSUCS2ErrorMessage 所取代.
const unsigned short * MLUCS2ErrorMessage(MLINK l, int *n)
returns a characters string encoded in UCS2 encoding form of length n describing the last error to occur on the MathLink connection specified by l.
更多信息
- MLUCS2ErrorMessage() allocates memory that must be released by calling MLReleaseUCS2ErrorMessage().
- MLUCS2ErrorMessage() is declared in the MathLink header file mathlink.h.
范例
基本范例 (1)
#include "mathlink.h"
/* A function for reading the error message from a link */
void f(MLINK l)
{
const unsigned short *message;
int length;
message = MLUCS2ErrorMessage(l, &length);
if(message == (const unsigned short *)0 || length == 0)
{ /* Unable to get the error message from the link */ }
/* ... */
MLReleaseUCS2ErrorMessage(l, message, length);
}