Print Page | Close Window

m_bShowNonActiveInPlaceButton

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Report Control
Forum Description: Topics Related to Codejock Report Control
URL: http://forum.codejock.com/forum_posts.asp?TID=15588
Printed Date: 22 December 2024 at 3:41am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: m_bShowNonActiveInPlaceButton
Posted By: larryp
Subject: m_bShowNonActiveInPlaceButton
Date Posted: 11 November 2009 at 10:07am
I have a report control where some rows have a combobox.  I want the combobox to always be drawn.  Like the property grid allows.
 
So, I do the following:
  1. Set the flag m_bShowNonActiveInPlaceButton to TRUE in the paint manager
  2. When adding the item, I call pItem->GetEditOptions(NULL)->AddComboButton(TRUE).

This always draws the combobox, but when I click on the combobox button, the combobox does not expand.  Instead the row is selected and I have two overlapping comboboxes drawn.  Clicking on the second comobox expands the combobox list.

 
ToolKitPro 13.2.1 
Windows 7 (32-bit)
Visual Studio 2008
 
Larry
 
 
 



Replies:
Posted By: mdoubson
Date Posted: 24 November 2009 at 7:19pm
Try MFC Sample - ReportDialog - with little changes in OnInitDialog:

CXTPReportRecord* pRec = m_wndReportCtrl.AddRecord(new CMessageRecord(msgImportanceNormal, FALSE, TRUE, _T("postmaster@mail.codejock.com"), _T("Undeliverable Mail"), odtSent, 7, TRUE, 10,

odtCreated, odtReceived, strEmpty, strEmpty, strMessage,

strEmpty, strEmpty, strEmpty,

strEmpty, strEmpty,

strMessage)); odtSent -= 80;

pRec->GetItem(3)->GetEditOptions(NULL)->m_bConstraintEdit = FALSE;

pRec->GetItem(3)->GetEditOptions(NULL)->AddConstraint(_T("Low"), 0);

pRec->GetItem(3)->GetEditOptions(NULL)->AddConstraint(_T("Normal"), 1);

pRec->GetItem(3)->GetEditOptions(NULL)->AddConstraint(_T("High"), 2);

pRec->GetItem(3)->GetEditOptions(NULL)->m_bAllowEdit = FALSE;

pRec->GetItem(3)->GetEditOptions(NULL)->AddComboButton(TRUE);

m_wndReportCtrl.AllowEdit(TRUE);

m_wndReportCtrl.FocusSubItems(TRUE);

m_wndReportCtrl.GetPaintManager()->m_bShowNonActiveInPlaceButton = TRUE;

Working fine on XP


-------------
Mark Doubson, Ph.D.


Posted By: mdoubson
Date Posted: 24 November 2009 at 8:16pm
I can confirm the problem on Vista and Win7 - while XP or Win7 - XP mode working fine.

-------------
Mark Doubson, Ph.D.


Posted By: mdoubson
Date Posted: 24 November 2009 at 9:14pm
Please try this demo - it have one combo - column-based combo and one row with cell-based combo.
https://forum.codejock.com/uploads/DemoVersion/ReportDialogStaticMod.rar -
 
https://forum.codejock.com/uploads/DemoVersion/ReportDialogStaticMod.rar
 
This sample working well on Vista and on Win7


-------------
Mark Doubson, Ph.D.


Posted By: mdoubson
Date Posted: 26 November 2009 at 12:21am
Retest same app on Win7 - now with Aero ON. On Combo button click picklist shows for very short moment and disapears. Without Aero - as good as on XP.

-------------
Mark Doubson, Ph.D.


Posted By: mdoubson
Date Posted: 27 November 2009 at 11:53pm

Today's build with Common files updates have no problems running on Win7 with Aero - https://forum.codejock.com/uploads/DemoVersion/ReportDialogStatic.rar - https://forum.codejock.com/uploads/DemoVersion/ReportDialogStatic.rar



-------------
Mark Doubson, Ph.D.


Posted By: larryp
Date Posted: 08 December 2009 at 1:04pm

I downloaded the sample and ran it.  Two things I notice:

1) If I click on the combobox down arrow icon, the combobox does not expand. It just puts the focus on the row.
2) After clicking on the icon, the displayed icon is narrower than the other icons and there is a black vertical line to the left of it.
 
--Larry



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net