|
bad habit to ask so...
generally, it already takes about 5 to 10 minutes to make a good answer, regarding the difficulty of the subject, and moreover, if you feel hurry, you may not ask your question on a forum, especially when it is your first (ok, 2nd with this one) post on the site...
TOXCCT >>> GEII power [toxcct][VisualCalc]
-- modified at 11:37 Wednesday 16th November, 2005
|
|
|
|
|
Sir,In dialog-based application in VC++(MFC),i have one dialog with a button called "Failure conditions".If i click it i will get another dialog box with check-box as control.If i check the option in dialog-box2 & uncheck it the message transmission in dialog-box1 should be stopped.How can i do it & can u
give me tips about the code please?
V.Natarajan
|
|
|
|
|
you have to make into you dialogBox2 a reference to the parent dialog... this way, you can interract with it.
to get the check event on your checkbox, just overload the event with the resource editor wizzard...
and please please, be patient at least 10min until instead of asking for a quick answer ! peaople are not obliged to answer, they do it as a pleasure, nothing more
TOXCCT >>> GEII power [toxcct][VisualCalc]
|
|
|
|
|
Hello All
I have developed an application to convert .WAV files to .MP3 using DirectX 9.0 SDK in VC++ on Visual Studio .NET 2003. My target systems are Windows 2000 and Windows XP. Can any one tell me what all the DLLs and other files (codecs) needs to be shipped along with the application?
Unfortunately we have installed DirectX 9.0 SDK in all our PCs and could not identify the dependency files to be shipped.
Thanks for your time
Ravi
|
|
|
|
|
If your app depends on DX9 then install the redist of DX9 with your install.
|
|
|
|
|
Hi,
Check the redist or MsiRedist folder. It contain the redistributables. Also read the redist.txt to find exactly which file to be redistributed.
Bye
Cool Ju
Vote for Cool Ju
|
|
|
|
|
I'm creating a stream object stored in global memory.
GetImage() function
IStream *pStream;
::CreateStreamOnHGlobal(NULL,TRUE,&pStream);
image->Save(pStream,&encoderClsid,&encoderParameters);
..// bit operations no memory allocations just math calcuations
//then
delete image;
pStream->Release();
the problem i have when application is run ,and begin executing the GetImage Function, the memory is keep increase after each call and nothing is freed, what should i do to free memory after each call the two statements :
delete image;
pStream->Release(); as they have to effects
I also tried to use GlobalFree(pStream), and GlobalFree(&pStream) with no avail. memory keep rasing after each call
|
|
|
|
|
raed wrote: I also tried to use GlobalFree(pStream), and GlobalFree(&pStream) with no avail. memory keep rasing after each call
You will need to call GetHGlobalFromStream(...) to get the correct handle to pass to the GlobalFree function.
However, the way you created the stream object, it should clean itself up...?
Peace!
-=- James If you think it costs a lot to do it right, just wait until you find out how much it costs to do it wrong! Tip for new SUV drivers: Professional Driver on Closed Course does not mean your Dumb Ass on a Public Road! DeleteFXPFiles & CheckFavorites (Please rate this post!)
|
|
|
|
|
Hello dear friends,
I've a problem in showing video captured from webcam
First I wanted to learn to do this by using the CAvicap, but it didn't work and I couldn't find anybody who can tell me what I did wrong.
So I was a bit desperate and searched another method and that was using the DirectShow of DirectX SDK. Well, I've still not coded, because I want to know how Directx and COM work.
But the main problem is still that I don't know how to display the video from the webcam on the screen.
The part to show the video using webcam with the Avicap class is here:
<br />
void CCamSampDlg::OnStart()
{
CRect rectangular;<br />
GetClientRect(&rectangular);<br />
<br />
<br />
WebCam.Create(WS_CHILD|WS_VISIBLE,rectangular,this,TRUE);<br />
WebCam.ConnectWithDriver(-1);<br />
WebCam.SetPreviewRate(15);<br />
WebCam.StartPreview(TRUE);<br />
<br />
}<br />
The only thing wat happens when I execute, is the Led blinking of my webcam, wich means that there is some activity going on. But I see not a window opening to show the captured video.
So I hope you smart guys can help this dumb boy, so I can give my wife more attention :->
If you want the whole project, I can send it to you by email
If my application works, I forget all my problems.
|
|
|
|
|
I have created a dll in vc7 and called by a c# form using dllimport. But this dll seems can't be load symbol when I try to debug. So I can't trace into the cpp code. Even I set dll project as start project and set the c# application as debug command.
Is there a solution to this situation?
|
|
|
|
|
I want to hook an application and want to get all windows messages of all the child windows of it. What kind of hook mechanism must be used? isn't it enough to hook only the main frame of the application, I think in that case I cannot get the windows messages sent from the child windows.
Thanks.
Elif Erkul
|
|
|
|
|
Have a look at the MSDN docs for SetWindowsHookEx(...) .
Peace!
-=- James If you think it costs a lot to do it right, just wait until you find out how much it costs to do it wrong! Tip for new SUV drivers: Professional Driver on Closed Course does not mean your Dumb Ass on a Public Road! DeleteFXPFiles & CheckFavorites (Please rate this post!)
|
|
|
|
|
well, actually I had some way with that.
when I find the main window and hook it with WH_CALLWNDPROC type of hook, I can only cath that main window's
window messages.
I want to hook an application and catch all the user input (mouse, keyboard, etc) about it. I want to know which button click, what data is entered, etc.
with what kind of hook mechanism can I get all the messages from all the windows of the applicaion?
Is it possible to hook only that application (I don't want to use a system-wide hook) and track all the user input
to the windows and dialogs of that applicaiton?
please answer.
Thank you.
Elif (Erkul) Ceylan
|
|
|
|
|
Please give me any tips of how to do that? Thanks in advance
NastradamuS
|
|
|
|
|
and what is a transporter agent supposed to be please ?
TOXCCT >>> GEII power [toxcct][VisualCalc]
|
|
|
|
|
Hi,
I have a problem with window painting...
The parent window has the layered property and it has some transparency settings also. The program use multiple desktops. This window is in the default desktop.
From another desktop I invoke some dialogs(which are completely ownerdrawn). These dialogs contains some special control(like ownerdrawn buttons, text display control derived from CWnd for showing some text, etc).
Problem is the dialog comes in the default desktop with out painting... a black window... sometimes. But when I click in it it will paint itself. Same is to the button.
When I remove the Layered Attributes settings, there is no problem.
Are there any special things to do to child dialogs if Layered Attributes settings are used?
Expecting valuable replays...
Thank you.
- NS -
|
|
|
|
|
have you tried InvalidateRect(), RedrawWindow(), something like that?
My articles
BlackDice
|
|
|
|
|
|
I need help making the menu and the title bar be written in a some other font, then it is by default.
NastradamuS
-- modified at 6:53 Wednesday 16th November, 2005
|
|
|
|
|
|
how to use:
SetFolderImageList(const int folder, CImageList * pImageList, int nImageList)?
how to set multi-outlookbar folder image?
|
|
|
|
|
I have code like this
<br />
fun1(){<br />
CEdit* pEdit=new CEdit;<br />
pEdit->Create(...);<br />
}<br />
fun2(){<br />
CEdit* pEdit=new CEdit;<br />
}<br />
fun3(){<br />
pEdit->SetWindowText("Bla Bla");<br />
}<br />
But I have problems in fun3() because sometimes the pEdit object isn't created.
What function I could use, to test pEdit, in fun2 to know if the object is created or not?
Thanks
|
|
|
|
|
( I assume that what you wrote in your question is what you have in your real code )
Well, you should go back to to your C++ books ...
in fun1 you create a local variable pEdit which will leak memory when the function ends; same thing in fun2
in fun3 you access a variable that is not allocated yet, so it will crash.
NOW, assuming that what you wrote is not actually your real code and that you pass pEdit as a parameeter to fun3 , check to see if pEdit is NULL before trying to access it :
fun3( CEdit* pEdit )
{
if ( pEdit )
pEdit->SetWindowText("...");
}
If when calling fun3 your not certain that pEdit is Create ed, you can check with CWnd::GetSafeHwnd ( or something similar ).
Maximilien Lincourt
Your Head A Splode - Strong Bad
|
|
|
|
|
SORRY.
Of course, the sintax wasn't correct.
This probally is better.
<br />
CEdit* pEdit=NULL;<br />
InitType1(){<br />
pEdit=new CEdit;<br />
pEdit->Create(...);<br />
}<br />
InitType2(){<br />
pEdit=new CEdit;<br />
}<br />
DoSomething(){<br />
pEdit->SetWindowText("Bla Bla");<br />
}<br />
Now.
if(pEdit) pEdit->SetWindowText("Bla Bla");
doesn't work because we could think that pEdit is always !=NULL.
if(pEdit->GetSafeHwnd()!=NULL) pEdit->SetWindowText("Bla Bla");
Looks interesting, and I think that could work.
So, Thank you
-- modified at 7:50 Wednesday 16th November, 2005
|
|
|
|
|
Matteo_78 wrote: if(pEdit) pEdit->SetWindowText("Bla Bla");
doesn't work because we could think that pEdit is always !=NULL.
Well, we would not... and checking the pointer validity is always a good thing, either with ASSERT or by if
...
BTW, why do you new pEdit twice ? is pEdit a class member variable ? in DoSomething , which pEdit are you referencing ? the one allocated in InitType1 or in InitType2 ?
Maximilien Lincourt
Your Head A Splode - Strong Bad
|
|
|
|