Solved

JScrollBar Question

Posted on 2006-11-21
5
220 Views
Last Modified: 2010-03-31
Hello,

I have a requirement in my SW development to create a scrollbar that has a min = 0.00, max = 100.00 and increments must be
floating point values with 2 decimal places. Currently ion javadocs I see scrollbars that work only for intergers. Do anyone know
where I can find this or can anyone throw some light to create one like that?

-prain
0
Comment
Question by:prain
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 
LVL 12

Expert Comment

by:enachemc
ID: 17987119
can't you make your scorll bar work in ranges 0-10 000 and instead of increase with two decimal digitis ... increase with this multiplied by 100 ? This results only in integers being used.
0
 

Author Comment

by:prain
ID: 18029038
No I cannot do that. This situation is different, and the user MUST see the incremented value in 2 decimal places.
That's our requirement. The Max MUST be 100.00  (a floating point) and the min MUST be (0.00).  Increments or
decrements MUST be in two decimal places. That's the requirement we have.
0
 
LVL 12

Accepted Solution

by:
enachemc earned 125 total points
ID: 18029055
how will the user know what values the scrollbar uses ? you can do the transformations required. Display a 30,12 and use a 3012 value.
0
 

Author Comment

by:prain
ID: 18033283
Ok. I think I get your point. Let me try this out and get back with you. Nice insight.
0
 

Author Comment

by:prain
ID: 18050168
Thanks. Works Well.
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

INTRODUCTION Working with files is a moderately common task in Java.  For most projects hard coding the file names, using parameters in configuration files, or using command-line arguments is sufficient.   However, when your application has vi…
In this post we will learn how to connect and configure Android Device (Smartphone etc.) with Android Studio. After that we will run a simple Hello World Program.
Viewers learn about the third conditional statement “else if” and use it in an example program. Then additional information about conditional statements is provided, covering the topic thoroughly. Viewers learn about the third conditional statement …
Viewers will learn about the different types of variables in Java and how to declare them. Decide the type of variable desired: Put the keyword corresponding to the type of variable in front of the variable name: Use the equal sign to assign a v…
Suggested Courses

710 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question