Random.NextDouble will return a value between 0 and 1. So if the value is 0.82, then the point representing this value will have a y axis of 164. So the basic idea is: you can calculate a proper y value based on your coordinate system. Sorry I don't have
time to write a more complete sample...
shanaolanxing - I'll transfer to the Windows Azure team, and will have limited time to participate in the Silverlight forum. Apologize if I don't answer your questions in time.
i am creating few ellipse at runtime when canvas will load.... like this below code..
for(i=0;i<n1.length;i++){
var t= n1[i]-10;
var l= hspace*(i)+15;
var slControl = Sender.getHost();
var e =slControl.content.createFromXaml('<Ellipse Fill="blue" Opacity="0.5" Height="10" Width="10" Canvas.Top="'+t+'" Canvas.Left="'+l+'" MouseEnter="show"/>');
var canvas = Sender.findName("main");
canvas.children.Add(e);
}
Now on other event i want to remove all previous ellipse and draw it again with differn parameter say i=0;i<n-20;i++
Hello Sir, i am desiging one slider in silverlight and i need to intract with table content which is in html.. when slider left or right thumb will move then table value should also change,,,, Note: i am using javascrip code so plz answer with this context
only.. Thank you Sir
Yi-Lun Luo -...
All-Star
25149 Points
2759 Posts
Microsoft
Re: Re: Re: Re: Re: create line chart in silverlight2.0
Mar 28, 2008 11:37 AM | LINK
In my original code, you'll notice I hard code:
source.Add(random.NextDouble() * 200);
Random.NextDouble will return a value between 0 and 1. So if the value is 0.82, then the point representing this value will have a y axis of 164. So the basic idea is: you can calculate a proper y value based on your coordinate system. Sorry I don't have time to write a more complete sample...
kundank
Member
12 Points
9 Posts
Re: Re: Re: Re: Re: Re: create line chart in silverlight2.0
Mar 28, 2008 11:50 AM | LINK
thanks shan
sitian
Member
20 Points
10 Posts
How to replace variable value
Apr 04, 2008 05:29 AM | LINK
suppose we have two varibale
var t= 50;
var l= 22;
then how can i put t and l value in below statement for Top and Left
var e =slControl.content.createFromXaml('<Ellipse Height="10" Width="10" Fill="red" Canvas.top="t" Canvas.Left="l" />');
plz reply soon its urgent
Thanking You
Subhash
Bangalore
mchlSync
Star
14968 Points
2799 Posts
Re: How to replace variable value
Apr 04, 2008 07:17 AM | LINK
var e =slControl.content.createFromXaml('<Ellipse Height="10" Width="10" Fill="red" Canvas.top="' + t + '" Canvas.Left="' + l + '" />');
Regards,
Michael Sync
Silverlight MVP
Blog : http://michaelsync.net
sitian
Member
20 Points
10 Posts
Re: How to replace variable value
Apr 04, 2008 09:38 AM | LINK
Thanks .. its worked..
Thank alot..
one more problem ..
i am creating few ellipse at runtime when canvas will load.... like this below code..
for(i=0;i<n1.length;i++){
var t= n1[i]-10;
var l= hspace*(i)+15;
var slControl = Sender.getHost();
var e =slControl.content.createFromXaml('<Ellipse Fill="blue" Opacity="0.5" Height="10" Width="10" Canvas.Top="'+t+'" Canvas.Left="'+l+'" MouseEnter="show"/>');
var canvas = Sender.findName("main");
canvas.children.Add(e);
}
Now on other event i want to remove all previous ellipse and draw it again with differn parameter say i=0;i<n-20;i++
how i can do it ..
"Thanking You"
Subhash
Bangalore
logicasw
Member
50 Points
25 Posts
Re: How to replace variable value
Apr 04, 2008 02:46 PM | LINK
Look at this:
http://www.visifire.com/index.php
sitian
Member
20 Points
10 Posts
Re: Re: How to replace variable value
Apr 08, 2008 06:58 AM | LINK
Hello Sir,
Thanks for this nice link..
now charting becames easy.
i am new so i have some problem.
i am saving Data.xml and calling in html then its showing an error
error is:-->Error Log Version:1.0.6 Beta
[Arg_NotsupportedException]
Arguments:
debugging Resources string are unavailbale
at System.Net.Webclient(...)
at .....................................
can you help me to come out
Thank You
Bangalore
sitian
Member
20 Points
10 Posts
Re: Re: How to replace variable value
Apr 08, 2008 06:58 AM | LINK
Hello Sir,
Thanks for this nice link..
now charting becames easy.
i am new so i have some problem.
i am saving Data.xml and calling in html then its showing an error
error is:-->Error Log Version:1.0.6 Beta
[Arg_NotsupportedException]
Arguments:
debugging Resources string are unavailbale
at System.Net.Webclient(...)
at .....................................
can you help me to come out
Thank You
Bangalore
sunilurs
Member
199 Points
36 Posts
Re: Re: How to replace variable value
Apr 14, 2008 07:00 PM | LINK
Have a look at the following forum post. I guess you've a similar problem
http://www.visifire.com/forums/index.php?showtopic=27
Sunil Urs
sitian
Member
20 Points
10 Posts
How to intract with html page
Apr 15, 2008 10:10 AM | LINK
Hello Sir, i am desiging one slider in silverlight and i need to intract with table content which is in html.. when slider left or right thumb will move then table value should also change,,,, Note: i am using javascrip code so plz answer with this context only.. Thank you Sir
Bangalore