|
Yes, that might be a better way to do it (though AppWizard puts the call to DoModal() in a dialog-based app's InitInstance()) and I've made that change. It makes no difference to the functionality that I see.
Since I can get the correct title bar and Alt-Tab icons to appear by setting them in the property sheet's OnInitDialog(), the real issue is the button on the taskbar. I guess the modeless dialog is considered the main window for the task (it has to be created first), since when it is displayed the button appears and as soon as it is hidden (SW_HIDE) the button disappears. So I can't hide the modeless dialog without also disappearing the taskbar button. So for now I'm not hiding the modeless dialog, which is undesirable.
There is also the issue of the initial icon on the taskbar button. I've added SetWindowText() to the modeless dialog's OnInitDialog() to set the proper caption, since there's no title bar, and added WS_SYSMENU to the .rc to force the icon to appear, but, until the property sheet loads the icon I want, I see the MFC cube icon in the taskbar button. After the property sheet loads the icon, that one is always displayed on the taskbar, even when I've temporarily destroyed the property sheet and the modeless dialog has reappeared.
What I'd like is to be able to hide the modeless dialog when I display the property sheet and not have the taskbar button disappear, and to set the taskbar button's icon so the MFC cube doesn't appear.
|
|
|
|
|
i just tried following code it works
m_prop.m_hIcon = AfxGetApp()->LoadIcon(IDI_MYICON);
m_prop.m_psh.dwFlags |= PSP_USEHICON;
m_prop.m_psh.hIcon = m_prop.m_hIcon;
SetIcon(m_hIcon, TRUE);
try this may help you...
The secret of life is not enjoyment
but education through experience.
- Swami Vivekananda.
|
|
|
|
|
The problem I have is in the table.
When I create a table of 12 lines the data printed is correct.
Then I come back in beause the is two tables. The second table has 6 rows.
Howver I only process only 5 roww. I move in data for these 5 rows and the when printed. The 6 row hase the data from the frist pages data for the 6th row. I do space out the data however, the data still has the data from the first page for the 6 row.
Can you PLEASE help me. My email address is WillmsDick@hotmain.com
Thanks
|
|
|
|
|
|
Post what you have tried (please use code tags), and maybe rephrase your original post as it was very unclear (to me anyways) as to what you are saying.
|
|
|
|
|
You should delete the data in your first table (12 rows) before adding the new data from the second table. When all you do is overwrite the old data you can get remnants of the old data mixed in with the new.
If this did not help you then you should post some relevant code to give us a better idea of what is happening.
You may be right
I may be crazy
-- Billy Joel --
Within you lies the power for good - Use it!
|
|
|
|
|
Hi
I need to do some data encryption. I need encrypt the data using "perl" and decrypt the data using Borland C++ (ActiveX).
Any recommendations are greatly appreciated.
Thanks,
modified on Tuesday, October 6, 2009 1:59 PM
|
|
|
|
|
|
I tried that software package. It does not support Borland C++.
Thanks,
|
|
|
|
|
Hi
I have problem with retrive a list of files open by one process for example notepad.
I alredy have the list of processes (Name and PID)
conime.exe (PID: 3384)<br />
rxvt.exe (PID: 3392)<br />
sh.exe (PID: 3484)<br />
SbPFCl.exe (PID: 3888)<br />
<unknown> (PID: 4044)<br />
GoogleDesktop.exe (PID: 4080)<br />
avgnt.exe (PID: 2184)<br />
jusched.exe (PID: 1156)<br />
GoogleDesktop.exe (PID: 1860)<br />
CarboniteSetupLitePBPreInstaller.exe (PID: 2824)<br />
rxvt.exe (PID: 3692)<br />
sh.exe (PID: 2692)<br />
notepad++.exe (PID: 2036)<br />
SciTE.exe (PID: 3156)<br />
<unknown> (PID: 3680)<br />
firefox.exe (PID: 3116)<br />
cmd.exe (PID: 1868)<br />
procexp.exe (PID: 2076)<br />
<unknown> (PID: 2604)<br />
mspaint.exe (PID: 3856)<br />
<unknown> (PID: 468)<br />
sh.exe (PID: 3880)<br />
spyprocess.exe (PID: 3260)
Let´s sey that in notepad++ I have opened 2 files .
I need the list that look like:
List:
Notepad++:
file1.txt
file2.txt (active)
file3.txt
Is there any function to enumerate this files or just to get this active file name or its path?
|
|
|
|
|
slawekwwww wrote: Is there any function to enumerate this files or just to get this active file name or its path?
Although it is unsupported by Microsoft it is possible to call the NtQuerySystemInformation Function[^] and populate an array of SYSTEM_HANDLE_INFORMATION structure.
Best Wishes,
-David Delaune
|
|
|
|
|
No, it won't work.
Notepad don"t let handles opened.
(see notepad source code)
|
|
|
|
|
kilt wrote: Notepad don"t let handles opened.
I do not understand your comment. Do you care to clarify?
Best Wishes,
-David Delaune
|
|
|
|
|
I have some code here
private: System::Void TS11_Click(System::Object^ sender, System::EventArgs^ e) {
++Tsn11;
if (Tsn11 = 0) { this->TS11->Image = Image::FromFile("C:/GamePics/NOTILE.png");}
else {
if (Tsn11 = 1){ this->TS11->Image = Image::FromFile("C:/GamePics/GREEN.png");}
else {
if (Tsn11 = 2){ this->TS11->Image = Image::FromFile("C:/GamePics/GRTRE.png");}
else {
if (Tsn11 = 3){ this->TS11->Image = Image::FromFile("C:/GamePics/ROAD.png");}
else {
if (Tsn11 = 4){ this->TS11->Image = Image::FromFile("C:/GamePics/WALL.png");}
};
};
};
};
};
};
when you click on the image, it gets the next one, but it only works one time
How can I make it work every time?
|
|
|
|
|
Hi,
This is the C++/MFC forum. You should ask your question in the C# forum[^].
Best Wishes,
-David Delaune
|
|
|
|
|
You could at least have answered it.
And I am writing it in C++...
So what...
|
|
|
|
|
You are in the wrong forum. Use the Managed C++/CLI forum[^]. This forum has nothing to do with .net.
You may be right
I may be crazy
-- Billy Joel --
Within you lies the power for good - Use it!
|
|
|
|
|
Fenix2 wrote: if (Tsn11 = 0)
Shouldn't that be if (Tsn11 == 0) ?
You may be right
I may be crazy
-- Billy Joel --
Within you lies the power for good - Use it!
|
|
|
|
|
Hi,
Can anyone tell me how to open a multi-page TIFF file using GDI+ ?
I use GDI+ to open various image files and then draw them on a printer DC. I use the same function for all types of image files:
Image* p = Image::FromFile(strFile);
But in the case of multipage TIFF this loads only the first page.
There is sufficient light for those who desire to see, and there is sufficient darkness for those of a contrary disposition.
Blaise Pascal
|
|
|
|
|
|
Here is the code I use for loading multipage images. It works for animated gifs as well as tiffs. It does not work for multi image icons however.
Gdiplus::Image Image(static_cast<LPCWSTR>(CT2W(FilePath)));
if (Gdiplus::Ok == Image.GetLastStatus())
{
GUID DimensionID;
Image.GetFrameDimensionsList(&DimensionID, 1);
UINT Frames = Image.GetFrameCount(&DimensionID);
for (UINT CurrentFrame = 0; CurrentFrame < Frames; ++CurrentFrame)
{
if (Gdiplus::Ok == Image.SelectActiveFrame(&DimensionID, CurrentFrame))
{
You may be right
I may be crazy
-- Billy Joel --
Within you lies the power for good - Use it!
|
|
|
|
|
Thanks for the code, I was wondering how to use the GUID and the MSDN docs weren't very clear, so your code is a lot of help.
There is sufficient light for those who desire to see, and there is sufficient darkness for those of a contrary disposition.
Blaise Pascal
|
|
|
|
|
Dear Experts,
While running the visual c++ program for active directory querying an error occuring like activeds.h is not included.so my question is whether we have to create activeds.h or it is builtin header file.provide me a solution to run the program
|
|
|
|
|
raja 4 wrote: so my question is whether we have to create activeds.h or it is builtin header file.provide me a solution to run the program
See here.
"Old age is like a bank account. You withdraw later in life what you have deposited along the way." - Unknown
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
|
|
|
|
|
Hi All,
I am a beginner in Adobe Indesign CS4.When i build a plugin using dollyxs and running it i am getting the following error.
PRJ0019:A tool returned an error code from performing custom build set up.
Can anyone solve this problem??
I am using Microsoft visual studio 2008 and AdobeIndesign cs4
Regards
G.Narendra Babu
|
|
|
|