@@ -162,7 +162,7 @@ chart.SecondaryAxis = secondaryAxis;
162
162
163
163
## Populate Chart with data
164
164
165
- To create a polar chart, you can add a [ PolarAreaSeries ] ( https://help.syncfusion.com/cr/maui/Syncfusion.Maui.Charts.PolarAreaSeries .html?tabs=tabid-1%2Ctabid-4 ) to the polar chart [ Series] ( https://help.syncfusion.com/cr/maui/Syncfusion.Maui.Charts.SfPolarChart.html#Syncfusion_Maui_Charts_SfPolarChart_Series ) property of the chart, and then bind the ` PlantData ` property of the above ` ViewModel ` to the ` PolarAreaSeries .ItemsSource` as follows.
165
+ To create a polar chart, you can add a [ PolarLineSeries ] ( https://help.syncfusion.com/cr/maui/Syncfusion.Maui.Charts.PolarLineSeries .html?tabs=tabid-1%2Ctabid-4 ) to the polar chart [ Series] ( https://help.syncfusion.com/cr/maui/Syncfusion.Maui.Charts.SfPolarChart.html#Syncfusion_Maui_Charts_SfPolarChart_Series ) property of the chart, and then bind the ` PlantData ` property of the above ` ViewModel ` to the ` PolarLineSeries .ItemsSource` as follows.
166
166
167
167
* In order to plot the series, the [ XBindingPath] ( https://help.syncfusion.com/cr/maui/Syncfusion.Maui.Charts.ChartSeries.html#Syncfusion_Maui_Charts_ChartSeries_XBindingPath ) and [ YBindingPath] ( https://help.syncfusion.com/cr/maui/Syncfusion.Maui.Charts.XYDataSeries.html#Syncfusion_Maui_Charts_XYDataSeries_YBindingPath ) properties need to be configured correctly. These properties allow the chart to retrieve values from the corresponding properties in the data model.
168
168
@@ -175,15 +175,15 @@ To create a polar chart, you can add a [PolarAreaSeries](https://help.syncfusion
175
175
</chart : SfPolarChart .PrimaryAxis>
176
176
177
177
<chart : SfPolarChart .SecondaryAxis>
178
- <chart : NumericalAxis >
178
+ <chart : NumericalAxis Maximum = " 100 " >
179
179
</chart : NumericalAxis >
180
180
</chart : SfPolarChart .SecondaryAxis>
181
181
182
- <chart : PolarAreaSeries ItemsSource =" {Binding PlantDetails}" XBindingPath =" Direction" YBindingPath =" Tree" />
182
+ <chart : PolarLineSeries ItemsSource =" {Binding PlantDetails}" XBindingPath =" Direction" YBindingPath =" Tree" />
183
183
184
- <chart : PolarAreaSeries ItemsSource =" {Binding PlantDetails}" XBindingPath =" Direction" YBindingPath =" Weed" />
184
+ <chart : PolarLineSeries ItemsSource =" {Binding PlantDetails}" XBindingPath =" Direction" YBindingPath =" Weed" />
185
185
186
- <chart : PolarAreaSeries ItemsSource =" {Binding PlantDetails}" XBindingPath =" Direction" YBindingPath =" Flower" />
186
+ <chart : PolarLineSeries ItemsSource =" {Binding PlantDetails}" XBindingPath =" Direction" YBindingPath =" Flower" />
187
187
</chart : SfPolarChart >
188
188
```
189
189
@@ -196,21 +196,24 @@ CategoryAxis primaryAxis = new CategoryAxis();
196
196
chart .PrimaryAxis = primaryAxis ;
197
197
198
198
// Initializing secondary Axis
199
- NumericalAxis secondaryAxis = new NumericalAxis ();
199
+ NumericalAxis secondaryAxis = new NumericalAxis ()
200
+ {
201
+ Maximum = 100 ,
202
+ };
200
203
chart .SecondaryAxis = secondaryAxis ;
201
204
202
205
// Initialize the series
203
- PolarAreaSeries series = new PolarAreaSeries ();
206
+ PolarLineSeries series = new PolarLineSeries ();
204
207
series .ItemsSource = (new ViewModel ()).PlantDetails ;
205
208
series .XBindingPath = " Direction" ;
206
209
series .YBindingPath = " Tree" ;
207
210
208
- PolarAreaSeries series = new PolarAreaSeries ();
211
+ PolarLineSeries series = new PolarLineSeries ();
209
212
series .ItemsSource = (new ViewModel ()).PlantDetails ;
210
213
series .XBindingPath = " Direction" ;
211
214
series .YBindingPath = " Weed" ;
212
215
213
- PolarAreaSeries series = new PolarAreaSeries ();
216
+ PolarLineSeries series = new PolarLineSeries ();
214
217
series .ItemsSource = (new ViewModel ()).PlantDetails ;
215
218
series .XBindingPath = " Direction" ;
216
219
series .YBindingPath = " Flower" ;
@@ -252,16 +255,16 @@ The [ShowDataLabels](https://help.syncfusion.com/cr/maui/Syncfusion.Maui.Charts.
252
255
``` xaml
253
256
<chart : SfPolarChart >
254
257
. . .
255
- <chart : PolarAreaSeries ShowDataLabels =" True" >
256
- </chart : PolarAreaSeries >
258
+ <chart : PolarLineSeries ShowDataLabels =" True" >
259
+ </chart : PolarLineSeries >
257
260
</chart : SfPolarChart >
258
261
```
259
262
260
263
###### C#
261
264
``` C#
262
265
SfPolarChart chart = new SfPolarChart ()
263
266
. . .
264
- PolarAreaSeries series = new PolarAreaSeries ();
267
+ PolarLineSeries series = new PolarLineSeries ();
265
268
series .ShowDataLabels = true ;
266
269
chart .Series .Add (series );
267
270
```
@@ -293,32 +296,32 @@ chart.Legend = new ChartLegend();
293
296
``` xaml
294
297
<chart : SfPolarChart >
295
298
. . .
296
- <chart : PolarAreaSeries ItemsSource =" {Binding PlantDetails}" XBindingPath =" Direction" YBindingPath =" Tree"
299
+ <chart : PolarLineSeries ItemsSource =" {Binding PlantDetails}" XBindingPath =" Direction" YBindingPath =" Tree"
297
300
Label =" Tree" />
298
301
299
- <chart : PolarAreaSeries ItemsSource =" {Binding PlantDetails}" XBindingPath =" Direction" YBindingPath =" Weed"
302
+ <chart : PolarLineSeries ItemsSource =" {Binding PlantDetails}" XBindingPath =" Direction" YBindingPath =" Weed"
300
303
Label =" Weed" />
301
304
302
- <chart : PolarAreaSeries ItemsSource =" {Binding PlantDetails}" XBindingPath =" Direction" YBindingPath =" Flower"
305
+ <chart : PolarLineSeries ItemsSource =" {Binding PlantDetails}" XBindingPath =" Direction" YBindingPath =" Flower"
303
306
Label =" Flower" />
304
307
</chart : SfPolarChart >
305
308
```
306
309
307
310
###### C#
308
311
``` C#
309
- PolarAreaSeries series = new PolarAreaSeries ();
312
+ PolarLineSeries series = new PolarLineSeries ();
310
313
series .ItemsSource = (new ViewModel ()).PlantDetails ;
311
314
series .XBindingPath = " Direction" ;
312
315
series .YBindingPath = " Tree" ;
313
316
series .Label = " Tree" ;
314
317
315
- PolarAreaSeries series = new PolarAreaSeries ();
318
+ PolarLineSeries series = new PolarLineSeries ();
316
319
series .ItemsSource = (new ViewModel ()).PlantDetails ;
317
320
series .XBindingPath = " Direction" ;
318
321
series .YBindingPath = " Weed" ;
319
322
series .Label = " Weed" ;
320
323
321
- PolarAreaSeries series = new PolarAreaSeries ();
324
+ PolarLineSeries series = new PolarLineSeries ();
322
325
series .ItemsSource = (new ViewModel ()).PlantDetails ;
323
326
series .XBindingPath = " Direction" ;
324
327
series .YBindingPath = " Flower" ;
@@ -333,14 +336,14 @@ Tooltips are used to display information about a segment when a user hovers over
333
336
``` xaml
334
337
<chart : SfPolarChart >
335
338
...
336
- <chart : PolarAreaSeries EnableTooltip =" True" />
339
+ <chart : PolarLineSeries EnableTooltip =" True" />
337
340
...
338
341
</chart : SfPolarChart >
339
342
```
340
343
341
344
###### C#
342
345
``` C#
343
- PolarAreaSeries series = new PolarAreaSeries ();
346
+ PolarLineSeries series = new PolarLineSeries ();
344
347
series .EnableTooltip = true ;
345
348
```
346
349
@@ -375,16 +378,16 @@ The following code example gives you the complete code of above configurations.
375
378
</chart : SfPolarChart .PrimaryAxis>
376
379
377
380
<chart : SfPolarChart .SecondaryAxis>
378
- <chart : NumericalAxis />
381
+ <chart : NumericalAxis Maximum = " 100 " />
379
382
</chart : SfPolarChart .SecondaryAxis>
380
383
381
- <chart : PolarAreaSeries ItemsSource =" {Binding PlantDetails}" XBindingPath =" Direction" YBindingPath =" Tree"
384
+ <chart : PolarLineSeries ItemsSource =" {Binding PlantDetails}" XBindingPath =" Direction" YBindingPath =" Tree"
382
385
Label =" Tree" EnableTooltip =" True" ShowDataLabels =" True" />
383
386
384
- <chart : PolarAreaSeries ItemsSource =" {Binding PlantDetails}" XBindingPath =" Direction" YBindingPath =" Weed"
387
+ <chart : PolarLineSeries ItemsSource =" {Binding PlantDetails}" XBindingPath =" Direction" YBindingPath =" Weed"
385
388
Label =" Weed" EnableTooltip =" True" ShowDataLabels =" True" />
386
389
387
- <chart : PolarAreaSeries ItemsSource =" {Binding PlantDetails}" XBindingPath =" Direction" YBindingPath =" Flower"
390
+ <chart : PolarLineSeries ItemsSource =" {Binding PlantDetails}" XBindingPath =" Direction" YBindingPath =" Flower"
388
391
Label =" Flower" EnableTooltip =" True" ShowDataLabels =" True" />
389
392
</chart : SfPolarChart >
390
393
</Grid >
@@ -413,10 +416,13 @@ The following code example gives you the complete code of above configurations.
413
416
CategoryAxis primaryAxis = new CategoryAxis ();
414
417
chart .PrimaryAxis = primaryAxis ;
415
418
416
- NumericalAxis secondaryAxis = new NumericalAxis ();
419
+ NumericalAxis secondaryAxis = new NumericalAxis ()
420
+ {
421
+ Maximum = 100 ,
422
+ };
417
423
chart .SecondaryAxis = secondaryAxis ;
418
424
419
- PolarAreaSeries series = new PolarAreaSeries ()
425
+ PolarLineSeries series = new PolarLineSeries ()
420
426
{
421
427
ItemsSource = (new ViewModel ()).PlantDetails ,
422
428
XBindingPath = " Direction" ,
@@ -426,7 +432,7 @@ The following code example gives you the complete code of above configurations.
426
432
ShowDataLabels = " True"
427
433
};
428
434
429
- PolarAreaSeries series = new PolarAreaSeries ()
435
+ PolarLineSeries series = new PolarLineSeries ()
430
436
{
431
437
ItemsSource = (new ViewModel ()).PlantDetails ,
432
438
XBindingPath = " Direction" ,
@@ -436,7 +442,7 @@ The following code example gives you the complete code of above configurations.
436
442
ShowDataLabels = " True"
437
443
};
438
444
439
- PolarAreaSeries series = new PolarAreaSeries ()
445
+ PolarLineSeries series = new PolarLineSeries ()
440
446
{
441
447
ItemsSource = (new ViewModel ()).PlantDetails ,
442
448
XBindingPath = " Direction" ,
@@ -455,4 +461,5 @@ The following code example gives you the complete code of above configurations.
455
461
456
462
The following chart is created as a result of the previous codes.
457
463
458
- ![ Getting started for .NET MAUI Chart] ( Getting_start_images/MAUI_polar_chart.png )
464
+ <img width =" 554 " alt =" polar-README " src =" https://github.com/SyncfusionExamples/Creating-a-Getting-Started-application-for-NET-MAUI-Polar-Chart/assets/103025761/01e0c860-be28-4051-b9cb-1d87a4532f07 " >
465
+
0 commit comments