Jump to content

unitrackbar - show values permanently


chefdackel

Recommended Posts

1 hour ago, chefdackel said:

the second (defining a step value) is the most important, because I don't see any workaround.

One possible workaround:

1. You have to "divide" the value on the server side by 10...

2. 

procedure TMainForm.UniFormCreate(Sender: TObject);
begin
  with UniTrackBar1.JSInterface do
  begin
    JSConfig('minValue', [10]);    //1
    JSConfig('maxValue', [1000]);  //100
    JSConfig('increment', [5]);    //0.5
    JSAddListener('afterrender', 'function(){this.plugins[0].getText = function(a){return (a.value/10).toFixed(2)}}')
  end;
end;

 

image.png.ed90aaa204098333ccbec7918c350671.png

Link to comment
Share on other sites

  • 8 months later...

Ok, but this solution don't help me much. I want to show in the TipText my data from the dataset and value of UniTrackBar telling me from which record of dataset i must get data. Like this:

Procdeure UniTrackBar1Change(Sender:TObject);
begin
	AdoQuery.RecNo := UniTrackBar1.Value;
	UniTrackBar1.TipText := AdoQuery.FieldByName('data').AsString;
end;

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...