Thanks for the reply. I did check out before calling the Post method.
IVersionedEntityPtr versionEntity = new_req->GetInt();
IVersionControlPtr req_vc = versionEntity->GetVC();
req_vc->CheckOut( _bstr_t(L"Checkout Requirement"));
......
new_req->Post();
......
req_vc->CheckIn( _bstr_t(L"CheckIn Requirement"));
It could be the CheckOut function is failed (QC doesn't provide method GetIsCheckedOut() function for requirements), but what could cause it to fail? User permission setting? How to set it in QC 11 server then?
Thanks a lot.