|
Thank you for your reply.
I had already gone thru this article. Anything else I could know more about my query.
poojaaa
|
|
|
|
|
Ok, boys, I think it's time to give an answer to an ancestral annoying question.
How do we (we = programmers, professional or amateur) call the parts which a FQP (fully qualified path)
is made of?
I mean, if we have a DOS-like path:
c:\dir1\dir2\file.ext
what are the meaningful strings we have to name?
fileName = "file.ext" ? or
fileName = "file"
fileExtension = "ext" ? And if so, how should we call "file.ext"?
Which name is "c:\dir1\dir2" usually addressed with?
In partial paths, should I use the ending slash ("c:\dir1\") or not (c:\dir1) ?
Where can I find standard naming conventions?
And what is the best way of handling file names? Windows API, or a more convenient code
has been written, maybe here in codeproject?
Thank ya guys...
|
|
|
|
|
Do you want to write an article about?
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
|
|
|
|
|
No...
I'm looking for answers, cause I don't have any...
Anyway, we could start a more involved discussion if there is need to shed light on this subject.
What I wonder is if there is a common convention shared by almost every programmer;
win API functions, like GetLongPathName or GetShortPathName and so on
seem to be very specific, but who really knows?
For instance, MS calls "c:\dir1\dir2\" a PathName, and "\\pcName\dir1\" as well.
But I saw someone else calling it rootPath, using the "Name" word to distinguish
between [Name of a file without extension] = FileName and [extension of a file] = FileExtension ;
in this case the [Name of a afile with extension] was called FullFileName (or FileFullName).
That's a mess!!
There must be some "sacred rules" we have to keep to.
Otherwise, we'll write them...
|
|
|
|
|
hi can anyone help me with being able to generate permutations using numbers..a c++ code. thanks
|
|
|
|
|
Does this[^] help you?
Nobody can give you wiser advice than yourself. - Cicero
.·´¯`·->Rajesh<-·´¯`·.
Codeproject.com: Visual C++ MVP
|
|
|
|
|
|
|
vikrams wrote: Now Is there any system timout I can configure for the same?
Why?
"Normal is getting dressed in clothes that you buy for work and driving through traffic in a car that you are still paying for, in order to get to the job you need to pay for the clothes and the car and the house you leave vacant all day so you can afford to live in it." - Ellen Goodman
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
The question raised here due to the following scenario
1) I have filer where data is stored
2) I Copy data from this filer share to my local machine
3) When I try to copy a file, Filer goes for Antivirus scanning for it
Note: This scanning time varies depends upon file size and complexity
4) Mean time My copy operation waits and evently timeouts in some cases
Now I want to know this timeout value.
|
|
|
|
|
Ok, is it failing when copied via Windows itself (e.g., Explorer), or from within your code?
"Normal is getting dressed in clothes that you buy for work and driving through traffic in a car that you are still paying for, in order to get to the job you need to pay for the clothes and the car and the house you leave vacant all day so you can afford to live in it." - Ellen Goodman
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
Failing form windows side only.
|
|
|
|
|
Well, if Windows is not accounting for such a failure, I'm not sure what you can do about it.
"Normal is getting dressed in clothes that you buy for work and driving through traffic in a car that you are still paying for, in order to get to the job you need to pay for the clothes and the car and the house you leave vacant all day so you can afford to live in it." - Ellen Goodman
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
The function readch() reads a character. But what do I use to "read a character, but do not wait for him to type a character?" How can the program find if there is a character waiting in the standard-input buffer?
|
|
|
|
|
|
*?#! You were faster.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
|
|
|
|
|
|
This one [^] looks promising.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
|
|
|
|
|
Hello everyone,
Suppose I have a component (class) CX implements IUnknown interface, and I have retrieved a pointer of CX by IUnknown pointer (IUnknown*), that is.
IUnknown* pCX;
QueryInterface (IID_IUnknown, &pCX);
delete pCX;
Even if I declare the component CX's destructor as virtual, if I delete through IUnknown pointer to "release" the object, there is still potential memory and resource leak, because in IUnknown interface, destructor is the compiler provided default one, which is non-virtual and public, right?
thanks in advance,
George
|
|
|
|
|
NEVER do that. COM has its own mechanism to perform cleanup, you must not break the toy.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
|
|
|
|
|
Thanks CPallini,
I should ask the question in another way. Is the default destructor virtual or not?
regards,
George
|
|
|
|
|
Default destructor is not virtual.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
|
|
|
|
|
Thanks CPallini,
Question answered.
regards,
George
|
|
|
|
|
George_George wrote: because in IUnknown interface, destructor is the compiler provided default one, which is non-virtual and public, right?
yes, But why don't you use Release() that's the COM needs.
|
|
|
|
|
Thanks Rajkumar,
I should ask the question in another way. The default destructor is non-virtual and public, right?
regards,
George
|
|
|
|