VC++托管代码封装C#类库,调用windows api 函数SendMessage出错
我用托管的C++类库封装的C#类库,想发送一个消息到Form上,以下是我调用的代码,但是一直编译不过,提示SendMessage对重载的函数调用不正确,请各位帮忙看一下,谢谢!
void CInputForm::ShowInputWindow(Message msg)
{
InputForm ^ inputform = GetImpObj(m_pinputform);
inputform->Show();
if (inputform->IsHandleCreated)
{
SendMessage((HWND)inputform->Handle.ToPointer(), msg.Msg, (WPARAM)0, (LPARAM)0);
}
}