Cannot add Control to TabControl (again #1440)
A lightweight and easy-to-use password manager
Brought to you by:
dreichl
I'm experiencing the same issue as described in #1440; only this time it's for version 2.34.
I usually only have one kdbx file open, but wanted to validate a sync-conflict copy of the same kdbx.
Switching back and forth 3 times will give this error:
Cannot add Control to TabControl. Only TabPages can be directly added to TabControls.
System.Windows.Forms
at System.Windows.Forms.TabControl+ControlCollection.Add (System.Windows.Forms.Control value) [0x00000] in <filename unknown>:0
at System.Windows.Forms.Control.set_Parent (System.Windows.Forms.Control value) [0x00000] in <filename unknown>:0
at System.Windows.Forms.Control..ctor (System.Windows.Forms.Control parent, System.String text) [0x00000] in <filename unknown>:0
at (wrapper remoting-invoke-with-check) System.Windows.Forms.Control:.ctor (System.Windows.Forms.Control,string)
at System.Windows.Forms.NativeWindow.WndProc (IntPtr hWnd, Msg msg, IntPtr wParam, IntPtr lParam) [0x00000] in <filename unknown>:0
at System.Windows.Forms.XplatUIX11.DispatchMessage (System.Windows.Forms.MSG& msg) [0x00000] in <filename unknown>:0
at System.Windows.Forms.XplatUI.DispatchMessage (System.Windows.Forms.MSG& msg) [0x00000] in <filename unknown>:0
at System.Windows.Forms.Application.RunLoop (Boolean Modal, System.Windows.Forms.ApplicationContext context) [0x00000] in <filename unknown>:0
at System.Windows.Forms.Application.Run (System.Windows.Forms.ApplicationContext context) [0x00000] in <filename unknown>:0
at System.Windows.Forms.Application.Run (System.Windows.Forms.Form mainForm) [0x00000] in <filename unknown>:0
at KeePass.Program.Main (System.String[] args) [0x00000] in <filename unknown>:0
Void Add(System.Windows.Forms.Control)
Running:
~$ apt-cache showpkg keepass2
Package: keepass2
Versions:
2.34+dfsg-1~ubuntu14.04~ppa1 (/var/lib/apt/lists/ppa.launchpad.net_jtaylor_keepass_ubuntu_dists_trusty_main_binary-amd64_Packages) (/var/lib/dpkg/status)
Description Language:
File: /var/lib/apt/lists/ca.archive.ubuntu.com_ubuntu_dists_trusty_universe_binary-amd64_Packages
MD5: e0f163e68e620c6be9c7b15ffee31fe6
Description Language: en
File: /var/lib/apt/lists/ca.archive.ubuntu.com_ubuntu_dists_trusty_universe_i18n_Translation-en
MD5: e0f163e68e620c6be9c7b15ffee31fe6
Description Language: en_CA
File: /var/lib/apt/lists/ca.archive.ubuntu.com_ubuntu_dists_trusty_universe_i18n_Translation-en%5fCA
MD5: e0f163e68e620c6be9c7b15ffee31fe6
2.25+dfsg-1ubuntu0.1 (/var/lib/apt/lists/ca.archive.ubuntu.com_ubuntu_dists_trusty-updates_universe_binary-amd64_Packages)
Description Language:
File: /var/lib/apt/lists/ca.archive.ubuntu.com_ubuntu_dists_trusty_universe_binary-amd64_Packages
MD5: e0f163e68e620c6be9c7b15ffee31fe6
Description Language: en
File: /var/lib/apt/lists/ca.archive.ubuntu.com_ubuntu_dists_trusty_universe_i18n_Translation-en
MD5: e0f163e68e620c6be9c7b15ffee31fe6
Description Language: en_CA
File: /var/lib/apt/lists/ca.archive.ubuntu.com_ubuntu_dists_trusty_universe_i18n_Translation-en%5fCA
MD5: e0f163e68e620c6be9c7b15ffee31fe6
2.25+dfsg-1 (/var/lib/apt/lists/ca.archive.ubuntu.com_ubuntu_dists_trusty_universe_binary-amd64_Packages) (/var/lib/apt/lists/us.archive.ubuntu.com_ubuntu_dists_trusty_universe_binary-amd64_Packages)
Description Language:
File: /var/lib/apt/lists/ca.archive.ubuntu.com_ubuntu_dists_trusty_universe_binary-amd64_Packages
MD5: e0f163e68e620c6be9c7b15ffee31fe6
Description Language: en
File: /var/lib/apt/lists/ca.archive.ubuntu.com_ubuntu_dists_trusty_universe_i18n_Translation-en
MD5: e0f163e68e620c6be9c7b15ffee31fe6
Description Language: en_CA
File: /var/lib/apt/lists/ca.archive.ubuntu.com_ubuntu_dists_trusty_universe_i18n_Translation-en%5fCA
MD5: e0f163e68e620c6be9c7b15ffee31fe6
Reverse Depends:
keepass2-plugin-keepasshttp,keepass2 2.17
keepass2-plugin-rpc,keepass2 2.19
keepass2-plugin-libimagemagick,keepass2
keepass2-plugin-application-menu,keepass2
keepass2-plugin-application-indicator,keepass2
keepass2-plugin-libdbus,keepass2
keepass2-plugin-keeagent,keepass2 2.19
keepass2-doc,keepass2
keepass2-doc,keepass2
keepass2-doc,keepass2
Dependencies:
2.34+dfsg-1~ubuntu14.04~ppa1 - mono-runtime (2 3.0~) libmono-corlib4.5-cil (2 3.2.8) libmono-system-drawing4.0-cil (2 3.0.6) libmono-system-security4.0-cil (2 1.0) libmono-system-windows-forms4.0-cil (2 1.0) libmono-system-xml4.0-cil (2 3.2.1) libmono-system4.0-cil (2 3.2.8) libx11-6 (2 2:1.6.0) keepass2-doc (0 (null)) mono-dmcs (0 (null)) xdotool (0 (null)) xsel (0 (null))
2.25+dfsg-1ubuntu0.1 - mono-runtime (2 3.0~) libmono-corlib4.5-cil (2 3.2.8) libmono-system-drawing4.0-cil (2 3.0.6) libmono-system-security4.0-cil (2 1.0) libmono-system-windows-forms4.0-cil (2 1.0) libmono-system-xml4.0-cil (2 3.2.1) libmono-system4.0-cil (2 3.2.8) libx11-6 (2 2:1.6.0) keepass2-doc (0 (null)) mono-dmcs (0 (null)) xdotool (0 (null)) xsel (0 (null))
2.25+dfsg-1 - mono-runtime (2 3.0~) libmono-corlib4.5-cil (2 3.2.3) libmono-system-drawing4.0-cil (2 3.0.6) libmono-system-security4.0-cil (2 1.0) libmono-system-windows-forms4.0-cil (2 1.0) libmono-system-xml4.0-cil (2 3.2.1) libmono-system4.0-cil (2 3.2.3) libx11-6 (2 2:1.6.0) keepass2-doc (0 (null)) mono-dmcs (0 (null)) xdotool (0 (null)) xsel (0 (null))
Provides:
2.34+dfsg-1~ubuntu14.04~ppa1 -
2.25+dfsg-1ubuntu0.1 -
2.25+dfsg-1 -
Reverse Provides:
Still on Ubuntu 14.04.5 LTS as I have not had time to upgrade...
I've detected this same problem. Before, it happended only with custom colors in the tabs, but now it happens with any two tabs.
Do youy have any plug-ins? Can you disable them?
cheers, Paul
Well, this is a bug in Mono, and unfortunately I don't see how a workaround could look like.
However, I just tested KeePass 2.34 on Ubuntu 16.04.1 LTS with mono-complete 4.6.1.5-0xamarin1 (i.e. exactly what you were using) and am not able to reproduce the issue. Thus I'm wondering what additional factors are required for this bug to appear.
Like Paul suggested, please try to remove any plugins, if you have any. If you're still able to reproduce the problem, it would be great if you could provide your configuration file (KeePass.config.xml).
Thanks and best regards,
Dominik
I assume the issue is not reproducible anymore.
Thanks and best regards,
Dominik
I can still reproduce this bug using Mono 4.8.0 and KeePass 2.35.
However (thanks to a comment in [#1440]), I noticed that disabling custom DB colors prevents KeePass from crashing when switching between DB tabs -- therefore, it seems that the colored tabs cause the crash.
Edit: Whoops, I didn't notice that this particular issue is about crashes with custom DB colors disabled. At least I can confirm that crashes don't happen anymore when disabling custom colors, so whatever the cause was, a newer Mono release must have fixed it.
Related
Bugs:
#1440Last edit: Tilman Blumenbach 2017-05-09