When I write to memory to be displayed in window then call UpdateWindow it only updates the first 12K. Is there a way to extend the update? I would like 32K updated.
Posted on 2003-11-24 01:40:57 by mrgone
Not sure what you're getting at here. UpdateWindow causes a WM_PAINT message to be sent to your window with the current update region. It has nothing to do with transferring data to or from the window. To repaint the entire window use InvalidateRect then send UpdateWindow. It is a graphics function not a data or memory function.
Posted on 2003-11-24 01:45:26 by donkey
Seems like it's speaking of view region of window ie:

"An application invalidates a portion of a window and sets the update region by using the InvalidateRect or InvalidateRgn function. These functions add the specified rectangle or region (given in client coordinates) to the update region, combining the rectangle or region with anything Windows or the application may have previously added to the update region."

What I'm doing is when I first open a file it contains 32K bytes of data. I open it with CreateFile than FileMapping and MapVeiwOfFile gives me a handle to SendMessage to my edit window. I can scroll the window down to veiw the entire 32K contents. Now I write 32K bytes of new data to file handle then UpdateWindow and I only see upper 12k changed.
Posted on 2003-11-24 11:29:14 by mrgone
Yes, UpdateWindow only affects the viewable portion of a window, it is a graphics function that is part of the GDI. It has nothing to do with the contents of any control, it just instructs Windows to repaint the graphic on the screen. For your problem I would have to see some code but it is definitely not related to UpdateWindow.
Posted on 2003-11-24 11:55:16 by donkey
Thank you Donkey for your help. You led me in good directions for debugging problem. UpdateWindow does update the entireview of the file. I found that starting with 4th 4K block of memory the address was changed.
Posted on 2003-11-24 13:38:28 by mrgone