It's best asking in the Windows Programming section for this.
Basically, it tells Windows which window to draw/display. It sends a WM_PAINT message to the window's procedure( which jumps in front of the message queue ). The single argument is the handle to the window you wish to draw.
ShowWindow( ) Determines how the window shall be shown. ( See the table for window display options: http://msdn.microsoft.com/en-us/library/ms633548(v=vs.85).aspx )
UpdateWindow( ) updates the client area of the given window( the argument is the handle to the window you want to update ). See here for information from Microsoft: http://msdn.microsoft.com/en-us/library/ms915501.aspx
Ive just been reading and ive come up with a new idea of what these two do:
ShowWindow() sets the "show-state". This function also DISPLAYS the window as we are setting the show state to a state which is displayed, so the window IS displayed because of this function.
UpdateWindow() does what it says on the tin. It updates the client area to make sure things such as strings and boxs are visible when the window is first created. Another thing which tells me that the updatewindow() does NOT display the window is that my application still displays if i remove the updatewindow().
Is this correct?
If so, why do need to make sure things such as strings and boxs are visible when the window is first created, why would they not be visible?
If your static string changed, then you will need to update the client area. If nothing changes then there will be no need to update the client area. However, if you were creating custom elements, then you might have to update the client area. These are my thoughts, however.