|
I haven't used SDI/MDI or neither MFC for long so I don't know!
Someone else have to take over now!
Rickard Andersson@Suza Computing
C# and C++ programmer from SWEDEN!
UIN: 50302279
E-Mail: nikado@pc.nu
Speciality: I love C#, ASP.NET and C++!
|
|
|
|
|
In your string table, you will find an entry for IDR_xxxxxxTYPE, where xxxxxx is your original file type. Replace the text in the string to:
\nJunk\nJunk\nJunk Files (*.junk)\n.junk\nJunk.Document\nJunk Document
Where Junk is your document type.
Hope that helps.
- Nitron
"Those that say a task is impossible shouldn't interrupt the ones who are doing it." - Chinese Proverb
|
|
|
|
|
Am I missing something? If I want to hook the minimize button, I add an OnSysCommand() method and look for SC_MINIMIZE, right?
What would make my CPropertySheet-derived dialog behave differently? I get the SC_CLOSE, but no SC_MINIMIZE.
J
May the bear never have cause to eat you.
|
|
|
|
|
No no, don't everybody rush to help out.
It turns out that you need to specify the WS_MINIMIZEBOX when you actually create the CPropertySheet-derived window (ie, pDlg->Create(whatever, WS_OVERLAPPEDWINDOW); // <- included in there). Specifying it later did not seem to work.
And using ModifyStyle() in the InitDialog() showed the minimize box, but wouldn't actually allow the dialog to send the associated WM_SYSCOMMAND. Weird.
I lurve MFC.
J
May the bear never have cause to eat you.
|
|
|
|
|
That kind of jogs my memory. I am not sure if this is what you were experiencing, but you need to make a call like this:
::SetWindowPos(hWnd, NULL, 0, 0, 0, 0, SWP_NOSIZE | SWP_NOMOVE | SWP_NOZORDER | SWP_NOACTIVATE | nFlags);
after certain style changes with SetWindowLong in order for the style to be completely set into the window. Maybe the WS_MINIMIZEBOX is one of those styles.
Build a man a fire, and he will be warm for a day Light a man on fire, and he will be warm for the rest of his life!
|
|
|
|
|
Hmmmm. I did a quick check it didn't succeed, but that doesn't mean much.
Thanks for the pointer - it's a useful tidbit to know regardless of whether or not it solves this problem.
J
May the bear never have cause to eat you.
|
|
|
|
|
Hello,
I am looking for the mentioned sysmsg.dll . I was unable to find on my Windows 2000 and it is not included with Visual Studio (I have a service pack 5). Could you please help me (let me know) where could I get it?
Or is there somebody who has it (perhaps with a lib and header if required) and could send it to me?
Thanks
|
|
|
|
|
I'm currently building a ListView control that is able to be edited in-place. So far I've got an edit control working, but I'm having problems with a spinner control.
The first problem is I can't set the focus to the spinner control after I've created it. I tried using the same method (SetFocus()) I used for the edit control but doesn't work.
The second problem is I can't trap when the 'Esc' or 'Enter' are pressed. For the edit control I'm using PreTranslateMessage(), but it's not getting called when the spinner is created.
Anybody no what's going on? Have an examples I can take a look at?
Thanks
Chris
|
|
|
|
|
the program has a view,
there are 2 Splitter Windows.
i will open a file in the 2 Splitter Windows.
one is hex. one is txt.
i feel good.
|
|
|
|
|
it must be choose one file ,
and open it in 2 Splitter Windows and in the same time.
i feel good.
|
|
|
|
|
for hex, open as ios::binary, for text, ios::text
- Nitron
"Those that say a task is impossible shouldn't interrupt the ones who are doing it." - Chinese Proverb
|
|
|
|
|
i have seen a code that is
class CHexEditCtrl : public CRichEditCtrl
it change CString to Hex,but it is in a EditCtrl.
i want open a file in a View
i can write a class
which public CView as --- class CHexEditCtrl : public CRichEditCtrl??
i feel good.
|
|
|
|
|
why not just create a CRichEditCtrl in your view and use that? Then you can have access to all the fun fonts and colors too.
- Nitron
"Those that say a task is impossible shouldn't interrupt the ones who are doing it." - Chinese Proverb
|
|
|
|
|
Hi !!!
I'd like to automatically run my app when inserting the CD-Rom (containing my app).
My app will be developped with VC++ 6, using the MFC.
What I was wondering is : is it possible ? I know that the MFC needs some DLLs, so how can I run my MFC App from the CD-ROM if the required DLLs are not on the local computer ? Linking the MFC statically is enough ?
Thanks !
Jerome
|
|
|
|
|
To resolve the DLL things, your application need to be statically linked with MFC ( if possible ), and if it needs other DLL, they should also be on the CD.
You can also do some pre testing, in the autoload thingy on the CD, start another application that checks for DLL's and other things, and then start your application.
Or, you can "temporarilly" install the application in a temp directory to run it.
Max.
|
|
|
|
|
Yep linking statically is fine...
Or as long as you place the DLLS the app needs in the same directory as the applcation it elf...
Asim Hussain
e: asim@jawache.net
w: www.jawache.net
|
|
|
|
|
Make an autorun.inf file containing the following:
[autorun]
OPEN = YOUREXE.EXE
ICON = YOUREXES.ICO
replace the italicized text
Jason Henderson start page ; articles
henderson is coming
henderson is an opponent's worst nightmare
* googlism *
|
|
|
|
|
Is it possible to query the remaining time of timer (returned by Set/CreateWaitableTimer )? If so HOWTO???
10x
--BlackSmith--
/*The roof is on fire, we don't need no water, let the MF burn*/. BHG.
|
|
|
|
|
I don't know of any Timer-related function to do so, but I would probably go with something like GetTickCount to grab the times first at SetWaitableTimer and then at WaitForSingleObject. The max wait time minus the difference of these two should tell you how much time was left.
Regards,
Alvaro
Well done is better than well said. -- Benjamin Franklin
(I actually prefer medium-well.)
|
|
|
|
|
When I have 2 instances of VS.NET compiling at the same time, one of them makes an access violation error.
Is there a way that I can have 2 instances compiling at the same time?
Michel
It is a lovely language, but it takes a very long time to say anything in it, because we do not say anything in it, unless it is worth taking a very long time to say, and to listen to.
- TreeBeard
|
|
|
|
|
What is the exact difference between them ?
I create next modeless dialog from main dialog. (MFC dialog based application). But it doesn't matter what the type of dialog in resources i use - result is the same.
rrrado
|
|
|
|
|
I believe one difference is that an overlapped window has a frame is can be resized.
Kuphryn
|
|
|
|
|
No, you can set resizable border also on the popup window, t tried that
rrrado
|
|
|
|
|
Hi all,
I am trying to get a bit of assistance as to the best method of of using data stored in my database, as the means of populating a CTreeCtrl. I have currently included the CTreeCtrl in my project, and now I want to be able to populate individual nodes, with the information stored in my database. Any assistance appreicated.
Regards
|
|
|
|
|
Assuming that you have something like a recordset, whenever you iterate thru the recordset you could add items to the Tree using the InsertItem() method . Also in one of my projects I needed to record changes made to the CtreeCtrl for which I had a structure array .
|
|
|
|