|
Well, I can't get that to work b/c I have new classes in this project. The program simply minimizes all current windows and opens the default webbrowser.
I wonder if I have imported my icon in VC++6 correctly b/c there still is no resources tab, when viewing the Workspace, it does compile though
|
|
|
|
|
I figured it out, I needed to add the Script1.rc file it created to my project Thanks!!
"I'd rather be a smart ass, than a dumb ass"
|
|
|
|
|
Hi, I am learning C++ and I was wondering If someone could give me an example on how to Shell an EXE with a DLL.. (For example.. when the DLL is loaded into memory, it loads an EXE)
Thanks
|
|
|
|
|
Hi All,
I need some help. I was wondering if there is a way to initialize a list box so that it shows the values already in the listbox when the program starts. The thing is that I have to display 777777 values and I currently load the listbox using a thread, but it takes like 8 minutes to load all the values. So I was wondering if there is a way to load the strings into the listbox before the window loads. Thanks for help.
|
|
|
|
|
look around here, at codeproject, there's a "virtual" listbox that's made just for that.
Max.
|
|
|
|
|
Hi,
I have 2 edit boxes on a dialog box. I have associated two member variables for these edit boxes. However, the variables don't seem to get the data I type in the boxes.
Any suggestions on what I'm doing wrong?
|
|
|
|
|
the variables are only updated when you call UpdataData.
-c
A conclusion is simply the place where someone got tired of thinking.
|
|
|
|
|
How Locate the error when meet the leak as follow?
/////////////////
Detected memory leaks!
Dumping objects ->
{46} client block at 0x009C2590, subtype 0, 100 bytes long.
a CWnd object at $009C2590, 100 bytes long
Object dump complete.
The thread 0x244 has exited with code 0 (0x0).
//////////////////////
thanks in advance!!
|
|
|
|
|
how do u get those wonderful information?
includeh10
|
|
|
|
|
it's in the VC debugger's output window
A conclusion is simply the place where someone got tired of thinking.
|
|
|
|
|
|
1. find out where you allocated a CWnd.
2. determine where you can it.
3. delete it.
-c
A conclusion is simply the place where someone got tired of thinking.
|
|
|
|
|
If there is a method to tell which CWnd is not delete?
thanks!
|
|
|
|
|
Look at default c++ files generated by Visual C++, they usually/always have a few preprocessor lines at the beginning that enable additional debugging info, as well as leak information; if it's defined, the leak is identified, with the code line where the allocation was made.
Max.
|
|
|
|
|
Since you've already got that intel, I think you may have seen Detecting and Isolating Memory Leaks Using Microsoft Visual C++[^].
Further in that article, there's a section called Comparing Memory States. If you suspect code that's leaking, wrap it with a call to checkpoint the memory before, and after, then compare. The article gives an example.
|
|
|
|
|
Has anyone gotten the last paramter to LoadImage LR_TRANSPARENT to work? I myself have not...(image loads but with the white background that clashes with the window). Can anyone help me on this?
|
|
|
|
|
if your talking about LR_LOADTRANSPARENT here is perhaps the answer.
First of all LR_LOADTRANSPARENT does not load transparent image. it replace the first color by COLOR_WINDOW. COLOR_WINDOW is the backgroud color of edit,combobox... by defaut it's white. To change this color by another, you need to replace this color in your window theme.
The second problem is that LR_LOADTRANSPARENT works only with 8bpp images.
The easyest way to use real transparent images is to use CommonControls ImageList.
If you only want to replace one backgroud color by another CommonControls CreateMappedBitmap is perhaps a best solution.
Dimitri Rochette
|
|
|
|
|
i explain:
click a .cpp file, if VC was installed, then VC pops up and displays the .cpp. if borland was installed ...
so, .cpp file is related VC or Borland.
if i develop a nodepad, how do i make .cpp etc related to my application? i guess it is something in register but ...?
thx
includeh10
|
|
|
|
|
Dunno if it is the correct key, but you might try HKEY_CLASSES_ROOT\cppfile\shell\&Open with MSDev
modified 12-Sep-18 21:01pm.
|
|
|
|
|
thx, that is right i think.
i.e. in .java i found "JCreator.java", but why jcreate.java, not jcreate.exe?
there should be more. i.e. i click my.txt (if it is related to MyApp.exe), how system passes the file name "my.txt" to MyApp.exe, from command line?
includeh10
|
|
|
|
|
First you'll need to come up with a "document name".
Something like MyFunkyAppDocType or whatever. Then
create a key under HKEY_CLASSES_ROOT by that name.
Under that key create keys Shell\open\command.
Set the default value to the command line to open
the document type. e.g. "C:\Program Files\MyFunkyApp %1"
Next, under HKEY_CLASSES_ROOT you'll see all the extensions
with associations. Just place the extension you want
associated there as a new key, and set the default value
to your document name.
But don't step on other associations without ok from the user.
i.e. check that your document name is unique. check that
the association is free or the user is willing to allow you
to overwrite it.
|
|
|
|
|
there is not WS_SYSMENU in my dialog,and the dialog app have no system icon and system menu.
how can i set the system icon or system menu?
and SetIcon() can not work.
please help me.
|
|
|
|
|
If you made this dialog in the resource editor then you have a choice of system menu which you can add.
|
|
|
|
|
|
Hi, everyone!
I have read some books about VC network programming, but in
them there are only basic samples (just to show the usage of API).
I want to know where can I get some sample codes of some more practical
samples? I want to learn socket programming.
Where can I get the codes and related explanations?
Cheers,
George
|
|
|
|