statusbar1
how do i link a status bar to button 1 in delphi?
i want to click the first button and have the status bar go forward this is purly cosmetic and serves no purpose to my code
so i just want the bar to move from min 0 to max 10000 on the event of clicking button 1.
cheers in advance this has been driving me crazy
Ummm....
StatusBar1.Position := StatusBar1.Max;
??
------------------------------
BCB DX Library - RAD C++ Game development for BCB
StatusBar1.Position := StatusBar1.Max;
??
------------------------------
BCB DX Library - RAD C++ Game development for BCB
I think you are referring to a progress bar, not a status bar. A status bar is the control that sits along the bottom of the window like at the bottom of your IE window.
To change the position of a TProgressBar, simply set the value of the Position property to the desired value. If you want to go to the maximum value, then set it to the value of the Max property.
ProgressBar1.Position := ProgressBar1.Max;
Steve 'Sly' Williams
Tools Developer
Krome Studios
To change the position of a TProgressBar, simply set the value of the Position property to the desired value. If you want to go to the maximum value, then set it to the value of the Max property.
ProgressBar1.Position := ProgressBar1.Max;
Steve 'Sly' Williams
Tools Developer
Krome Studios
Oh, and to link it to the button On Click event, double-click on the button in design-mode. This will create an event handler in the code for the button something like the following:
procedure TForm1.Button1Click(Sender: TObject);
begin
end;
In between the begin and end statements is where you put the code to change the position of the progress bar as mentioned in the previous message.
For more help, select the component on the form in design-mode and press F1.
Steve 'Sly' Williams
Tools Developer
Krome Studios
Edited by - Sly on November 1, 2000 5:48:57 PM
procedure TForm1.Button1Click(Sender: TObject);
begin
end;
In between the begin and end statements is where you put the code to change the position of the progress bar as mentioned in the previous message.
For more help, select the component on the form in design-mode and press F1.
Steve 'Sly' Williams
Tools Developer
Krome Studios
Edited by - Sly on November 1, 2000 5:48:57 PM
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement