|
What is HRESULT and HIWORD and LOWORD
please write example ...
|
|
|
|
|
|
Do the struct type accept data member of kind CArray?
Thank in advance, Leudis
|
|
|
|
|
Why not? Just try out.
Uwe Keim
http://www.zeta-software.de
|
|
|
|
|
My document has an unknown size (is listCtrl), I don't know how can I indicate to print loop that my document is multipage.
Thank in advance, Leudis.
I sorry but my English is very poor.
|
|
|
|
|
hi,
I'm looking for a way to add items to the popup menu that appears when you right click on a file in Windows. It would be nice if I could add an extra option too the "send to" part of the popup menu from a Visual C++ program ... Can anyone help???
Regards,
FlashP
|
|
|
|
|
|
I dunno about code.. but to do it manually just create a shortcut to your program in C:\windows\SendTo
|
|
|
|
|
I have a Date and time picker control on a property page with the DTS_SHOWNONE style.
Each time I swith back to the page that has the date and time control the check box is always checked whereas it was unchecked before switching to another page.
After stepping into the code I found that each time the page gains the focus, the DDX_DateTimeCtrl is called.
The DDX_DateTimeCtrl doesn't take into account the previous state of the check box.
I checked twice and I have the latest SP for VC++ 6.0.
Does someone know if that bug have been reported ?
P.S.: In case I am the only having this problem, please let me know
Regards,
Daniel BERMAN
|
|
|
|
|
It's hard to say w/o seeing your code. The first thing I'd check is, is does your page have the disabled style in the resource file? Not making the page disabled can lead to strange behavior.
--Mike--
http://home.inreach.com/mdunn/
|
|
|
|
|
Well the pages are disabled.
The problem seems to be in the way the DDX_DateTimeCtrl(CDataExchange* pDX, int nIDC, CTime& value) function is implemented.
When the function is called to save the data it calls CDateTimeCtrl::SetTime(&value) with a valid pointer that causes the SetTime function to set the flags to GDT_VALID with no regards to the previous state !
Daniel
|
|
|
|
|
Ah, ok. In that case, you can write your own DDX routine - just copy the code from MFC's routine and fix the problem.
--Mike--
http://home.inreach.com/mdunn/
|
|
|
|
|
Is there API that I can export the registry settings programmatically?
There is a similar function in regedit, i believe that there is one similar in API.
Thanks all!
|
|
|
|
|
Hello, can anyone help me?
I have a ListControl (it has the Member-Variable m_ctlList).
I want to read the data from the list-control and write it
into an INI-File.
That's a part the code (it is obviously written with MFC):
char *keys[4] = {"1","2","3","4"};
int num_items = m_ctlList.GetItemCount();
for(int i=0; i
modified 12-Sep-18 21:01pm.
|
|
|
|
|
Hello, the codegurus around the world.
WritePrivateProfileString should be assigned the absolute path showing ini files for four parameter.
Otherwise, it created Statistics.ini at Windows direcory.
If there is no the same ini file at Windows directory,
there is something wrong?
HTH.
-Masaaki Onishi-
|
|
|
|
|
I know the file is created at the Windows directory
and there is no other ini-file with that name...that's not the problem.
The problem is that nothing is written after the equal-sign
in the ini-file, although the 3rd parameter has a valid content
cu
modified 12-Sep-18 21:01pm.
|
|
|
|
|
Hi
I have a static control stretched to a big rectangle and i want to scroll in that control, so i was thinking of doing that using the scrollbar functionality of the CWnd derived controls.
I derived a CStatic class called CCanvas;
I did a call to CCanvas::EnableScrollBar() and both a hor. and a vert. scrollbar which were not grayed out appeared. But i cannot move them nor receive messages from them (according to Spy++).
Does anybody know how to enable those scrollbars and use them??
Joris Mans
|
|
|
|
|
I want to change the font of the icons on the desktop. I use this function that wraps SystemParametersInfo:
inline BOOL SPI_SetIconMetrics( ICONMETRICS pIconM, UINT Update )
{
pIconM.cbSize = sizeof( ICONMETRICS );
return( ::SystemParametersInfo(
SPI_SETICONMETRICS,
sizeof( ICONMETRICS ),
&pIconM,
Update ) );
}
I use a valid ICONMETRICS structure and SPIF_SENDCHANGE (documented in MSDN) as Update parameter. Nothing happens on the desktop, but:
1) The font changes in other windows, for example in the icons displayed in My Computer;
2) In Desktop Properties, in the page where you change system colors, the new font for icons is reported correctly. But icons change only if I click on Apply.
How can I update my icons? Note: Accessing desktop as a CWnd and using UpdateWindow, Redraw ecc. does not work.
Any help will be appreciate.
Marakid
|
|
|
|
|
I'm looking for a way to code something like these beautiful roll-up controls in 3ds max.
Any help ?
Thanks
Roms.
|
|
|
|
|
The idea is to use a page concept. Each page is based on a CDialog, and has a IDD referencing the dialog template you want.
When each page is added to the control (similar to the PropertySheet::Addpage function) , make it the child of a container window that contains the show/hide button and group border. This container is in turn a child window of the actual control.
When a container button is pressed, just show or hide the page window as appropriatte, and resize the container to the 'hidden' size.
When something happens to change the look of the control, such as one of the container buttons being pressed, or scrolling of the control contents, call a layout function that moves the container windows around (normally just a vertical re-positioning) so that the pages look like they are opening and closing.
Thats the basic concept, I have some code for this lying around if you really want it, its not generic, but it works.
|
|
|
|
|
Finally I found a * really * good solution. If you want, I can Email you the code source.
I use the following architecture :
CRollboxCtrl : public CDialog
- AddPage(CGroupCtrl *)
- ShowPage(int page_index)
- HidePage(int page_index)
This is the whole Control... (including the groups which are my 'property pages')
CGroupCtrl : public CDialog
(DECLARE_DYN_CREATE)
Each "property" page is derived from this class...
CPropertyPage : public CGroupCtrl
The property class... Just create a CDialog with Class Wizard and replace each "CDialog" by "CGroupCtrl"...
So, it's easy to create a control box.
It's owesome ! that's really cool, I spend just 1 day to make this control, and it's nice (even nicer than the controls in 3ds max).
The only drawback is that I can figure out how to create a CScrollBar control to scroll the groups in the controls.
My Email is Roms@usa.com and I would be glad to send you the actual code if you wanna take a look.
Roms
|
|
|
|
|
Hi,
I'd like to know if there's a way to play AVI files from memory using the AVIFile functions?
All I found from Net was a Win32 SDK document Q155360:
"HOWTO: Use MCI to Play AVI/WAVE Files from Memory"
(can be found from online MSDN) which explains how to play AVI files from mem using the MCI (media control interface).
I'm more interested to get the actual bytes of each frame of the AI files. Using the AVIFile functions I can do that, but the MCI wont do that.
I tried to use the method decribed in the document Q155360, but all I got was a Access Violation in avifil32.dll.
I know how to make a custom AVIStream, but I would not like to parse the AVI file myself. Instead I'd prefer similar trick as the forementioned document suggests. Saving the AVI to a temporary file is out of question. Any ideas?
Thanks...
--memon
|
|
|
|
|
Hi there,
I have an activeX control and in it, I do handle the VK-BACK on KeyUp. However, even when I am clicking on an item on the ActiveX, when I click backspace, IE switches to the previous page.
How do I completely and fully suppress the backspace, so my pages don't change on me?
thanks!
|
|
|
|
|
Folks,
I have an urgent need to add a 32-bit ActiveX control (OCX) to a VC++ DLL,then instantiate and access this OCX only from the DLL. The current DLL doesn't contain any visible Windows or CWnd objects in which to host the component.
However, it does contain a main application object (CWinApp). Is this possible or do I have to provide a form and then hide it from the user.
If possible, I would like to avoid the later scenario. Can someone provide me with an example of this or point me to a source explaining this concept. It seems that any events fired by the control wouldn't be available to my app, and this is fine.
Thanks in advance for any consideration and help in solving this problem.
|
|
|
|
|
Any idea or tutorial on how to create a NetDDE Client and Server in Visual C++.
|
|
|
|