I'm looking for a brief discussion of AFX_MANAGE_STATE(AfxGetStaticModuleState()). When I use this at the entry point to a DLL as stated in the comments generated by AppWizard, I cannot use CWnd or derivatives of CWnd in the DLL created in the application since they are in the applications window map not the DLL's. The debug ASSERTions fail. For example, if I pass a pointer to the status bar of CMainFrame to a DLL exported function, I cannot update the status bar in the DLL function with code like: pBar->SetPaneText(0, "String", FALSE). Is there a proper way to accomplish this that I am not doing?