Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: COM VC
Hello friends,
I am new in VC++ area and I got class not registered exception from the
AVIFileOpen()
function.
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 2-Jan-13 3:45am

1 solution

Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

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.
  Permalink  
v2

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



Advertise | Privacy | Mobile
Web01 | 2.8.1411022.1 | Last Updated 2 Jan 2013
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100