C
C#2y ago
K3YS

❔ visual studio windows form app, how can i allow a panel to extend out of the form itsself?

I have a custom dropdown menu i'm making for a windows form application, and i'm wondering if it's possible to have it extend out of the form itsself because the form is too small, and it'd have to be gigantic to hold the dropdown menu.
40 Replies
JakenVeina
JakenVeina2y ago
define "extend out ofbthe form itself"
K3YS
K3YSOP2y ago
so, if you have a dropdown menu for example right and you open it on a small window the dropdown menu would extend out of the window because the window is too small for all of the contents i'm wondering how i can do that without actually having a dropdown menu, but with a custom one i'm making
JakenVeina
JakenVeina2y ago
out of the window meaning actually being drawn outside of it?
K3YS
K3YSOP2y ago
let me show you an example a dropdown menu would be able to act like this right
K3YS
K3YSOP2y ago
No description
K3YS
K3YSOP2y ago
drop outside of the window
JakenVeina
JakenVeina2y ago
yeah I don't see why not
K3YS
K3YSOP2y ago
but you can't do that with a custom dropdown menu i don't think
JakenVeina
JakenVeina2y ago
try it and find out
K3YS
K3YSOP2y ago
thats why im asking here??
JakenVeina
JakenVeina2y ago
why not?
K3YS
K3YSOP2y ago
i'm not sure there's a way to do it lmao content inside of a window extending outside of the window it's in just seems impossible, or at the least very hard to do.
JakenVeina
JakenVeina2y ago
there must be, if a built-in control can do it
K3YS
K3YSOP2y ago
unless it's an actual dropdown menu i guess. just cant figure out how i'll be able to make it do what i need it to
JakenVeina
JakenVeina2y ago
define "it"
K3YS
K3YSOP2y ago
drop outside of the window itsself, like the picture i showed
JakenVeina
JakenVeina2y ago
yes, you said thst that's what you want to do define the "it" that you want to do thst
K3YS
K3YSOP2y ago
i just did, that's what i meant
JakenVeina
JakenVeina2y ago
to make "it" do what I need "it" to
K3YS
K3YSOP2y ago
i don't know how to make the custom dropdown menu drop out of the window itsself
JakenVeina
JakenVeina2y ago
what's your custom dropdown implementation?
K3YS
K3YSOP2y ago
you click a textbox, a dropdown menu extends (flow panel layout) with buttons in it
JakenVeina
JakenVeina2y ago
yes, how are you implementing that
K3YS
K3YSOP2y ago
it's already implemented, i just don't know how to make it extend out of the window because the window is too small, that's what i need
JakenVeina
JakenVeina2y ago
how are you implementing the flyout part?
K3YS
K3YSOP2y ago
also what do you mean how am i implementing it, sort of explained it here right?
JakenVeina
JakenVeina2y ago
I mean, in code
K3YS
K3YSOP2y ago
No description
JakenVeina
JakenVeina2y ago
where is this?
K3YS
K3YSOP2y ago
in form1.cs
JakenVeina
JakenVeina2y ago
oh
K3YS
K3YSOP2y ago
newbutton is just adding buttons into the dropdown
JakenVeina
JakenVeina2y ago
so you don't have a custom dropdown at all you have a form, with some controls in it
K3YS
K3YSOP2y ago
what did you think i meant when i said a custom dropdown?
JakenVeina
JakenVeina2y ago
a custom control well, really, I wasn't sure either way, that's why I asked
K3YS
K3YSOP2y ago
No description
JakenVeina
JakenVeina2y ago
so, you can't controls attached to a parent cannot be drawn outside of their parent the way a dropdown makes it work is that the popup is... a popup it is not attached to the form, it exists completely outside of the form's hierarchy possibly even the window's hierarchy give this a look
JakenVeina
JakenVeina2y ago
Stack Overflow
C# Winform how to allow panel draw outside the panel's parent?
I have created a form that shows data and the filter that has checkbox in it combobox I have used a Button and a Panel to do this and found that the panel is only shown in the parent's panel not...
SWR
SWR2y ago
This is a dumb question maybe, but what's wrong with the default behavior of a scroll bar in the combo box? This scales better than your idea. What happens when your combo box extends past your monitor?
Accord
Accord2y ago
Was this issue resolved? If so, run /close - otherwise I will mark this as stale and this post will be archived until there is new activity.

Did you find this page helpful?