|
How can I obtain disk's allocation unit in C++?
ARSALAN MALIK
|
|
|
|
|
GetDiskFreeSpace(strPath, &dwSectorsPerCluster, &dwBytesPerSector, &dwFreeClusters, &dwTotalClusters);
DWORD dwClusterSize = dwSectorsPerCluster * dwBytesPerSector; This will not work on volume sizes that are greater than 2GB. For that, I would use ZwQueryInformationFile(..., FileStandardInformation) .
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
|
|
|
|
|
how can i countact to the server from program and copy the data from the server to the program
if any one can help me of this and send me the receurce
i will be thankfull for him/her
Best regards,
|
|
|
|
|
What server?, which technology?, what type of data?
"After all it's just text at the end of the day. - Colin Davies
"For example, when a VB programmer comes to my house, they may say 'does your pool need cleaning, sir ?' " - Christian Graus
|
|
|
|
|
I am working on a function that displays all related names when the user entering name. For now, I only can search the exact entried name! However, since the users always typing very fast and more often enter name with incorrectly (ie: Joh instead of John, Cater instead of Carter ...)
Is there any existed codes to correct for them?
Thanks for any help
|
|
|
|
|
A very easy and simple method that I have used is to use the Soundex algorithm to match words that may be spelt incorrectly, but is phonetically similar.
Have a search for this in Google and you will get a few good sites. Even SQL Server's T-SQL have a Soundex function!
I Dream of Absolute Zero
|
|
|
|
|
Hello All Programmer,
I am facing a little problem,hope i found Solution here.
i have make Bold a particular Item in TreeCtrl. how to accomplish that.
Thanks
-----------------------------
"I Think It Will Help"
-----------------------------
Alok Gupta
visit me at http://www.thisisalok.tk
|
|
|
|
|
go via the tree item not the text itself:
use TVIS_BOLD and set the tree item to this attribute
(I can't remember how though but you can look it up.)
good luck.
"If I don't see you in this world, I'll see you in the next one... and don't be late." ~ Jimi Hendrix
|
|
|
|
|
First of all use GetSelectedItem() which will return u the selected item and then create the TVITEM struct specifying the mask value as TVIF_TEXT, and hItem as the selected item and state as TVIS_BOLD.
This will bold selected item's text even at the runtime.
Work Hard and Bit of Luck is Key to Success
|
|
|
|
|
Thanks a Lot every body
-----------------------------
"I Think It Will Help"
-----------------------------
Alok Gupta
visit me at http://www.thisisalok.tk
|
|
|
|
|
Hello All,
I have an application in vc++, where on a ("Synchronize")button click, some functions are executed. Now i have to(Schedule)set a particular time on a given day(weekly once) at which the same functions should get execute, which are executed when i click the button("Synchronize").
Please send me the code if possible.
Regards,
Prax.
|
|
|
|
|
Use a timer (see the "OnTimer" event) and use CTime::GetCurrentTime.
Elaine
The tigress is here
|
|
|
|
|
It sounds like you are wanting to create a scheduled task. If so, check out the ITaskScheduler and related interfaces.
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow
|
|
|
|
|
Hi,
I have created a compiled help file outside our app. Now I would like to call this chm file by the press of a button (test project) or via a menu.
How can you do this?
Do you need to include this in your project or can you specify the path? (I prefer option 2).
tnx 4 your help!
|
|
|
|
|
You can always specify the file path if you want to.
See the documentation for HtmlHelp function.
This topic in MSDN will get you started - "HTML Help Tools and Features"
|
|
|
|
|
Hello Friends,
I am using CListView in which I am displaying some images, but whenever I am resizing it, then It is displaying the Horizontal Scroll bar which Should not be displayed.
I had tried ShowScrollBar(SB_FALSE) in the OnSize() member function also. but it is displaying.
I don't want this horizontal scroll bar to be present.
Please Help me.
Thank you in advance.
Neelesh J Jain.
|
|
|
|
|
|
I want to display multiline text in a CStatic text control. How can I do this? /n does not work!
|
|
|
|
|
Try \n
|
|
|
|
|
Sorry. I meant \n. I tried \n and \r and they did not work.
I am trying to display some text on the screen and need to show it in a window that sizes itself to the text but I will need to limit the width to the screen width so I may need newlines in the text.
|
|
|
|
|
Use "\n\r"
ARSALAN MALIK
|
|
|
|
|
I have a generic class named CMainHandler. I want to be sure if it was created before. From debugger window i see its value is 0xcccccccc but i can do something like this:
if(m_mh != 0xcccccccc)
delete m_mh;
else
m_mh = new CMainHandler(MODEUDP);
m_mh is CMainHandler instance
Thanks in advance
|
|
|
|
|
I dont think it's good idea...Y dont u initiaze it to NULL very first?
|
|
|
|
|
In the constructor of the class that uses this class, set it to NULL. So you can check if the value exist or not...
|
|
|
|
|