Hi
I have a windows form and with init I have a tab control.
How can I get the tab control to resize, Min/Max as the windows form is
resized?
Thanks 3 16151
In the Form's resize event code block, insert code changing the tab control's
dimensions relative to the form's. Example:
Private Sub Form1_Resize(By Val sender As Object, ByVal e As
System.EventArg s) Handles Me.Resize
TabControl1.Wid th = Me.Width - 20
TabControl1.Hei ght = Me.Height - 20
End Sub
You can use any arithmetic operator and any values within reason; just
depends on what your needs are.
Randall Arnold
"BrianDH" wrote: Hi
I have a windows form and with init I have a tab control.
How can I get the tab control to resize, Min/Max as the windows form is resized?
Thanks
It Works! TY
"Randall Arnold" wrote: In the Form's resize event code block, insert code changing the tab control's dimensions relative to the form's. Example:
Private Sub Form1_Resize(By Val sender As Object, ByVal e As System.EventArg s) Handles Me.Resize TabControl1.Wid th = Me.Width - 20 TabControl1.Hei ght = Me.Height - 20 End Sub
You can use any arithmetic operator and any values within reason; just depends on what your needs are.
Randall Arnold
"BrianDH" wrote:
Hi
I have a windows form and with init I have a tab control.
How can I get the tab control to resize, Min/Max as the windows form is resized?
Thanks
"BrianDH" <Br*****@discus sions.microsoft .com> wrote in message
news:8C******** *************** ***********@mic rosoft.com... How can I get the tab control to resize, Min/Max as the windows form is resized?
Take a look at the Anchor and Dock properties or, if neither of
those do the job, add some code to the Form's Layout event,
as in
Private Sub Form1_Layout( ... ) handles Form1.Layout
With TabControl2
.Location = New Point( 8, 8 )
.Size = New Size( Me.ClientSize.W idth - 16 _
Me.ClientSize.H eight - 16 _
)
End With
End Sub
HTH,
Phill W. This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Andrew Baker |
last post by:
I want to show the parent name of a control in an addin I am writing.
However, when I use the following :
string parentName = thisControl.Parent.Name // thisControl is of type
Control
it is returning the name of the base type. Below is the form class
declaration:
public class frmUserEditor : VBUsers.Windows.Forms.EditorFormBase
|
by: Miky |
last post by:
Hi,
I have the following problem:
I have a .CFM web page and I have to populate, from VB, two textboxes on it.
I
was thinking using sendkeys (even if I don't like it too much) but when I
open the web browser and navigate to the selected page, I cannot set the
focus to the html part of the control (only the web control takes the focus)
so I can't use sendkeys to populate the fields I need.
|
by: Pranati |
last post by:
My windows forms(vb.net) application has a web browser control that
is navigating to an asp.net web application(aspx) . The aspx page has an
grid control . How can i capture the click event of the grid from my client application (windows
forms application)?
Any help on this ?
Thanks in advance
|
by: Aung Thu |
last post by:
Hi, there!
I want to set focus on a control, of which TabIndex is not the first, when a
form is loaded. In the form's load event, I have used Control.Focus() but it
doesn't not work. The focus is not on the control I set. The focus is always
on the control of which TabIndex is 0.
Thanks.
|
by: PW |
last post by:
Hi,
Is it possible to make a control bigger or maximize it also when the
user maximizes the form? I have a calendar control on a form and I
would like to automatically make it bigger when the form is maximized
so the user can see more detail.
I see there is only a height property for a form and no width
propertly. The calendar control on the form has both.
| |
by: Amit |
last post by:
Can anyone write the code to hide tabpage of tab control in windows
form 2.0
Thanks,
Amit
|
by: Mulm3h |
last post by:
Hi,
Me to Express vb 2k5
As I could remember there was a funtion in the old VB where simply type "Time" or something then it will show you the real time and second appear on the label.
Is that funtion still available in VB express 2k5, or it had been renamed to something else?
thx
|
by: Tarren |
last post by:
Hi:
I am trying to get access to the event after a window has been resized. The
events I have been using SizeChanged and Resize all fire after any pixel
size change.
What I am trying to achieve is after the window has been dragged to a new
size (or maximized/restored) then I redraw the images within the form.
If I do it on Resize, then it tries to redraw as the form is being resized,
|
by: mahboobeh |
last post by:
hi
I want to transparent a wpf control in a winapp.
I know that i can transparent the normal form and set its opacuty=0.if i transparent wpf control The background of the parent WPF control can become the background of hosted Windows Forms controls.
And i dont know how can i transparent wpf control and not displayed its backcolor.
For example if i have an image in wpf usercontrol ,It will only be displayed ,and the control backcolor...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
| |
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
| |
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
| |