"r+"
Opens for both reading and writing. (The file must exist.)
"w+"
Opens an empty file for both reading and writing. If the given file exists, its contents are destroyed.
If your file already exists,try using r+
"r+"
Opens for both reading and writing. (The file must exist.)
"w+"
Opens an empty file for both reading and writing. If the given file exists, its contents are destroyed.
If your file already exists,try using r+
From MSDN:
When a file is opened with the "a" or "a+" access type, all write
operations occur at the end of the file. The file pointer can be
repositioned using fseek or rewind but is always moved back to the end of
the file before any write operation is carried out. Thus, existing data
cannot be overwritten.
When the "r+", "w+", or "a+" access type is specified, both reading and
writing are allowed (the file is said to be open for “update”). However,
when you switch between reading and writing, there must be an intervening
fflush, fsetpos, fseek, or rewind operation. The current position can be
specified for the fsetpos or fseek operation, if desired.
So instead of using append mode try to use r+ it is for both reading and writing. Hope this helps. -- modified at 0:31 Monday 18th December, 2006
Just see here http://bobmoore.mvps.org/Win32/framed_tip064.htm[^] Hope this helps
In WM_CTLCOLOR message handler set background mode as transparent and return a null brush. This will make the background colour of the controls same as background colour of your dialog
Right click on the tool bar and check on the option controls to get the controls palette
See this www.devguy.com/fp/Tips/COM/bstr.htm[^] Hope this will help
Thank you very much for your reply
hi , what is the meaning of #pragma pack ? From MSDN I came to know that it specifies the packing alignment for structure and union members . But what is meant by packing alignment ? Can you please tell me. Thanks in advance
Are you using VS2003 or vs2005?? #include should be in the first line of all include statements. Just check this.
see this article on checksum algorithm .This may help [http://www.flounder.com/checksum.htm](<a href=)[^]" -- modified at 0:35 Friday 21st July, 2006
hi Try by adding #include Hope this will help
___________ |tab1|tab2| |============| |****color*****| |****here***** | |=============| -- modified at 0:45 Thursday 20th July, 2006
|------| |----------------------| | color here | | | |----------------------| I want the tab ctrl to look like this. How can I do it:confused:
In the tabcontrol I have a button which is associated with tab1 . Now I want to change the background color of that button. How can I achieve this?
how can we change color inside tabcontrol
as i use three tabs now when i click on one color changed where i put code for this or what function i have to use If you want to change the color handle the OnSelChange message handler void Ctabeg::OnSelchangeTab1(NMHDR* pNMHDR, LRESULT* pResult) { // TODO: Add your control notification handler code here *pResult = 0; } -- modified at 7:06 Tuesday 18th July, 2006
Hai can any one pls tell what is ShellExecute command ? and when do we use it? Thanks in advance:)
hi, I want to know how do we use BSTR and VARIANT .Can any one please tell where to find the information about these? Thank You
Thank you very much:)
BOOL CBmDialog::OnInitDialog() { CDialog::OnInitDialog(); CImageList list; list.Create(16, 16, ILC_COLOR8, 0, 4); CBitmap bm; bm.LoadBitmap(IDB_BITMAP1); list.Add(&bm, RGB(0, 0, 0)); m_tree1.SetImageList(&list,TVSIL_NORMAL); m_tree1.InsertItem("Image1"); m_tree1.InsertItem("Image2"); HTREEITEM h1,h2; h2=m_tree1.GetNextItem(h1,TVGN_FIRSTVISIBLE); m_tree1.SetItemImage(h2,0,0); return TRUE; }