Click here to Skip to main content
15,891,951 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hello friends,
I am new in VC++ area and I got class not registered exception from the
C++
AVIFileOpen()
function.
C++
HRESULT CAviExtract::OpenAviFile(CString szFile)
{	
    int nNumAudioStreams = 0;
    try
    {
	hr = AVIFileOpen(&m_pAviFile, szFile,  OF_READWRITE, NULL);
	if(hr != S_OK)//Got Class not registered exception here.
	     return hr;

	hr = AVIFileInfo(m_pAviFile, &m_pAviFileInfo, sizeof(m_pAviFileInfo));
	if(hr != S_OK)
             return hr;		
	
	hr = AVIFileGetStream(m_pAviFile, &m_pAVIVideoStream, streamtypeVIDEO, 0);
	if(hr == AVIERR_NODATA || hr == AVIERR_MEMORY)
	     return hr;
	
	hr = AVIStreamInfo(m_pAVIVideoStream, &m_pStreamInfo, sizeof(m_pStreamInfo));
	if(hr != S_OK)
	     return hr;		
        }
	catch(...)
	{

	}
	return hr;
}


Please help me to resolve it. I am not using any COM regarding functionality and using Windows XP 32 bit with VS2005.
Posted

1 solution

Documentation[^] says it all:
According to the registry, the type of file specified in AVIFileOpen does not have a handler to process it.


Roughly: your system cannot provide you an interface able to play files of that type.
 
Share this answer
 
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900