|
hi all !
when i compile the "programing windows" example.it is no problem but link it , then it appear such error:
"LINK : fatal error LNK1104: cannot open file "Debug/IconDemo.exe"
and all example are like this . why ??
just for free
|
|
|
|
|
hard to say what is your reason, there could be many:
f.e. read only file (by copy from cd) or program is actualy running
what do you can do with that file using any file manager?
t!
|
|
|
|
|
You are running or debugging the exe
|
|
|
|
|
Hi
I want to get the subitem rect by doing this:
GetSubItemRect(nItem, nSubItem, LVIR_BOUNDS, rect);
This works on VC6, but not on VC5.
Does anyone know how to achieve the same by sendinging message ('LVM_GETSUBITEMRECT')? I tried alot, but didn't work.
Greetings
Jens
|
|
|
|
|
I have Visual Studio 6 with SP5. Everything was working fine, till in order to solve some debug release problems I made a lot of project setting changes (the main project includes some 9 other projects) and checked in the .dsp and .dsw files into CVS for the benefit of others.
What is happening is that everytime I (or someone else) tries to open the project in VC, it takes an inordinately long time (about 5 mins) during which the CPU usage jumps up to 100%.
Whats happening? Any ideas... I can furnish the project files if required.
Life is a b****, so f*** it in the arse
|
|
|
|
|
Hello, can anyone point me to an article or a website that discusses all pitfalls associated with floating point calculations, rounding errors and such? I was reading a book on math for geometric computing yesterday and it said 'the pitfalls when using floating point calculations are well known...' without explaining those pitfalls further; now I know about some problems but I'd like to make sure that I know about all cases, even the obscure ones... Thanks.
|
|
|
|
|
Hi,
recently I did setup a project/workspace for working with Visual C++ IDE. All runs fine and I can edit and start my application, but the build script makes troubles: When I call the build line from IDE all I get is somthing like this:
Building...
Error executing c:\windows\system32\cmd.exe.
There should be much more text displayed, and the build line (calling my Python script) runs perfect when I call it manually at command line.
So I played around and did place the build line into a batch-file. Same result when called from VC6 (yes, it works well when I call the batch-file manually).
Anyone has an idea what's going wrong? Is it a Python problem?
Thanks,
Moak
|
|
|
|
|
Well, it seams to be a Python problem. If you explicitely call python as interpreter it works in any combination (called from VC or manually at command line)
working:
python C:\Development\buildmystuff.py -debug
<br>
NOT working with VC:
C:\Development\buildmystuff.py -debug
Strange, I never mentioned a problem with Perl. However it works.
Moak
|
|
|
|
|
Ok, I know this is really a back to basics question, but I would really appreciate some help.
I am developing a MFC application (mainly to teach myself the whole thing) and I am trying to show a modal dialog box when I click a toolbar button. (SDI program). I get response when I click the button, but the dialog show various errors when I try diffrent approaches I found in source codes on the net. Sometimes it hangs, sometimes it just doesn't show up, but hangs the rest of the app (because it's modal, yes I know). I haven't gotten to the point where I can actually interact with the dialog, as in pushing the command buttons, writing in the edit boxes and such.
The dialog box is a dialog resource template with it's own class CDataEditor, derived from CDialog. In my code, I am mostly trying DoModal() but as you understand, it's not going very well.
Hope you can get me out of this....
|
|
|
|
|
OldViking wrote:
Hope you can get me out of this....
How? You did not show what you were doing when your call to DoModal() gave errors.
My opinions may have changed, but not the fact that I am right.
|
|
|
|
|
Hmm... My bad. Just forgot about it.
void CMainFrame::OnDataedit()
{
// Displays the data Edior dialog box
CDataEditor * dlg;
dlg = new CDataEditor;
dlg->DoModal();
}
|
|
|
|
|
Looks OK. What errors do you get?
Can you call your class on the stack instead of on the heap?
My opinions may have changed, but not the fact that I am right.
|
|
|
|
|
I don't get any errors. That's the thing. When I click the toolbar button, the whole programs hangs and I have to end it with ctrl-alt-del.
I tried to use Create( IDD_TEMPLATEID, NULL) instead of DoModal(). The only thing I accomplished was being able to shut down the program in a normal way. The only thing that showed up was the cancel button in the dialog, somehow.
For your second question...remember that I'm a newbie. I don't understand what that means
------------------------------
The great successful men of the world have used their imagination...they think ahead and create their mental picture in all its details, filling in here, adding a little there, altering this a bit and that a bit, but steadily building-steadily buildings. (Robert Collier)
|
|
|
|
|
Answer to second question:
void CMainFrame::OnDataedit()
{
CDataEditor dlg;
dlg.DoModal();
}
For the first question - IDD_TEMPLATEID is a valid resource (one that is actually visible with the resource editor)?
My opinions may have changed, but not the fact that I am right.
|
|
|
|
|
Well, for the code you gave me... It showed the dialog in a split second, before it disappeared again, and the whole program freezed once again.
The IDD_TEMPLATEID is a valid resource, yes. I double-checked the properties and it's set to visible and disabled is NOT checked. It has the child-style set.
I'm using VC++ 6.0 if that has anything to say.
------------------------------
The great successful men of the world have used their imagination...they think ahead and create their mental picture in all its details, filling in here, adding a little there, altering this a bit and that a bit, but steadily building-steadily buildings. (Robert Collier)
|
|
|
|
|
Do you have any odd code in the dialog's OnInitDialog() method (that might be causing it to go away)?
|
|
|
|
|
Well, no. The dialog only has a ClassWizard-generated class connected to it. I haven't edited that class by hand in any way. In fact, there is no OnInitDialog string in any of the source code. I am assuming that means that MFC does all the required "standard" work?
------------------------------
The great successful men of the world have used their imagination...they think ahead and create their mental picture in all its details, filling in here, adding a little there, altering this a bit and that a bit, but steadily building-steadily buildings. (Robert Collier)
|
|
|
|
|
Your CDataEdit is derived from CDialog ? That is, it has
class CDataEdit : public CDialog
{
...stuff...
} written in its header file?
My opinions may have changed, but not the fact that I am right.
|
|
|
|
|
Yes, it's derived from CDialog.
If you want and got the time, I can give you the source code to see if you find anything wrong...
------------------------------
The great successful men of the world have used their imagination...they think ahead and create their mental picture in all its details, filling in here, adding a little there, altering this a bit and that a bit, but steadily building-steadily buildings. (Robert Collier)
|
|
|
|
|
OldViking wrote:
It has the child-style set.
This is the problem I bet. If you are trying to show a modal dialog box, don't make it a Child, make it a Popup style. If your point was to embed the dialog on a different window, that's a whole different story.
So, for now, go change that Child style to Popup, and you don't need to create the dialog on the heap if it's a modal dialog. Just create it on the stack:
C_ICantRememberTheClassName_Dlg dlg;
dlg.DoModal();
Chris Richardson Terrain Software
|
|
|
|
|
I recommend you teach yourself via one of the many available tutorials on MSDN. I used Scribble and it helped tremendously with all this stuff.
Regards,
Alvaro
If you want to get to the top, prepare to kiss a lot of bottom. -- despair.com
|
|
|
|
|
Hi,
I want to change the Winlogon policy
programmatically. This I'm able to do by finding some of
the registry entries in the Windows registry which would
bring this policy into effect.
But changing this policy through registry don't show the
changed status in the windows 2k Local Security Policy
snap-in.
What shall I do to reflect this change in the Local
Security Policy Snap-in.
Thanks,
Abhishek.
Learning is a never ending process of Life.
|
|
|
|
|
Hello,
i have a text file where i store a number. When i read the value in my szBuffer(CString) i like to cast this to an integer because i want to increment this value.
After the incrementation i like to write the value back into the file. So cast from int to CString(szBuffer)
Any ideas, code?
Thanks, Mark
|
|
|
|
|
try this:
iInteger=atoi(LPCTSTR(csCString));
iInteger++;
csCString.Format("%d",iInteger);
this should do it!
greets,
Jason
|
|
|
|
|
yeah, works great. And how is the function to cast int to CString??;)
Thanks, Mark
|
|
|
|