xtpControlCustom - SetFocus Problem |
Post Reply |
Author | |
Josef
Groupie Joined: 15 April 2006 Status: Offline Points: 59 |
Post Options
Thanks(0)
Posted: 24 August 2008 at 6:12pm |
Hello,
I have a strange Problem using a FlatEdit-Control as a custom Commandbar control. When the Flatedit control receives the focus, it moves to it's original position on the form. Please take a look at the attached sample project: 20080824_180921_SetFocusProblem.zip Thank you, Josef |
|
Product: Xtreme SuitePro ActiveX v13.2.1
Platform: Windows 2008 (64bit) Language: Visual Basic 6.0 |
|
ijwelch
Senior Member Joined: 20 June 2006 Status: Offline Points: 262 |
Post Options
Thanks(0)
|
Try adding FlatEdit to PictureBox first, then add PictureBox to CommandBar.
|
|
Josef
Groupie Joined: 15 April 2006 Status: Offline Points: 59 |
Post Options
Thanks(0)
|
Hi,
this works, but shouldn't it work without Picturebox too? Thank you, Josef |
|
Product: Xtreme SuitePro ActiveX v13.2.1
Platform: Windows 2008 (64bit) Language: Visual Basic 6.0 |
|
Aaron
Senior Member Joined: 29 January 2008 Status: Offline Points: 2192 |
Post Options
Thanks(0)
|
Hi,
Most controls get detached and no one has an answer for this problem so I use ALWAYS a picturebox. I don't even try anymore... I suggest you do the same
|
|
Product: Xtreme SuitePro (ActiveX) version 15.0.2
Platform: Windows XP (32bit) - SP 2 Language: Visual Basic 6.0 Zero replies is not an option.... |
|
Baldur
Senior Member Joined: 22 November 2006 Location: Germany Status: Offline Points: 244 |
Post Options
Thanks(0)
|
The problem is, that CommandBars are not really a Container-Control !
You assign only a windows-handle.
But if a control is contained it use the Extender-Property of the Container to get some informationes like position, backgrounds and other.
If you put the control in the form, the container is the form and the positions are relative to the form.
If you put a control in a picturebox, the positions are relative to the picturebox (see Left/Top-Properties).
The picturebox itself don't use the extender because its a container himself.
In .NET you must use a panel-control, picturebox is there not a container-control.
|
|
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |