|
i'm using visual studio 6.0. Do you know any related examples i can refer to.
thanks in advance
|
|
|
|
|
Are you handling the CBN_SELCHANGE notification? If so, in that handler function, use the GetCurSel() and GetLBText() methods.
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
Do you have any related examples that i can refer to. I'm still a beginner at this. so if yes, thanks alot
|
|
|
|
|
Use ClassWizard (Ctrl+W) to create a handler function for the CBN_SELCHANGE notification. In that handler function, call GetCurSel() and GetLBText() , like:
void MyDialog::OnSelChange()
{
int nIndex;
CString strText;
nIndex = m_combo.GetCurSel();
m_combo.GetLBText(nIndex, strText);
}
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
this doesn't mean anything. a combo box contains strings only, so when the Combo is populated, you have to store the source list, to recall the data selected later...
|
|
|
|
|
CBN_SELENDOK is the notification you want to be looking for. It is sent when the user selects and item, and confirms the selection. Do not respond to CBN_SELCHANGE because the user can select items and not confirm the selection (e.g. drop down the box, mouse over items to select them, and then press <esc> to cancel).
What you need to do after determining the user's action is another thing...
Peace!
-=- James If you think it costs a lot to do it right, just wait until you find out how much it costs to do it wrong! Avoid driving a vehicle taller than you and remember that Professional Driver on Closed Course does not mean your Dumb Ass on a Public Road! DeleteFXPFiles & CheckFavorites (Please rate this post!)
|
|
|
|
|
Do you know any related examples i can refer to? if yes, it would be great. i'm a beginner at this. thanks
|
|
|
|
|
Do you have any related examples that i can refer to. I'm still a beginner at this. so if yes, thanks alot
|
|
|
|
|
After declare CBN_SELCHANGE and get string of combobx you need to path of this string
|
|
|
|
|
We usually assign String value to an ID in the String table. e.g.
**************************************************
STRINGTABLE
BEGIN
IDS_ABOUTBOX "&About..."
IDS_VALUE "Value"
END
**************************************************
We use LoadString() method to retrive the value of IDS_VALUE.
However, how can we allocate a new value to IDS_VALUE in the code side? maybe "New Value"
thx!
Skytear
|
|
|
|
|
xiaoke wrote: However, how can we allocate a new value to IDS_VALUE in the code side? maybe "New Value"
Either change the .rc file and recompile, or use BeginUpdateResource() and UpdateResource() .
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
Ok,
After googling my brains out, asking all my friends on ICR, Yahoo, AIM, and MSN/Live!, I stand corrected when i say "If you know how to use good keywords, you can find anything on google". I know in VB6, the MS-Winsock ActiveX control can become an array item simple by making
Winsock_Control.Index = 0
but i'm a Newb to networking in C++, and after reading a million articles, still have no clue how to make an array of sockets, or how to respond to incomming data from each one, without writing a seperat function for each one. i managed to get 1 to work after reading an article i found here on the site ( HUGE thanks to the author of "Programming TCP.doc" ) but, now i am left with the question, and a handful of hair...where are the arrays?? either a snippit of code, or a link to a good article would truely make my day
**PPPSHT** ACA Over And Out....*PSSHHT* 10/4 ACA
One day all military forces will be robotic, and you will know the ones programmed in VB, because they will appear to have downsyndrome - Inetd.Conf
|
|
|
|
|
i opend the harddisk like this
sHardDisk.Format("\\\\.\\PhysicalDrive1");
HANDLE hDevice = CreateFile(sHardDisk,GENERIC_READ,......,0,OPEN_EXISTING,0,0);
then i read the Partition table using ReadFile
Everything is fine i can read all the partitions and extended partitions directly from harddisk but my questions is
How can i find out the logical drive name corresponding to the Partitions and extended
partitions that i read directly from hard disk?
Thank you in advance.
To err is human, to blame it on somebody else shows management potential.
|
|
|
|
|
Hi,
Are you talking about something like this [^] ?
-----------
Mila
|
|
|
|
|
You got me curious now whats the difference between
"\\Device\\HarddiskVolume1" and "\\\\.\\PhysicalDrive1" i suspect one is a logical drive and the other is a device.
what i am doing is opening the harddisk reading directly from the sectors and loading the partition table and then reading the MFT.
I dislike feeling at home when i am abroad.
To all the virgins in the world thanks for Nothing.
|
|
|
|
|
hi all
i'm developping an application wich use a lot of xml documents...i want to parse a file xml, but i didn't find any function or Api to do it..
can you help me please...
thanks
|
|
|
|
|
You can use TinyXML[^] for this purpose. It's a nice cross-platform XML parser.
|
|
|
|
|
it's ok..thanks a lot
(merci beaucoup:->)
|
|
|
|
|
Depending on the features you want in a parser, there is Xerces/Xalan (which you can get off of www.apache.org), MSXML (which comes with Windows -- very similar API to Xerces), and TinyXML.
If you decide to become a software engineer, you are signing up to have a 1/2" piece of silicon tell you exactly how stupid you really are for 8 hours a day, 5 days a week
Zac
|
|
|
|
|
thanks Zac, i resolved my problem with Xerces, i'm now trying to find an application for converting from xml to C++ classes..if you know any tool for this, it will be a great day for me..
thanks again
|
|
|
|
|
use Serialization for this...
|
|
|
|
|
There are some tools that will generate these for you, but none of them are worth recommending. Personally, what I've always done when dealing with XML is to first write an .XSD file (schema), and then to write my class heirarchy by hand (which really shouldn't take you too long) and then to write a parsing routine to fill in the data as I march through it. When I've tried a few of the code generators, I've found myself fixing and changing much of the code anyway, so they really aren't all that useful.
If you decide to become a software engineer, you are signing up to have a 1/2" piece of silicon tell you exactly how stupid you really are for 8 hours a day, 5 days a week
Zac
|
|
|
|
|
|
Hello,
I get the handle of a window on a other process with the function FindWindowEx. How i can get the ThreadId of this handle on Windows XP.
I have tried to use "NtQueryInformationThread" but I will get Access Denied. Then i have tried to change the access restriction of the handle with API "SetSecurityInfo(handle, ...)" but I get the error "The handle is invalid". But the handle is valid. I' getting crazy now , nothing will work.
If you have a solution to get the handle I'm very happy.
I need the TreadID to setup "SetWindowsHookEx()" and capture (hook) then Messages to this window.
May you know a simpler solution to capture messages of a window.
Thank you very very much.
regards
michi
|
|
|
|
|
Have you tried GetWindowThreadProcessId() ?
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|