I am only a little way in front of you in terms of MT knowledge, but I have a 
lot of experience of other programming platforms, if anyone can spot a better 
way please correct me, what I would do is this.

Create a class that inherits uiview,

plan for reuse from the start, so plan for having the screen in 
landscape/portrait and for both the iPhone and iPad screen sizes,

create a view this is the total size of the control with the + and - buttons 
with the indicator in the middle, so the view will be a rectangle almost the 
height of the screen and say 50px wide, inside this view add the + button to 
the top of the view, the - button to the bottom of the view and using the code 
in the link in the previous email build the percentage bar in the middle, the 
key thing is that the variable for percentage for the view needs to be at the 
class level.

Something to consider is if the percentage is under say 20% colour it red, then 
yellow for 21%-80%, then green for >80% just a thought.

hopefully that should get you started, sorry I have no code to show you, 
hopefully someone else can provide a link to a working example.

ATB

Alex



On 10 Jul 2012, at 17:51, proindigo wrote:

> Yes you are correct. I will have to incorporate two buttons + and - for
> increasing and decreasing the level. My first question is, should I use a
> blank label or is there any other control in the library available that is
> more suited to this task? 
> 
> Let's assume for the sake of discussion that I use a blank label,
> representing a vertical bar. How to establish a mathematical logic so that
> when user clicks the + or - buttons, there is  increment or decrements [ie
> gets filled by green color] by a fixed amount, say 1/25th of the total
> height of the label. Can you provide me with an outline of some code block
> relating to this specific scenario. It would be immensely helpful to me. 
> 
> Meanwhile I am going to take a look at the link you forwarded me and
> consider the options.
> 
> Look forward to your reply.
> 
> Thanks.
> 
> --
> View this message in context: 
> http://monotouch.2284126.n4.nabble.com/IPhone-Application-Critical-Scenario-Help-Required-tp4655874p4655902.html
> Sent from the MonoTouch mailing list archive at Nabble.com.
> _______________________________________________
> MonoTouch mailing list
> MonoTouch@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/monotouch

_______________________________________________
MonoTouch mailing list
MonoTouch@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/monotouch

Reply via email to