setting Minimum and maximum values

Mar 17, 2009 at 7:41 PM

 

Hi David,
 When the minimum and maximum values are set like this it shows an error saying some out of range problem. But the value field works alright. When the same maximim and minimum values are given directly instead of {Binding } is shows no error. Can you help me out. thx

<
my:Dial360 x:Name="dlSensor" Value="{Binding curVal}" Minimum="{Binding minVal}" Maximum="{Binding maxVal}" Grid.Row="0" Grid.Column="0" HorizontalAlignment="Center" >
    <my:Dial360.FaceColorRange>
        <my:ColorPoint HiColor="#7B1D15" LowColor="#BA1A00" Value="0" />
        <my:ColorPoint HiColor="#4C5C59" LowColor="#058A73" Value="15" />
        <my:ColorPoint HiColor="#7B1D15" LowColor="#BA1A00" Value="20" />
    </my:Dial360.FaceColorRange>
</my:Dial360>

 

Coordinator
Mar 19, 2009 at 9:23 PM
Hi there zapping

I tried to reproduce this but I didn't have much luck. My current developement version is quite a way from the last release. One thing that I did note
was that using the abbreviated format of Value="{Binding minVal}" gave different results to Value="{Binding Path=minVal}". Could you try using the
Path= format and tell me what happens?

D
Apr 7, 2009 at 11:11 AM
Hi David,
  Sorry for the delayed reply was occupied. Thank you for the tip. Will try it out. But did a work around it by setting the minimum and maximum values through code at load time and that did the trick.

cheers,
zapping.
Apr 13, 2009 at 5:04 PM
Hi,
I had a similar problem with 'Minimum'. If a thermometer reading is < 0 - it gets displayed as 0.

The issue was apparent in my code :

            pt.Name = name;
            pt.Value = value;
            pt.Minimum = min;
            pt.Maximum = max;

Always showed negatives as 0

So _ moved the min/max up front and it worked fine - so the issue could be down to the order of binding ??.

            pt.Minimum = min;
            pt.Maximum = max;
            pt.Name = name;
            pt.Value = value;

Obviously setting the value before defining the minimum causes the default min to be used - logical ;-).

I am using 0.5.7.0 version - last stable release ?.

I also have a second problem but will not post details until I have done more investigation ;-O. Getting an exception when displaying a quantity of thermometers :

'Value does not fall within the expected range'. which occurs when the code-created thermometers are being rendered under some circumstances only!.

Thanks

Regards

Graham
Apr 13, 2009 at 5:10 PM
OK found my second problem - not caused by the Thermometer at all I guess but rather the Silverlight framework.

I am adding thermometers at runtile into a stackpanel, then when all have been created - I add the stack panel as a child to a border - this is when it barfs.

The problem arises if I have two thermometers with the same 'Name' :-O.

Just thought it worth giving the feedback as I had already suggested a further issue might exist ;-O.

Regards

Graham

Coordinator
Apr 14, 2009 at 1:39 PM
The minimum display as 0 issue is fixed in the current top of tree source. I will be doing a release as soon as I iron out the wrinkles with WPF.

D
Jun 5, 2009 at 8:23 AM

hi Zapping/David

I am trying to read data from database and trying to set the dial's min max and value filed from that.

But the Min, max fields are still showing 0-100. I have used a wcf service to get the data.

please help me in  going about this.

 

 

Coordinator
Jun 6, 2009 at 2:59 PM

Hi There

Are you running against the last release or the top of tree? The next release (hoefully sunday) should have fixes for all reported issues in it (and of course some new issues!)

 

D

Jun 8, 2009 at 6:13 AM

I am sorry but i am not sure. I am using Build 007. How can i know which is the release i am using? 

Regards

Aroop

 

 

Jun 9, 2009 at 5:25 AM

hi david

i used the latest release(by date) and it is working beautifully.

Thanks.