|
|
Sternocera wrote: There are 3 columns
But you were calling InsertItem() with only one variable argument, hence the 1 that I supplied. If you wanted to call it with three arguments, you would need to do:
SampleReportCtrl.InsertItem(0, 3, _T("test1"), _T("test2"), _T("test3")); You would obviously need to change the method's signature for this to work properly. Your solution of making the last argument 0 is probably a bit cleaner, however.
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
InsertItem is an overloaded function. I found by calling it in this manner:
SampleReportCtrl.InsertItem(0, _T("test1"),0);
SampleReportCtrl.InsertItem(1, _T("test2"),0);
SampleReportCtrl.InsertItem(2, _T("test3"),0);
everything worked nicely. Thanks!
|
|
|
|
|
Sternocera wrote: I found by calling it in this manner:
SampleReportCtrl.InsertItem(0, _T("test1"),0);
SampleReportCtrl.InsertItem(1, _T("test2"),0);
SampleReportCtrl.InsertItem(2, _T("test3"),0);
everything worked nicely.
Which creates 3 rows and 1 column.
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
Yes. Thanks for your help, David.
|
|
|
|
|
how many columns are there in the list control?
|
|
|
|
|
Hai All,
Can anybody please expalin me a way.I'm having a handle value(say hnd) to a dialog.I want to acess the controlls of that dialog (say edit control).I know the ID (say IDD1)of the controll also.But when I'm using the ::GetDlItem(hnd,IDD1) it is showing unreferenced memory.
MyCode is like this
hnd=::GetForegroundWindow();
HWND hWnd = ::GetDlgItem(hnd, IDD1);
CEdit* pEdit = (CEdit*)CWnd::FromHandle(hWnd);
pEdit->SetWindowText("HELLO");
My intenetion is to change the text of the edit controll(IDD1).
Thanks in advance
Robs here
|
|
|
|
|
Wheres the edit control if its on the current dialog you can use of Id of editcontrol you enter Id of edit control on GetDlgItem and dont need to ID of Dialog.
|
|
|
|
|
robshere wrote: hnd=::GetForegroundWindow();
HWND hWnd = ::GetDlgItem(hnd, IDD1);
CEdit* pEdit = (CEdit*)CWnd::FromHandle(hWnd);
You are not checking the return value of any of these functions. Why?
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
I have a PC connected via HDMI to my TV but after a period with the TV on another input the PC's HDMI output switches off.
Is there a function I can call to force a display detection again as this sorts things out?
It's an ATI Radeon Express 1250 on a motherboard by the way.
Thanks.
Elaine
|
|
|
|
|
*If* its ACPI causing the port to power down, can't you just disable ACPI in the BIOS? Try it and see if it helps.
-Randor (David Delaune)
|
|
|
|
|
I want to write a program that would swap the left and right audio channel system wide (regardless of audio/video player). This is not a program that plays audio/video files, but works kind like a filter, any audio that outputs to the speaker/headphone should be affected by this program. Is this possible? if so, can someone point me in the right direction on how this could be done.
What should I look into? directsound? audio driver?
I only want to write this because I couldn't find any program that would do this. If such program exist, what is the name of the software?
Thanks
hi
|
|
|
|
|
often the driver of the audio card give you a boolean flag to choose if you want to reverse the speakers. Take a look to the control panel before start to write the program.
Russell
|
|
|
|
|
Hi all,
I need to select only exact file from directory.
For example file.ttt.
I am trying the following:
<br />
CFileDialog fileDialog( TRUE, NULL, "file.ttt", NULL, "file.ttt" );<br />
But there is no visible files.
Please help me to resolve the problem.
|
|
|
|
|
CFileDialog fileDialog( TRUE, NULL, "file.ttt", NULL, "All files(*.ttt)\0*.ttt\0" );
|
|
|
|
|
Romiks wrote: But there is no visible files.
Does file.ttt exist in the folder that is initially opened?
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
This should do the task correctly....
CFileDialog FileDlg(TRUE,_T("file.ttt"),NULL,NULL,_T("ttt Files(*.ttt)|*.ttt||"),NULL );
Who am I?
Do you know me....
|
|
|
|
|
Rivezle wrote: If anyone could advise me as what to do...
What exactly is your question?
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
How should i go about re-creating my old programs, through a 100% coding or another way.
|
|
|
|
|
Rivezle wrote: How should i go about re-creating my old programs...
Open the IDE, select the type of project you want. Do you want a doc/view (e.g., SDI), or a dialog-based, aplication? Once the bare framework has been created, start adding coding from there.
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
|
My question was is there a way i can make GUIs in the VS2005 IDE without going a 100% coding route and not requiring the .net framework to run the application, maybe i should repost in the Visual studio section.
|
|
|
|
|
Hello,
The following functions
_cexit, _c_exit, exit and _exit works fine on release mode but in debug mode the processes/procedures are not terminated when the functions are called.
I use VS 2003 and I use both managed and unmanaged code. Anyway I tried those functions with #pragma managed and #pragma unmanaged but the problem is the same.
Do you know why and how to make them working on debug mode?
Thanks for your help.
|
|
|
|
|
Which one do you need to use? They al perform differently.
MArk
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
I use _c_exit()
It allows me to exit from a procedure/process without closing the application.
|
|
|
|