|
DavidCrow wrote: Your document class has methods for retrieving that.
Yeah, I think they still hide that information in the documentation.
led mike
|
|
|
|
|
may you speak clearly about which you reply to me,please .Thanks
|
|
|
|
|
From your document class(es), you can call CDocument::GetPathName() to get the full pathname.
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
After I click button "open" to choose file ,the event or function where I will process to get file path,what is it's name? .Thanks
|
|
|
|
|
|
Override the CDocument::OnOpenDocument(LPCTSTR lpszPathName) function. The arguement contains the File Name which is selected in Open dialog
|
|
|
|
|
Hi friends,
I want to develop one business (back end exe to do functional computations and to get/store data into Oracle) application which i can develop either in Pro*C/C++ or C#.
Which language (Pro*C/C++ or C#) shall i chose ??? and why ???
which application will be more faster ?? and why ???
xyz
|
|
|
|
|
Amit4u wrote: Which language (Pro*C/C++ or C#) shall i chose ??? and why ???
Honestly, nobody cares which language you use. Choose the one which you know best. Both languages have good and bad aspects about them.
Amit4u wrote: which application will be more faster ?? and why ???
Generally speaking C++ generates slightly faster machine code, however with an Oracle DB application this really doesn't matter.
Best Wishes,
-David Delaune
|
|
|
|
|
Which language you know better ?
|
|
|
|
|
A Senior Software Developer should be able to evaluate C++ and C#.
|
|
|
|
|
I have a VS2005 (WinXP) project that compiles perfectly with zero warnings or errors that i recently migrated to VS2008 (Vista), and on initial compile i got these three errors:
C:\Program Files\Microsoft SDKs\Windows\v6.0A\include\netioapi.h(155) : error C2146: syntax error : missing ';' before identifier 'PhysicalMediumType'
C:\Program Files\Microsoft SDKs\Windows\v6.0A\include\netioapi.h(155) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
C:\Program Files\Microsoft SDKs\Windows\v6.0A\include\netioapi.h(155) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
And i can't figure out what is causing it. I know it's related to network I/O, but not sure what inparticular. Anyone have any suggestions?
Thanks!
|
|
|
|
|
You need to #include
ntddndis.h
or
netioapi.h
Best Wishes,
-David Delaune
|
|
|
|
|
You'll need to get your header files in order.
At the line the errors occur, the compiler does not recognize the "PhysicalMediumType"
type. You need to examine the header files (including nesed ones) above that line to
find out why.
maybe some info here will help[^]
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
hi
I made a listview control with LVS_REPORT style .......
My task is when i select any item from the listview control and delete it....the focus should go on to the next item......not only focus but next item should be selected......
Thanx in advance
AbidBhat
|
|
|
|
|
Have you looked into the LVM_SETITEM and/or LVM_SETITEMSTATE messages?
"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
|
|
|
|
|
Hi all,
I am writing a multi-threaded program that runs multiple Ftp clients with different transfer types to connect to different ftp servers. The general sequence of each session is:
CInternetSession::CInternetSession ();
CInternetSession::GetFtpConnection ();
.....
Do all kinds of weird and wonderfull things like get, put, pwd etc.
.....
CFtoConnection::Close ();
delete m_FtpConnection;
CInternetSession::Close ();
delete m_Session;
Basically it all works as expected. The only problem is that the ftp server's log always ends with:
0325 15:05:12 (00000984) 172.29.9.67 connection aborted
0325 15:05:12 (00000984) 172.29.9.67 connection closed
and I don't like the "connection aborted" part, since my clients will probably come back to me asking what the hell is going on here!!!!
It does not matter if I remove the close statements or the delete statements. Only when I remove the whole close and delete part, will I not get the aborted message. I then however also not get the "connection closed", so that in a next cycle the ftp server's log show things like:
0325 14:24:20 (00000fa8) 172.29.9.67 connection reset
0325 14:24:20 (00000fa8) 172.29.9.67 connection closed
When I use the standard window ftp manually and do something there, then I see a log like:
0325 14:52:05 (00001084) NBK0188.cew.centric.lan D(0) 172.29.9.67 user1 QUIT
0325 14:52:05 (00001084) NBK0188.cew.centric.lan S(0) 172.29.9.67 user1 logoff R D P
0325 14:52:05 (00001084) 172.29.9.67 connection closed
0325 14:59:38 (000017a8) 172.29.9.67:2235 connected to 172.29.9.67:21
The quit probably coming from the "bye" command, however I do not see any equivalent in the CFtpConnection or CInternetSession classes.
Does anyone have any bright ideas on the subject? Would be greatly apreciated!
Thanks in advance,
William
|
|
|
|
|
William Engberts wrote: The quit probably coming from the "bye" command, however I do not see any equivalent in the CFtpConnection or CInternetSession classes.
You are kidding right?[^]
led mike
|
|
|
|
|
Sorry, I wish I were, but alas there is no "Quit" routine. There is a close which I obviously use, but that one results in the "Connection aborted" line in the ftp server's trace (although I am not sure weather it is the connection's close of the session's close)
Regards,
William
|
|
|
|
|
Um William, did you even look at the link in my post? It's to the documentation for the Command(...) method so you can send a bye command to the server.
led mike
|
|
|
|
|
Mike,
Sorry, I missed the link. It however turns out that, since I am working with Studio 6, the CFtpConnection does not (yet) know the Command method. The article however refers to the separate FtpCommand instruction, and that indeed does the trick and solves my problem. Thanks a lot!!
William
|
|
|
|
|
Glad you got a solution. In future posts include that information about VC6 up front. Most people are not going to know you are using it unless you tell them.
led mike
|
|
|
|
|
First let me say that I am not a CInternetSession expert, simply because I generally migrate to the lower levels of development. However with that being said I can make a guess to what is happening based on the error message you have posted.
You see, when you attempt to open a connection... a three way handshake takes place. Here is a fairly good visual explanation:
http://www.youtube.com/watch?v=z40w3G8szK0[^]
And when you close the connection you must also wait for a handshake sequence to complete. Unfortunately I could not find a video for this. Maybe this URL will suffice:
http://www.freesoft.org/CIE/Course/Section4/11.htm[^]
Here is Microsofts detailed explanation on the whole thing.
http://support.microsoft.com/kb/172983[^]
In laymens terms... when you close() a connection. What is happening is that a message called FIN is sent to the other side and your client goes into a FIN_WAIT state. At this point it is waiting for the other side to respond. Unfortunately with your code:
CInternetSession::Close ();
delete m_Session;
You are probably deleting the object before it has completed the connection termination handshake.
I believe you need to implement a status callback:
http://msdn2.microsoft.com/en-us/library/73cf84cs(VS.80).aspx[^]
And inside OnStatusCallback() you need to wait for INTERNET_STATUS_CONNECTION_CLOSED status.
http://msdn2.microsoft.com/en-us/library/4bwy8hw5.aspx[^]
Best Wishes,
-David Delaune
|
|
|
|
|
I have writen code as
BOOL bResult = fileFind.FindFile(strFilePath);
if(bResult)
{
bResult = fileFind.FindNextFile();
CTime createTime;
CTime modTime;
fileFind.GetCreationTime(createTime);
fileFind.GetLastWriteTime(modTime);
CString strCreateTime = createTime.Format("%H:%M:%S, %A, %B, %d, %Y");
CString strModifyTime = modTime.Format("%H:%M:%S, %A, %B, %d, %Y");
}
but I am getting wrong values as
Thursday, January, 01, 1970
Please help me to solve this problem
|
|
|
|
|
It sounds like you're unable to even get these values. I bet the CTime int values is 0.
What exactly do you mean by "remote files"?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~<br />
Peter Weyzen<br />
Staff Engineer<br />
<a href="http://www.soonr.com">SoonR Inc -- PC Power delivered to your phone</a>
|
|
|
|
|
Hi Dudes am developing NDIS driver can any one guide me with step by step development of NDIS DRIVER. in "C" on winCE platform. As am a freshier i dont know how to develop ndis driver.
THANKS IN ADVANCE.
|
|
|
|