Click here to Skip to main content
15,881,812 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: the needed DLL's Pin
PasNad11-Nov-06 1:37
PasNad11-Nov-06 1:37 
AnswerRe: the needed DLL's Pin
Michael Dunn11-Nov-06 1:46
sitebuilderMichael Dunn11-Nov-06 1:46 
GeneralRe: the needed DLL's Pin
PasNad11-Nov-06 2:38
PasNad11-Nov-06 2:38 
QuestionQuery about MCI(Media Control Interface) Pin
Raja Bose C Leo10-Nov-06 21:43
Raja Bose C Leo10-Nov-06 21:43 
AnswerRe: Query about MCI(Media Control Interface) Pin
Hamid_RT11-Nov-06 0:22
Hamid_RT11-Nov-06 0:22 
GeneralRe: Query about MCI(Media Control Interface) Pin
Raja Bose C Leo12-Nov-06 21:13
Raja Bose C Leo12-Nov-06 21:13 
GeneralRe: Query about MCI(Media Control Interface) Pin
Hamid_RT13-Nov-06 7:17
Hamid_RT13-Nov-06 7:17 
GeneralRe: Query about MCI(Media Control Interface) Pin
Raja Bose C Leo14-Nov-06 2:14
Raja Bose C Leo14-Nov-06 2:14 
Thank you one again for replying

hmmm Its giving the same error message (The error message is "The Specified file cannot be played in the specified MCI device. The file may be corrupt, not in correct format or no file name")... I found out one thing that your code had suceeded without error by checking the return value(as given below) ... and also I created a registry value( in regedit) for MPEGVIDEO2 in MCI32 key folder and set the value as MCIQTZ32.DLL is that OK??? .... for MPEGVIDEO I have the key already(so mpeg 1 is playing fine with MCIFMP32.DLL in registry) but for the MPEGVIDEO2 I created new one .... If I didnt create this key, your code returns some error message as their is no DLL linked with MPEGVIDEO2 Devicetype

I had included your code in my btnPlay() function in the main dialog is that OK ???

The code snippet for the button play is as follows

void CSeamlessPlayerDlg::OnBtnPlay()
{
if(index == m_PlyLst.GetItemCount())
index=0;
char lpszErr[256];
CString SPath=m_PlyLst.GetItemText(index,2);
char lpPath[256];
strcpy(lpPath, SPath);
///////////////////////////////////////////////////////////////////////////////////
MCI_DGV_OPEN_PARMS mciOpen;
mciOpen.dwCallback = 0L;
mciOpen.wDeviceID = 0;
mciOpen.dwStyle = WS_CHILD;
mciOpen.hWndParent = m_hWnd;
mciOpen.lpstrElementName = lpPath ;
mciOpen.lpstrDeviceType ="MPEGVIDEO2";
mciOpen.lpstrAlias ="MPEGVIDEO2";

MCIERROR err = mciSendCommand( 0,MCI_OPEN, (DWORD)(MCI_OPEN_ELEMENT|MCI_OPEN_TYPE
|MCI_DGV_OPEN_PARENT|MCI_DGV_OPEN_WS),(DWORD)(LPVOID)&mciOpen);

if(err != 0)
{
mciGetErrorString(err, lpszErr,256);
MessageBox(lpszErr); // display error if failed
}

////////////////////////////////////////////////////////////////////////////////////
if(m_PlyLst.GetItemCount() != 0)
{
// mci.Stop();
mci.SetPath(SPath);
mci.SetParent(m_video.GetSafeHwnd());
mci.Initialize();


// mci.SetParent(m_video.GetSafeHwnd());

// if(i==m_PlyLst.GetItemCount())
// mci.Initialize();

::ShowWindow(mci.GetWindowHandle(),SW_MAXIMIZE);

mci.Play();
SetTimer(1,1000,NULL);
}
else
{
MessageBox("Check your Play List");
}
}

Thank you,

Awaiting for your replySmile | :)

With regards

Raja Bose

GeneralRe: Query about MCI(Media Control Interface) Pin
Hamid_RT14-Nov-06 8:32
Hamid_RT14-Nov-06 8:32 
GeneralRe: Query about MCI(Media Control Interface) Pin
Raja Bose C Leo14-Nov-06 18:35
Raja Bose C Leo14-Nov-06 18:35 
GeneralRe: Query about MCI(Media Control Interface) Pin
Hamid_RT14-Nov-06 20:15
Hamid_RT14-Nov-06 20:15 
Questione.Problem Pin
amaneet10-Nov-06 21:40
amaneet10-Nov-06 21:40 
AnswerRe: e.Problem Pin
Hamid_RT11-Nov-06 0:23
Hamid_RT11-Nov-06 0:23 
AnswerRe: e.Problem Pin
toxcct11-Nov-06 1:02
toxcct11-Nov-06 1:02 
QuestionHow I can add jpg images in list box? [modified] Pin
Sameer_Thakur10-Nov-06 21:11
Sameer_Thakur10-Nov-06 21:11 
AnswerRe: How I can add jpg images in list box? Pin
Hamid_RT11-Nov-06 0:24
Hamid_RT11-Nov-06 0:24 
GeneralRe: How I can add jpg images in list box? Pin
Sameer_Thakur11-Nov-06 1:54
Sameer_Thakur11-Nov-06 1:54 
GeneralRe: How I can add jpg images in list box? Pin
Mark Salsbery11-Nov-06 5:04
Mark Salsbery11-Nov-06 5:04 
GeneralRe: How I can add jpg images in list box? Pin
Hamid_RT11-Nov-06 23:07
Hamid_RT11-Nov-06 23:07 
Questionprefix increment Pin
amaneet10-Nov-06 20:45
amaneet10-Nov-06 20:45 
AnswerRe: prefix increment Pin
Mohammad A Gdeisat10-Nov-06 23:36
Mohammad A Gdeisat10-Nov-06 23:36 
GeneralRe: prefix increment Pin
CPallini13-Nov-06 6:26
mveCPallini13-Nov-06 6:26 
GeneralRe: prefix increment Pin
Mohammad A Gdeisat13-Nov-06 7:34
Mohammad A Gdeisat13-Nov-06 7:34 
AnswerRe: prefix increment Pin
toxcct11-Nov-06 1:06
toxcct11-Nov-06 1:06 
QuestionLocking Winsock from sending windows message Pin
Toubou10-Nov-06 20:17
Toubou10-Nov-06 20:17 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.