|
|
I wrote for you an exmaple and also GetWindowText needs to a parameter for hold values
|
|
|
|
|
harshadha wrote:
TCHAR szMsg[256];
wsprintf(szMsg,_T("hEIGHT: %ld "),m_ce);
So then why are not using CString with your MFC application?
harshadha wrote: MessageBox(szMsg,NULL,MB_OK);
Consider using AfxMessageBox() .
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
Hai,
Thanks a lot to all...
i got the output....
Harshadha
|
|
|
|
|
I hope you got your answer with best way
|
|
|
|
|
Hi,
If iknow the filename and its path i hould be able to open and display that file.if any ideas on how to do it please let me know..
harsha
|
|
|
|
|
Which? Open a file or get path of a file?
|
|
|
|
|
i should be able to open and display the contents to the user ..
harsha
|
|
|
|
|
|
Have you tried the following:
Open File
HANDLE CreateFile(
LPCTSTR lpFileName,
DWORD dwDesiredAccess,
DWORD dwShareMode,
LPSECURITY_ATTRIBUTES lpSecurityAttributes,
DWORD dwCreationDisposition,
DWORD dwFlagsAndAttributes,
HANDLE hTemplateFile
);
Read Contents:
BOOL ReadFile(
HANDLE hFile,
LPVOID lpBuffer,
DWORD nNumberOfBytesToRead,
LPDWORD lpNumberOfBytesRead,
LPOVERLAPPED lpOverlapped
);
Read File[^]
Open File[^]
Regards,
The only programmers that are better than C programmers are those who code in 1's and 0's.....
Programm3r My Blog: ^_^
|
|
|
|
|
i dont want to read or open or create a file.. i want to display a file to the user say when user clicks a button. will this help in that regard ?
harsha
|
|
|
|
|
harsh_2961 wrote: i dont want to read or open or create a file.. i want to display a file to the user say when user clicks a button. will this help in that regard ?
If you want to see file's content you have to open it. There is no other way than opening given file to read it, and if you want to display it's content you have to read it first.
Unless you are talking about viewing file's... name?
|
|
|
|
|
Hope I understood your question
use of a CFileDailog and when he clicks ok button show file name(Is your purpose)
|
|
|
|
|
If its a simple text file using CEditView will do, try creating simple SDI application and choose baseclass as CEditView in last step of app wizard.
|
|
|
|
|
its a ".chm" (Compiled Html file)..
harsha
|
|
|
|
|
|
Have you considered using ShellExecute(..., "open", "file.chm", ...) ?
"Approved Workmen Are Not Ashamed" - 2 Timothy 2:15
"Judge not by the eye but by the heart." - Native American Proverb
|
|
|
|
|
thanks a lot.. its working perfectly
|
|
|
|
|
I use a floodfill function to fill a pie chart, it's ok when i print on display but doesn't works on printer
Is there a other function to fill a ellipse or parts of pie???
thanks
|
|
|
|
|
hi i want to capture the key pressed by the user and have to do the corresponding functions. can anyone tell me such events
Arise Awake Stop Not Till ur Goal is Reached.
|
|
|
|
|
See WM_KEYDOWN and WM_KEYUP
|
|
|
|
|
|
thanks a lot. its very useful. but when i press esc key keeping the focus in editbox the dialog closes. instead of this the tab containig the dialog should be closed what i have to do
Arise Awake Stop Not Till ur Goal is Reached.
|
|
|
|
|
I want to implement a program that would check that a connected device like speaker,webcam,... is properly connected or not.Please reply me as soon as possible.
Thanks & Regards
Pankaj
|
|
|
|
|
Befor I do something like this ..
CString input;<br />
sprintf_s(buf, 16, "%d", input);
I'd like to know whether the input is a number, but how ?
Thanks for a fast answer in advance!
alex
-- modified at 5:18 Thursday 8th March, 2007
|
|
|
|