Click here to Skip to main content
16,014,591 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralTHanks!!!!Great info! Pin
ns11-Mar-03 1:51
ns11-Mar-03 1:51 
GeneralContextMenu with CTabCtrl Pin
AnTri7-Mar-03 4:11
AnTri7-Mar-03 4:11 
GeneralRe: ContextMenu with CTabCtrl Pin
Ernest Laurentin7-Mar-03 5:20
Ernest Laurentin7-Mar-03 5:20 
GeneralRe: ContextMenu with CTabCtrl Pin
Brian Shifrin7-Mar-03 6:27
Brian Shifrin7-Mar-03 6:27 
Generalreactivate the view in an SDI app Pin
luedi7-Mar-03 4:06
luedi7-Mar-03 4:06 
GeneralRe: reactivate the view in an SDI app Pin
Brian Shifrin7-Mar-03 6:38
Brian Shifrin7-Mar-03 6:38 
GeneralRe: reactivate the view in an SDI app Pin
luedi7-Mar-03 12:08
luedi7-Mar-03 12:08 
GeneralCFile Write Pin
ns7-Mar-03 3:28
ns7-Mar-03 3:28 
This is what I did and it doesnt crash but is it safe etc? I am going to put this in my OnSize to find out what the width and height of the window are so I can pinpoiint the exact dimensions when the dlg looks best. Then I'll make onsize restrict it to these minimum dimensions when its resized. I think I'l get cx, cy which are height and width, so I dont need CRect, but I was wondering if there is a more direct way of outputting two simple integers rather than formatting them into a string...
thanks

void CTestsView::OnButtonwrite() 
{
	CFile cFile("E://testWrite.txt", CFile::modeCreate|CFile::modeWrite);

CRect cRect;

GetClientRect(&cRect);

int width = cRect.Width();

int height = cRect.Height();

CString pos;

pos.Format("widthe %d	height %d", width, height);

int bufLength = pos.GetLength() + 1;

LPCTSTR lP = pos.GetBuffer( bufLength);


cFile.Write(lP, bufLength);

cFile.Close();

pos.ReleaseBuffer();


}

GeneralRe: CFile Write Pin
Chris Losinger7-Mar-03 3:39
professionalChris Losinger7-Mar-03 3:39 
GeneralThanks and another ques about OnSize Pin
ns7-Mar-03 3:45
ns7-Mar-03 3:45 
GeneralRe: Thanks and another ques about OnSize Pin
ns7-Mar-03 4:16
ns7-Mar-03 4:16 
GeneralEmbedding Internet Explorer (Win32, no MFC) Pin
Dominik Reichl7-Mar-03 2:43
Dominik Reichl7-Mar-03 2:43 
GeneralRe: Embedding Internet Explorer (Win32, no MFC) Pin
Stefan Pedersen7-Mar-03 3:40
Stefan Pedersen7-Mar-03 3:40 
GeneralCreating memory bitmap Pin
Anonymous7-Mar-03 2:13
Anonymous7-Mar-03 2:13 
GeneralRe: Creating memory bitmap Pin
Joel Lucsy7-Mar-03 2:36
Joel Lucsy7-Mar-03 2:36 
GeneralRe: Creating memory bitmap Pin
djordj7-Mar-03 2:40
djordj7-Mar-03 2:40 
GeneralRe: Creating memory bitmap Pin
Scott H. Settlemier7-Mar-03 4:09
Scott H. Settlemier7-Mar-03 4:09 
GeneralRe: Creating memory bitmap Pin
djordj7-Mar-03 4:14
djordj7-Mar-03 4:14 
GeneralRe: Creating memory bitmap Pin
Scott H. Settlemier7-Mar-03 4:42
Scott H. Settlemier7-Mar-03 4:42 
GeneralInstalling VC7.0 Pin
Dave_7-Mar-03 1:52
Dave_7-Mar-03 1:52 
GeneralRe: Installing VC7.0 Pin
RobJones7-Mar-03 8:13
RobJones7-Mar-03 8:13 
GeneralRe: Installing VC7.0 Pin
Dave_7-Mar-03 8:19
Dave_7-Mar-03 8:19 
GeneralVC6 Debugger Problem Pin
Paul Farry7-Mar-03 0:34
professionalPaul Farry7-Mar-03 0:34 
GeneralRe: VC6 Debugger Problem Pin
Brian Shifrin7-Mar-03 6:42
Brian Shifrin7-Mar-03 6:42 
GeneralRe: VC6 Debugger Problem Pin
Paul Farry7-Mar-03 10:54
professionalPaul Farry7-Mar-03 10:54 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.