|
In a good mood today, tox'?
"It's supposed to be hard, otherwise anybody could do it!" - selfquote
|
|
|
|
|
Roger Stoltz wrote: In a good mood today, tox'?
still the morning here...
|
|
|
|
|
|
|
Hello,
I want to start a vector of calsses with the same contruct
Lets say this is my class :
<br />
class aaa<br />
{<br />
public:<br />
aaa(int i){ m_iA = i; }<br />
private:<br />
int m_iA;<br />
};<br />
and I want now to do 5 classes with the same contruct:
<br />
aaa* f = aaa(2)[5];<br />
I have to do a loop for this (pointer of pointers etc.) ?
Or it is possible to do this somehow in a short way ?
Thanks,
|
|
|
|
|
Ohad Cabiri wrote: I have to do a loop for this (pointer of pointers etc.) ?
In fact if you don't have a default constructor, the only way to do that is to have an array of pointers to your class:
aaa** pArray;
...
...
pArray = new aaa*[5];
And then loop through your array and create all the classes:
for (int i=0;i<5;i++)
pArray[i] = new aaa(Value);
Of course, you will need to delete all these instances AND the array.
|
|
|
|
|
So there is no shortcut here.
Thanks
|
|
|
|
|
If a statically-allocated array is acceptable, you can do:
aaa stuff[] = { aaa(2), aaa(2), aaa(2), aaa(2), aaa(2) };
|
|
|
|
|
Hi,
I am using IADS component to query about the user information from a local machine.
Sometimes, When i call ADsGetObject method, it takes more time to query about the user. But some times it happens quick.
I am querying about an user who is created in the local machine.
What is the reason for this? How can i solve this problem.
Any help would be very much appreciated.
Thanks.
Selva
|
|
|
|
|
Hi,
I want to write some application that looking some file name ( "file.exe" or *.exe ) on the entire disk.
Can some one help me ?
|
|
|
|
|
Some please can help me with this one ?
|
|
|
|
|
Hi,
There are two APIs for searching a folder
FindFirstFile & FindNextFile
or there is an MFC Class CFileFind, which is almost like a wrapper to above mentioned APIs. you can go through the documents of these APIs.
bye
P.Somasundaram
|
|
|
|
|
|
You can use of FindFirstFile/FindNextFile I was working with them it easy if you declare their on a thread is good.
|
|
|
|
|
can any body help me??
LRESULT CALLBACK WndProc(HWND hwnd, UINT Message, WPARAM wParam, LPARAM lParam)
i'm trying to convert this c++ code into vb 6.0 can i?, any recommendation for the message sending function i should use in vb?
thx
|
|
|
|
|
having problems with "unbolded" text ??
moreover, if you needed help on VB specific, you'd better ask the VB forum (unless you have a specific C/C++ question ?)...
|
|
|
|
|
That's a mighty BOLD question for a C++ forum
|
|
|
|
|
Hi !!!
I am initialize text and retriving it on dialog box..My code is like..
CDialog::OnInitDialog();
m_ExchListbox.AddString(_T("Exchanger-Double end"));
m_ExchListbox.AddString(_T("Exchanger-Single end"));
m_ExchListbox.AddString(_T("Exchanger-Double end kettle"));
m_ExchListbox.AddString(_T("Exchanger-Single end kettle"));
m_ExchListbox.AddString(_T("Exchanger-Super"));
m_ExchListbox.AddString(_T("Exchanger-Process Flow"));
m_ExchListbox.SetCurSel(0);
n out put of the dialog box is not same as what i declred..ie the out put is like..
Exchanger-Double end
Exchanger-Double end kettle
Exchanger-Process Flow
Exchanger-Super
Exchanger-Single end
Exchanger-Single end kettle
ie i want out put as same as i declred.. ie first should be Exchanger-Double end and last should be Exchanger-Process Flow..I dont want alphabetically character out put..
Thanking you
Shah Satish
Shah Satish
|
|
|
|
|
In the dialog editor, right-click on your listbox and search in the settings. There should be an option to sort the list. Uncheck the check box 'Sort'.
|
|
|
|
|
|
Mr satish,
I already told you that when you have to post code, you have to use the <pre></pre> tags around your pieces of code !
please edit your message consequently
ps: edit means reuse the same message and modifying it, without reposting a new message (have you noticed the little [Modify] link at the bottom of your post ?).
as we are on a forum, it also implies that you share with us on the boards, instead of mailing me your modifications...
|
|
|
|
|
Sorry dear..I forgot it..
Shah
|
|
|
|
|
ListBox and ComboBox has a option on the property window that is sort you can set it to true or false
|
|
|
|
|
Good day to you all!
I created an application having a spin control(vertical scrollbar) attached to an edit box. I needed the application to increment/decrement by 0.01 everytime the scrollbar is pressed. Later on I found out that the default increment is set to 1. What should I do so that the increment would be set to 0.01 and also the display in the edit box having two decimal places?
Thank you very much for the help and time!
|
|
|
|
|
Huh?
I've never seen a spin control or scrollbar implementation that used floating point.
Why not set the range to range*100 and anytime you display the position use position/100 ?
Mark
|
|
|
|