A problem with popup window

Hi,

I have a weird problem with a popup window in a MDI application. 
I've created a popup window from inside my CView class, using the
following:

  MyCWndDerivedClass *PopupWindow = new MyCWndDerivedClass;

  CRect rectInitialSize(200,200,500,500);

  PopupWindow ->CreateEx(NULL,  NULL, "The Title of the
window",WS_POPUP | WS_CHILD | WS_CAPTION | WS_CLIPSIBLINGS |
WS_THICKFRAME ,rectInitialSize, this, NULL, NULL);

  SegmentWindow->ShowWindow(SW_SHOW); 

The window opened and everything seemed fine, but then I've noticed
that if I switch to another program and then try to switch back to my
program, the program (the desktop, menu and all its windows) wont
maximize - it stays minimized!. The only thing that helps is switching
to it using ALT-TAB (instead of the taskbar), or clicking again twice
on the taskbar (so the program window will "minimize" and "maximize"
again).
  
I Don't know if you understand what I mean but I could really use some
help and would appreciate it alot.

Tnx,
Nadav.
0
nadav (3)
10/7/2003 6:11:38 PM
vc.mfc 33608 articles. 0 followers. Follow

4 Replies
737 Views

Similar Articles

[PageSpeed] 1

>I have a weird problem with a popup window in a MDI application. 
>  PopupWindow ->CreateEx(NULL,  NULL, "The Title of the
>window",WS_POPUP | WS_CHILD |

The documentation says:

"WS_POPUP 
Creates a pop-up window. This style cannot be used with the WS_CHILD
style"

... so try removing WS_CHILD for starters.

Dave
--
MVP VC++ FAQ: http://www.mvps.org/vcfaq
0
davidl (422)
10/8/2003 12:00:54 PM
David Lowndes <davidl@mvps.org> wrote in message news:<e1v7ovk1629tivekc188dujbak1gq86u72@4ax.com>...
> >I have a weird problem with a popup window in a MDI application. 
> >  PopupWindow ->CreateEx(NULL,  NULL, "The Title of the
> >window",WS_POPUP | WS_CHILD |
> 
> The documentation says:
> 
> "WS_POPUP 
> Creates a pop-up window. This style cannot be used with the WS_CHILD
> style"
> 
> .. so try removing WS_CHILD for starters.
> 
> Dave

Hi
The documentation is wrong, WS_POPUP doesnt work without WS_CHILD. And
I've tried about every combination of the WS_ styles that is possible,
and nothing solves my problem...
 
Nadav.
0
nadav (3)
10/9/2003 6:12:48 AM
>> The documentation says:
>> 
>> "WS_POPUP 
>> Creates a pop-up window. This style cannot be used with the WS_CHILD
>> style"
>> 
>> .. so try removing WS_CHILD for starters.
>> 
>The documentation is wrong, WS_POPUP doesnt work without WS_CHILD.

Hmm, really? It's been wrong for a long time then. ;)

Dave
-- 
MVP VC++ FAQ: http://www.mvps.org/vcfaq
0
davidl (422)
10/9/2003 5:46:02 PM
David Lowndes <davidl@mvps.org> wrote in message news:<8k7bovgijp3r867l17egih3qnfd2nlkfpt@4ax.com>...
> >> The documentation says:
> >> 
> >> "WS_POPUP 
> >> Creates a pop-up window. This style cannot be used with the WS_CHILD
> >> style"
> >> 
> >> .. so try removing WS_CHILD for starters.
> >> 
> >The documentation is wrong, WS_POPUP doesnt work without WS_CHILD.
> 
> Hmm, really? It's been wrong for a long time then. ;)
> 
> Dave

Anyone???
0
nadav (3)
10/12/2003 12:02:39 PM
Reply:

Similar Artilces:

Winmail.dat problem with SBS 2003..and yes i have read the other wiinmail posts
Ok, so I have read thru all the winmail.dat posts in this group and the outlook group, problem is most of them are geared towards ex 5.5. Well I have sbs 2003 and I have one user in my entire company that can not send a excell spreadsheet to one recp. without outlook 2003 i converting into a winmail.dat. I have tryed everyhting I can think of. I reinstalled outlook. I have sett all the options to send as plain text globally and for that contact that gets the winmail.dat files. I have been working on this for a while, but I do believe I checked the setting on exchange to allow the user to ch...

Error while opening GP windows from BP
Hi all . I am getting an issue when we click 'Create Journal entries' item in the Financial Back Office Tasks webpart in Business Port4.0. "null-CWTSSession.openCannes:'oWTS' is null or not an object" I done a Terminal Server Setups as per the BP installation Document. Version Details : GP10.0,BP4.0,MOSS 2007 Note : I am getting this even for Administrator Login Regards Sunny Hi Sunny, A simple troublshooting steps: 1. Ensure that you can remotely access the server (where BP is installed) via Remote Desktop Connection (RDP). This will ...

Problems after kb890830 and kb978542 updates
After windows Vista installed kb890830 and kb978542 I noticed 4 problems so far. 1. MSN Service not available, error code: 800706b5. (This happened with previous updates and I fixed the issue by doing a system restore to a previous date.) 2.When I started internet explorer (ver 8.0.6001.18904) I got a message my default search engine was corrupted by another program. 3.I tried the usual system restore and found there were no restore points available 4. I had some unknown problem trying to log into this site. It kept giving a site not available message. I am running windows vis...

Cell Reference Problem with Network
Let's say I have a spreadsheet with two worksheets = SheetA and SheetB. SheetA might reference a cell in SheetB with a formula like =SheetB!A1 But when I move this to the network the reference changes to include the network drive and file name like: ='Z:\FOLDER\[FILE]SheetB!A1 the file may move from my laptop to the network several times and this becomes completely confusion as the reference looks, not within the same spreadsheet which is what I want it to to, but for another file out on the network. How do I explicitly reference a cell within a difference worksheet but alwa...

New entity
when i attach a contact to an account i have an option - to choose an account from the list, or to create a new one. but i dont have this option when i work with two custom entities (1 to many relationships). only to choose from existing when i want a assign a primary entity to a secondary one. is there a workarround? this way makes me press much more buttons in different forms. i have secondary objects already created due to my business proccess, so i need to go to the primary entity, create an object, then to go back, to open a secondary one and to attach the primary one to it. thanks ...

Converting From ADO.Net XML to ADO problem
Using the method described in Microsofts Knowledge Base article http://support.microsoft.com/default.aspx?scid=kb;en-us;316337 to convert an XML file created by a DataSet into an XML file read by ADO. This seems pretty straight forward and the ADO recordset *opens* without error, however it's quite empty. Any attempt to use it (e.g. MoveFirst or RecordCount) causes an E_FAIL error. The translated XML file has lots of data when viewed with a browser. The code is below... DataSet ds = new DataSet(); try { SqlDataAdapter da = new SqlDataAdapter("SELECT * FROM MyTable", SqlCo...

Problems with Crystal Reports
Hi everyone We are currently encountering a problem with Crystal Reports on MSCRM. Launching one takes about 10-15 seconds before data is displayed (even if only 1 record is retrieved). The standard Accounts reports are worse, we get a Timed Out error everytime. We are deploying MSCRM on 2 servers - CRM Server has dual procs and 1GB RAM. Any suggestions are very much appreciated. Thanks in advance. Regards. Hon Having Crystal reports in CRM 1.0 timeout is a known bug. (Happens after you try to retrieve more than about 10K records.) There is a private hotfix. It will also be fi...

Problem with line Chart
I have the following data: Date Value 1/07 700 3/07 550 9/07 600 10/07 550 7/08 500 9/08 700 2/09 750 8/09 600 I would like to create a simple line chart connecting the Value points. Note that the points correspond to random dates (not evenly spaced). How can I create a line chart that has time on the x-axis, (say shown in months) with a line connecting the Value points, which are shown at various locations in time. Soun...

Urgent OWA 2K3 Setup Problem
I am fairly new to Exchange 2003 and IIS so this may be a silly question. I have a single 2003 Domain and Exchange organisation that contains 2 backend servers, one is for staff the other students. The default email policy is set for e.g user@emailaddress1 a second policy is set to user@emailaddress2 which is applied to all users on server2. I have configured OWA on Server1 which works fine but can't access any mailboxes on Server2. This is where I get a little confused! The settings on the default http virtual servers on both servers point to the default email policy but the mo...

OWA problem on front-end server
I'm currently running Exchange 2003 over Windows 2000 SP4 with a front-end server handling all the OWA and SSL. I've foung that any email ending with ..EML as opposed to .EML (note the extra dot) gets a 404 page not found. However if I log into OWA on a backend server the same email with the ..EML opens no problem. If anyone has some insight into this problem I'd be greatly appreciated. Take a look at: 320089 XCCC: The URLScan Utility Does Not Allow You to Open Messages in OWA http://support.microsoft.com/?id=320089 Thanks, Richard Roddy Microsoft Exchange Support This...

Clear Format problem
I am trying to write a macro to clear ALL format in a range of cell. However, I run into a problem. I am using the Selection.ClearFormats command and it works in most cases, but fails when multiple format are applied to the cell. For example if a cell only contains "Hello wonderful world" all in bold than ClearFormats will remove the bold formatting. But if the cell contains "Hello wonderful world" where only "wonderful" is in bold, than ClearFormats does not work and the word "wonderful" remains in bold. Does anyone know how to clea...

Shared Calendar problems
We have created a secondary mailbox which includes a calendar for booking a conference room. If I want to book the room, I arrange a meeting with the room (using a modified calendar form) and a secretary accepts the meeting. It appears that something in my modified form is causing a mistake, as when the appointment is viewed (by anyone) the meeting time changes to the current time and if the person viewing it closes the appointment down they get the option to save the changes - thus updating the calendar and clearly causing a few nightmares with the booking! Any suggestions as to where my form...

Problems with Colour Printing
Hi there, I have a spreadsheet with multiple sheets containing colour formatting (including graphs) that is regularly printed out in colour and greyscale. The problem I have is that when I need to print out several sheets simultaneously I uncheck the "Greyscale" option under print options and have the print job come out in colour. To print multiple selected sheets in colour I need to change the print options for each individual sheet (about 10 in all) to colour (non- greyscale). One strange peculiarity of this is that some of the sheets will not need to be "Unchecked"...

Problem with "New Message to Contact"
I've created an Exchange public folder, which contains 50 contact folders. (This allows us to allow different regions access to just their customers.) I want to send a mail message to a group of customers. So I highlight all the contacts with e-mail addresses, go to the Actions menu and choose "New Message to Contact". I get the following error: "You do not have the permission to send the message on behalf of the specified user." I am the owner of the folder! This method works in a different Exchange public folder, just not in our customer folders. It does...

Data validation causing problems when using a data form in Excel 2
I have an Excel 2007 workbook that includes data validation set on a number of cells. When using a data form to enter data and I enter an invalid value on the form field corresponding to one of those cells I receive the validation error dialogue that prompts me to retry. I enter the correct data into that field on the form then close the form. My worksheet only has the data relating to the corrected field entered. All other data entered via the form is not entered onto the worksheet. Is this a bug in Excel 2007? I previously was using Excel 2002 and found that when using a ...

Windows Resizing
Hello, I have a DLL app that contains a dialog and inside a dialog there is a CWebBrowser2 control. I am trying to make CWebBrowser2 get maximized together with the Dialog so when a user maximizes dialog CWebBroswer2's width and height are changed with Dialog's width and height. Does anybody know how to make it work? Thank you, Victor. Catch the WM_SIZE message in your dialog (This message gets called when the user is changing the size of the dialog box) and change the size of the control accordingly. AliR. "victorsk" <victorsk@discussions.microsoft.com> wrot...

Learning C# properties from O'Relly book
In a simple time class, int hour /* public int Hour // This works { get { return hour; } set { hour = value; } } */ // Automatic property? public int Hour { get; set; } // This doesn't set hour ! // Client code Time t = new Time(now); int theHour = t.Hour; Console.WriteLine("\nRetrieved the hour: {0}\n", theHour); theHour++; Console.WriteLine("\nUpdated the hour: {0}\n", theHour); Michael Hanson wrote: > [...] > // Automatic property? > public int Hour { get; set; } // This doesn't set hour ! W...

Outlook 2003 Smart Tag Integration with MSN Messenger 7.0 vs Windows Messenger
Is there a way to use MSN Messenger 7.0 with the Outlook 2003 Smart Tag integration instead of useing Windows Messenger? Seems really silly that Outlook 2003 would use Windows Messenger a older product with less features then use MSN Messenger which is a newer product with more features. I've search all over the net for this answer and all I find is others asking the same questions but never and answer. -- Regards, Chris ...

Nz & Dlookup problem
I keep getting the #Error in my text box. What is wrong with this syntax? =Nz(DLookUp("[Affiliation]","tblFaculty","[FacID] =" & [Outside]),"") Check the Dlookup 1. Check if the name are correct 2. If FacID field is a text field and not numeric, add a single quote before and after the criteria DLookUp("[Affiliation]","tblFaculty","[FacID] ='" & [Outside] & "'") 3. In any case, try running the dlookup without the text box using the Immidate windows (press Ctrl+g) and then type ?DLookUp(&qu...

Fore Color Field Problem
Hi I have problem with fields from the main form that thier value is from a subform query subtotal result - after the main form is open I changed the fore color to red and I saw that with the debugger but when I open the main form I see that the fore color of the fields is black again. I don't know what is the cause for changing of the fields for color from red to black again. Can you please help me with that? Thanks On May 5, 2:31 pm, hmadyson <hmady...@discussions.microsoft.com> wrote: > I think that this is going to be tricky to solve without seeing your > application, ...

Rootkit author offer fix for MS patch problem
"According to security vendor Prevx, the authors of the rootkit which was the cause of a large number of unbootable systems which applied the MS10-015 patch issued last week have issued a patch to fix the incompatibility." http://blogs.pcmag.com/securitywatch/2010/02/rootkit_authors_issue_patch_fo.php All your roots belong to us... HeyBub wrote: > "According to security vendor Prevx, the authors of the rootkit which > was the cause of a large number of unbootable systems which applied > the MS10-015 patch issued last week have issued a patch to fix t...

Excel 2002 -> Problem with calculated fields in Pivottable
Hi, I have created a Pivot table and use a calculated field. Now I want to eleminate the "0" of this calculated field. Normally I would drag the field into the page area. But this does not work the normal way. I don't want to change the original database. Does anyone know the possibilty of using a calculated field in the page area of a pivot table? Or another way to avoid the zeros ? Thanks foru your help ...

multiple windows creation without
Hi, Does anybody know how to create multiple windows without having a Winproc for each of them? My coworker and me are thinking of creating a debugwindow class(to display various algorithm related waveform/images), so that the user can create one or a few of such objects to show some intermidate results at their own choice. I knew normally every window has a winproc defined. Is it possible to create multiple windows without writing each one a winproc? Which will be the my way to solve my problems? >Does anybody know how to create multiple windows without having a Winproc >for...

Printing Problem #2
In preview mode, my worksheet looks very nice and evenly arranged on A4 size with all the top, bottom, left and right margins all balanced. However, when printed, the hard copies look very much different. The left margin is much much wider, and there is a large blank space between the header and the beginning of the contents. I have checked the page setup of Excel and also the printer settings in windows (XP Professional) and they look in good order to me. Anyone can help? Thanks a million. Check the paper size too. Peter "Yew Keong" <yk@recsam.edu.my> wrote in mes...

windows messinger
can not sign into messinger. keep getting error code 8e5e03fe -- Gary In news:A5FAF95C-5DE6-42DD-A891-8EA9623C7255@microsoft.com, yrag <yrag@discussions.microsoft.com> typed: > can not sign into messinger. keep getting error code 8e5e03fe http://lmgtfy.com/?q=windows+messenger+error+codes ...