コード例 #1
0
// @pymethod |PyIBackgroundCopyJob|SetDisplayName|Description of SetDisplayName.
PyObject *PyIBackgroundCopyJob::SetDisplayName(PyObject *self, PyObject *args)
{
	IBackgroundCopyJob *pIBCJ = GetI(self);
	if ( pIBCJ == NULL )
		return NULL;
	// @pyparm <o unicode>|Val||Description for Val
	PyObject *obVal;
	LPWSTR Val;
	if ( !PyArg_ParseTuple(args, "O:SetDisplayName", &obVal) )
		return NULL;
	BOOL bPythonIsHappy = TRUE;
	if (!PyWinObject_AsBstr(obVal, &Val))
		return NULL;
	HRESULT hr;
	PY_INTERFACE_PRECALL;
	hr = pIBCJ->SetDisplayName( Val );
	SysFreeString(Val);
	PY_INTERFACE_POSTCALL;
	if ( FAILED(hr) )
		return PyCom_BuildPyException(hr, pIBCJ, IID_IBackgroundCopyJob );
	Py_INCREF(Py_None);
	return Py_None;

}