Hey everyone,
I was looking for some insight into the syntax for status bar panels. The help documentations says if simplepanel property is set to false you can have multiple panels in the status bar but I'm not sure how I'd go about assigning that.
I'm assuming I need to assign something to the panels property? I'm trying to put two panels in the status bar so I can have a message that is aligned to the left side of my dialog and then in the second panel have that one aligned to the right.
Once I get the syntax of how it works for one panel I'm sure I can figure it out from there.
Thanks!
Question about creating multiple panels in a statusbar.
Moderators: JRL, Dorian (MJT support)
- Marcus Tettmar
- Site Admin
- Posts: 7395
- Joined: Thu Sep 19, 2002 3:00 pm
- Location: Dorset, UK
- Contact:
At present you can't access the panels property as it is an object in its own right.
So right now you will need to stick with SimplePanel and SimpleText.
We'll work on making the panels object accessible so that you can have multiple panels within the status bar.
You can achieve the same appearance by using a number of regular panels instead, and multiple status bar objects. See my example below which uses two status bar objects to give the appearance of one status bar with two panels:
So right now you will need to stick with SimplePanel and SimpleText.
We'll work on making the panels object accessible so that you can have multiple panels within the status bar.
You can achieve the same appearance by using a number of regular panels instead, and multiple status bar objects. See my example below which uses two status bar objects to give the appearance of one status bar with two panels:
Code: Select all
Dialog>Dialog1
object Dialog1: TForm
Left = 710
Top = 501
HelpContext = 5000
BorderIcons = [biSystemMenu]
Caption = 'CustomDialog'
ClientHeight = 226
ClientWidth = 570
Color = clBtnFace
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
Font.Height = -11
Font.Name = 'MS Sans Serif'
Font.Style = []
OldCreateOrder = True
ShowHint = True
OnTaskBar = False
PixelsPerInch = 96
TextHeight = 13
object Panel1: TPanel
Left = 0
Top = 207
Width = 570
Height = 19
Align = alBottom
BevelOuter = bvNone
Caption = 'Panel1'
TabOrder = 0
ExplicitTop = 94
ExplicitWidth = 439
object Panel2: TPanel
Left = 0
Top = 0
Width = 185
Height = 19
Align = alLeft
BevelOuter = bvNone
Caption = 'Panel2'
TabOrder = 0
ExplicitLeft = 51
ExplicitTop = 3
ExplicitHeight = 41
object StatusBar1: TStatusBar
Left = 0
Top = 0
Width = 185
Height = 19
Panels = <>
SimplePanel = True
SimpleText = 'Hello World'
SizeGrip = False
ExplicitLeft = 73
ExplicitTop = 6
ExplicitWidth = 0
end
end
object Panel3: TPanel
Left = 185
Top = 0
Width = 385
Height = 19
Align = alClient
BevelOuter = bvNone
Caption = 'Panel3'
TabOrder = 1
ExplicitWidth = 280
object StatusBar3: TStatusBar
Left = 0
Top = 0
Width = 385
Height = 19
Panels = <>
SimplePanel = True
SimpleText = 'Second Status Panel'
ExplicitLeft = 156
ExplicitTop = 8
ExplicitWidth = 0
end
end
end
end
EndDialog>Dialog1
Show>Dialog1,r
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?