1 'encoding UTF-8 Do not remove or change this line!
2 '**************************************************************************
3 '* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 '* Copyright 2008 by Sun Microsystems, Inc.
7 '* OpenOffice.org - a multi-platform office productivity suite
9 '* $RCSfile: ch2_flexible_source_range_selection.inc,v $
13 '* last change: $Author: obo $ $Date: 2008-07-21 12:07:40 $
15 '* This file is part of OpenOffice.org.
17 '* OpenOffice.org is free software: you can redistribute it and/or modify
18 '* it under the terms of the GNU Lesser General Public License version 3
19 '* only, as published by the Free Software Foundation.
21 '* OpenOffice.org is distributed in the hope that it will be useful,
22 '* but WITHOUT ANY WARRANTY; without even the implied warranty of
23 '* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
24 '* GNU Lesser General Public License version 3 for more details
25 '* (a copy is included in the LICENSE file that accompanied this code).
27 '* You should have received a copy of the GNU Lesser General Public License
28 '* version 3 along with OpenOffice.org. If not, see
29 '* <http://www.openoffice.org/license.html>
30 '* for a copy of the LGPLv3 License.
32 '/***********************************************************************
34 '* owner : oliver.craemer@sun.com
36 '* short description : Updatetest for Flexible Source Range Selection in spreadsheets
38 '************************************************************************
40 ' #1 tDataRangeWizardCalc ' Updatetest for tabpage DataRange via chart wizard
41 ' #1 tDataSeriesWizardCalc ' Updatetest for tabpage DataSeries via chart wizard
42 ' #1 tDataRangeDialogCalc ' Updatetest for tabpage DataRange via data ranges dialog
43 ' #1 tDataSeriesDialogCalc ' Updatetest for tabpage DataSeries via data ranges dialog
44 ' #1 fOpenTestDocumentAndInsertChart ' Sub routine which is being used by two test cases
46 '\***********************************************************************
48 testcase tDataRangeWizardCalc
49 dim sDataRange as string
50 dim sInputFile as string
51 sInputFile = convertpath(gTestToolPath & "chart2/required/input/ch_flexrange01.ods")
52 printlog "Open test document gtesttoolpath/chart2/required/input/ch_flexrange01.ods"
53 if fOpenTestDocumentAndInsertChart(sInputFile) then
55 printlog "Choose the Chart type <i>bar</i> (should be the second in the top-down list)"
56 if fSetChartType( "bar" ) > 0 then
57 warnlog "Something went wrong setting chart type to BAR."
58 warnlog "Testcase aborted"
64 printlog "Switch to tabpage Data Range"
67 Kontext "TabChartTypeDataRange"
68 call DialogTest ( TabChartTypeDataRange )
69 printlog "Check that the data range in edit field has the value $ChartFlexRange.$B$3:$E$6"
70 Kontext "TabChartTypeDataRange"
71 sDataRange = DataRange.GetText
72 if sDataRange <> "$ChartFlexRange.$B$3:$E$6" then
73 warnlog "This is not the expected datarange, it is " & sDataRange & " but should be $ChartFlexRange.$B$3:$E$6"
75 printlog " Datarange is correct"
77 printlog "Check if -Data series in rows- is enabled"
78 if Rows.IsEnabled then
79 printlog " Data series in rows is enabled"
81 warnlog "Data series in rows is disabled"
83 printlog "Check if Data series in columns- is enabled and chosen"
84 if Columns.IsEnabled then
85 printlog " Data series in columns is enabled"
86 if Columns.IsChecked then
87 printlog " and checked"
89 warnlog "Data series in columns is not checked"
92 warnlog "Data series in columns is disabled"
94 printlog "Check if -First row as label- is enabled and checked"
95 if FirstRowAsLabel.IsEnabled then
96 printlog " First row as label is enabled"
97 if FirstRowAsLabel.IsChecked then
98 printlog " and checked"
100 warnlog "First row as label is not checked"
103 warnlog "First row as label is disabled"
105 printlog "Check if -First column as label- is enabled and not checked"
106 if FirstColumnAsLabel.IsEnabled then
107 printlog " First column as label is enabled"
108 if FirstColumnAsLabel.IsChecked then
109 warnlog "First column as label is checked"
111 printlog " and not checked"
114 warnlog "First column as label is disabled"
116 printlog "Press button Range Chooser"
117 SelectDataRange.Click
118 printlog "Enter invalid range $ChartFlexRange.$B$3:$E$0 and close Range Chooser"
119 Kontext "AcceptOrRejectChangesArea"
120 AreaEditField.SetText "$ChartFlexRange.$B$3:$E$0"
122 printlog "Check if -Data series in rows- is disabled"
123 Kontext "TabChartTypeDataRange"
124 if NOT Rows.IsEnabled then
125 printlog " Data series in rows is disabled"
127 warnlog "Data series in rows is enabled, but should be disabled"
129 printlog "Check if -Data series in columns- is disabled"
130 if NOT Columns.IsEnabled then
131 printlog " Data series in columns is disabled"
133 warnlog "Data series in columns is enabled, but should be disabled"
135 printlog "Check if -First row as label- is disabled"
136 if NOT FirstRowAsLabel.IsEnabled then
137 printlog " First row as label is disabled"
139 warnlog "First row as label is enabled, but should be disabled"
141 printlog "Check if -First column as label- is disabled"
142 if NOT FirstColumnAsLabel.IsEnabled then
143 printlog " First Column as label is disabled"
145 warnlog "First Column as label is enabled, but should be disabled"
147 printlog "Check if Back, Next and Finish does not work"
148 Kontext "ChartWizard"
150 Kontext "TabChartTypeDataRange"
151 if FirstColumnAsLabel.IsVisible then
152 printlog " Success: Back button does not work"
154 warnlog "Back button is not functionless"
155 Kontext "ChartWizard"
158 printlog "Enter valid range $ChartFlexRange.$B$3:$E$6"
159 Kontext "TabChartTypeDataRange"
160 DataRange.SetText "$ChartFlexRange.$B$3:$E$6"
161 printlog "Check if -Data series in rows- is enabled"
162 if Rows.IsEnabled then
163 printlog " Data series in rows is enabled"
165 warnlog "Data series in rows is disabled"
167 printlog "Check if -Data series in columns- is enabled and chosen"
168 if Columns.IsEnabled then
169 printlog " Data series in columns is enabled"
170 if Columns.IsChecked then
171 printlog " and checked"
173 warnlog "Data series in columns is not checked"
176 warnlog "Data series in rows is disabled"
178 printlog "Check if -First row as label- is enabled and checked"
179 if FirstRowAsLabel.IsEnabled then
180 printlog " First row as label is enabled"
181 if FirstRowAsLabel.IsChecked then
182 printlog " and checked"
184 warnlog "First row as label is not checked"
187 warnlog "First row as label is disabled"
189 printlog "Check if -First column as label- is enabled and not checked"
190 if FirstColumnAsLabel.IsEnabled then
191 printlog " First column as label is enabled"
192 if FirstColumnAsLabel.IsChecked then
193 warnlog "First column as label is checked"
195 printlog " and not checked"
198 warnlog "First column as label is disabled"
200 printlog "Press Cancel button"
201 Kontext "ChartWizard"
203 printlog "Close document"
206 warnlog "It was not possible to open the test document."
210 '-------------------------------------------------------------------------
212 testcase tDataSeriesWizardCalc
213 dim sInputFile as string
214 dim iDataSeries as integer
215 dim sDataRanges as string
216 dim sRangeFor as string
217 dim sCategories as string
218 sInputFile = convertpath(gTestToolPath & "chart2/required/input/ch_flexrange02.ods")
219 printlog "Open test document gTestToolPath/chart2/required/input/ch_flexrange02.ods"
220 if fOpenTestDocumentAndInsertChart(sInputFile) then
222 printlog "Choose the Chart type XY (SCATTER) (should be the second in the top-down list)"
223 if fSetChartType( "xy" ) > 0 then
224 warnlog "Something went wrong setting chart type to XY (SCATTER)."
225 Kontext "ChartWizard"
230 Kontext "ChartWizard"
231 printlog "Click on Next button"
233 printlog "Click on Next button"
235 Kontext "TabChartTypeDataSeries"
236 if RangeFor.IsVisible then
237 printlog " Switching to tabpage was successfull"
239 warnlog "Switching to tabpage Data Series failed"
240 Kontext "ChartWizard"
245 call DialogTest ( TabChartTypeDataSeries )
246 printlog "Check if the data series listbox is enabled and contains three entries"
247 iDataSeries = DataSeries.GetItemCount
248 if iDataSeries = 3 then
249 printlog " All 3 data series are available"
251 warnlog "There are " & iDataSeries & " data series instead of 3"
253 printlog "Check if the ADD button is enabled and click the button"
254 if AddButton.IsEnabled then
255 printlog " ADD button is enabled"
258 warnlog "ADD button is not enabled"
260 printlog "Check if there are now four entries in the data series listbox"
261 iDataSeries = DataSeries.GetItemCount
262 if iDataSeries = 4 then
263 printlog " Adding a data series was successfull"
265 warnlog "There are " & iDataSeries & " data series instead of 4"
267 printlog "Check if the second data series was added below the highlighted one"
268 if DataSeries.GetSelIndex = 2 then
269 printlog " The new data series was inserted below the highlighted (first) one"
271 warnlog "The new dataseries was not inserted below the highlighted one"
273 printlog "Check if the REMOVE button is enabled and click the button"
274 if RemoveButton.IsEnabled then
275 printlog " REMOVE button is enabled"
278 warnlog "REMOVE button is not enabled"
280 printlog "Check if there are now 3 entries in the data series listbox"
281 iDataSeries = DataSeries.GetItemCount
282 if iDataSeries = 3 then
283 printlog " Removing a data series was successfull"
285 warnlog "There are " & iDataSeries & " data series instead of 3"
287 printlog "Use UP button on last data series and verify that it it disabled on first entry"
289 if MoveUp.IsEnabled then
290 printlog " The MoveUp button is enabled"
291 printlog "Click on Move Up button twice."
295 warnlog "The MoveUp button is disabled"
297 if DataSeries.GetSelIndex = 1 then
298 printlog " Moving data series was successfull"
299 if MoveUp.IsEnabled then
300 warnlog "MoveUp button is not disabled on first entry"
302 printlog " and MoveUp button is disabled on first enty"
305 warnlog "Moving data series was not successfull"
307 printlog "Use DOWN button and verify that it is disabled on last entry"
309 if MoveDown.IsEnabled then
310 printlog " The MoveDown button is enabled"
311 printlog "Click Move Down button twice"
315 warnlog "The MoveDown button is disabled"
317 if DataSeries.GetSelIndex = 3 then
318 printlog " Moving data series was successfull"
319 if MoveDown.IsEnabled then
320 warnlog "MoveDown button is not disabled on first entry"
322 printlog " and MoveDown button is disabled on first enty"
325 warnlog "Moving data series was not successfull"
327 printlog "Select first entry in Data Ranges"
329 printlog "Verify that the range matches the one in edit field"
330 'GetSelText(line,column) is a new parameter since CWS:SRC680gh13
331 'Instead of 1,2 there must be 1,4 used becqause there are two invisible
332 'label-columns in that treelist-box
333 sDataRanges = DataRanges.GetSelText (1,4)
334 sRangeFor = RangeFor.GetText
335 if sDataRanges = sRangeFor then
336 printlog " Both ranges are matching"
338 warnlog "The ranges does not match: " & sDataRanges & sRangeFor
340 printlog "Select second entry in Data Ranges"
342 printlog "Check that the range in the edit field has changed, too."
343 'GetSelText(line,column) is a new parameter since CWS:SRC680gh13
344 'Instead of 1,2 there must be 1,4 used becqause there are two invisible
345 'label-columns in that treelist-box
346 sDataRanges = DataRanges.GetSelText (1,4)
347 sRangeFor = RangeFor.GetText
348 if sDataRanges = sRangeFor then
349 printlog " Both ranges are matching"
351 warnlog "The ranges does not match" & sDataRanges & sRangeFor
353 printlog "Change the range in edit field"
354 RangeFor.SetText "$ChartFlexRange.$D$5:$D$6;$ChartFlexRange.$D$8"
355 printlog "Check that the range in Data Ranges has changed, too"
356 'GetSelText(line,column) is a new parameter since CWS:SRC680gh13
357 'Instead of 1,2 there must be 1,4 used becqause there are two invisible
358 'label-columns in that treelist-box
359 sDataRanges = DataRanges.GetSelText (1,4)
360 if sDataRanges = "$ChartFlexRange.$D$5:$D$6;$ChartFlexRange.$D$8" then
361 printlog " The data range has also changed"
363 warnlog "The data range has not changed"
365 printlog "Click on Range Chooser and change the range"
367 Kontext "AcceptOrRejectChangesArea"
368 printlog "Enter $ChartFlexRange.$D$5:$D$6 in edit field"
369 AreaEditField.SetText "$ChartFlexRange.$D$5:$D$6"
370 printlog "Click on Shirnk button"
372 printlog "Check if the range in Data ranges has changed"
373 Kontext "TabChartTypeDataSeries"
374 'GetSelText(line,column) is a new parameter since CWS:SRC680gh13
375 'Instead of 1,2 there must be 1,4 used becqause there are two invisible
376 'label-columns in that treelist-box
377 sDataRanges = DataRanges.GetSelText (1,4)
378 if sDataRanges = "$ChartFlexRange.$D$5:$D$6" then
379 printlog " The data range has also changed"
381 warnlog "The data range has not changed"
383 printlog "Edit range for Data Labels"
384 printlog "Set text $ChartFlexRange.$C$15:$C$16 in categories"
385 Categories.SetText "$ChartFlexRange.$C$15:$C$16"
386 sCategories = Categories.GetText
387 printlog "Validate the changes have not been modified"
388 if sCategories = "$ChartFlexRange.$C$15:$C$16" then
389 printlog " The range has been modified"
391 warnlog "Modifiing the range was not successfull"
393 printlog "Click on Range Chooser and change the range"
394 SelectCategories.Click
395 Kontext "AcceptOrRejectChangesArea"
396 printlog "Set text $ChartFlexRange.$C$5:$C$6 in the edit field"
397 AreaEditField.SetText "$ChartFlexRange.$C$5:$C$6"
398 printlog "Click on Shrink button"
400 printlog "Verify that the range is taken"
401 Kontext "TabChartTypeDataSeries"
402 sCategories = Categories.GetText
403 if sCategories = "$ChartFlexRange.$C$5:$C$6" then
404 printlog " The range has been modified"
406 warnlog "Modifiing the range was not successfull"
408 printlog "Enter invalid range $ChartFlexRange.$C$5:$C$"
409 Categories.SetText "$ChartFlexRange.$C$5:$C$"
410 Kontext "ChartWizard"
411 printlog "Click on the Back button"
413 Kontext "TabChartTypeDataSeries"
414 if Categories.IsVisible then
415 printlog " Success: Back button is disabled"
417 warnlog "Back button is not functionless"
418 Kontext "ChartWizard"
421 printlog "Enter $ChartFlexRange.$C$5:$C$6 - a valid range"
422 Categories.SetText "$ChartFlexRange.$C$5:$C$6"
423 printlog "Press Range Chooser"
424 SelectCategories.Click
425 printlog "Press <END>-key"
426 Kontext "AcceptOrRejectChangesArea"
427 AreaEditField.TypeKeys "<END>"
428 printlog "Enter a semicolon and the second range $ChartFlexRange.$C$8"
429 AreaEditField.TypeKeys ";$ChartFlexRange.$C$8"
430 printlog "Close Range Chooser"
432 printlog "Verify that there is a multiple range"
433 Kontext "TabChartTypeDataSeries"
434 sCategories = Categories.GetText
435 if sCategories = "$ChartFlexRange.$C$5:$C$6;$ChartFlexRange.$C$8" then
436 printlog " The range has been modified to a multiple range"
438 warnlog "Modifiing the range was not successfull"
440 printlog "Press Cancel button"
441 Kontext "ChartWizard"
443 printlog "Close document"
446 warnlog "It was not possible to open the test document."
450 '-------------------------------------------------------------------------
452 testcase tDataRangeDialogCalc
453 dim sDataRange as string
454 dim sInputFile as string
455 sInputFile = convertpath(gTestToolPath & "chart2/required/input/ch_flexrange03.ods" )
456 printlog "Open test document gTestToolPath/chart2/required/input/ch_flexrange03.ods"
457 if fOpenTestDocumentAndSelectDataRange(sInputFile) then
458 printlog "Check if the data range in edit field is $ChartFlexRange.$D$4:$G$6;$ChartFlexRange.$C$5:$G$6;$ChartFlexRange.$C$4"
459 Kontext "TabChartTypeDataRange"
460 sDataRange = DataRange.GetText
461 if sDataRange <> "$ChartFlexRange.$C$4:$G$6" then
462 warnlog "This is not the expected datarange, it is " & sDataRange & " but should be $ChartFlexRange.$C$4:$G$6"
464 printlog " Datarange is correct"
466 printlog "Check if -Data series in columns- is enabled"
467 if Columns.IsEnabled then
468 printlog " Data series in columns is enabled"
470 warnlog "Data series in columns is disabled"
472 printlog "Check if -Data series in columns- is enabled and chosen"
473 if Rows.IsEnabled then
474 printlog " Data series in rows is enabled"
475 if rows.IsChecked then
476 printlog " and checked"
478 warnlog "Data series in rows is not checked"
481 warnlog "Data series in rows is disabled"
483 printlog "Check if -First row as label- is enabled and checked"
484 if FirstRowAsLabel.IsEnabled then
485 printlog " First row as label is enabled"
486 if FirstRowAsLabel.IsChecked then
487 printlog " and checked"
489 warnlog "First row as label is not checked"
492 warnlog "First row as label is disabled"
494 printlog "Check if -First column as label- is enabled and checked"
495 if FirstColumnAsLabel.IsEnabled then
496 printlog " First column as label is enabled"
497 if FirstColumnAsLabel.IsChecked then
498 printlog " and checked"
500 warnlog "First column as label is not checked"
503 warnlog "First column as label is disabled"
505 printlog "Press button Range Chooser"
506 SelectDataRange.Click
507 printlog "Enter $ChartFlexRange.$B$3:$E$0 in Range Chooser and close Range Chooser"
508 Kontext "AcceptOrRejectChangesArea"
509 AreaEditField.SetText "$ChartFlexRange.$B$3:$E$0"
511 printlog "Check if -Data series in rows- is disabled"
512 Kontext "TabChartTypeDataRange"
513 if NOT Rows.IsEnabled then
514 printlog " Data series in rows is disabled"
516 warnlog "Data series in rows is enabled, but should be disabled"
518 printlog "Check if -Data series in columns- is disabled"
519 if NOT Columns.IsEnabled then
520 printlog " Data series in columns is disabled"
522 warnlog "Data series in columns is enabled, but should be disabled"
524 printlog "Check if -First row as label- is disabled"
525 if NOT FirstRowAsLabel.IsEnabled then
526 printlog " First row as label is disabled"
528 warnlog "First row as label is enabled, but should be disabled"
530 printlog "Check if -First column as label- is disabled"
531 if NOT FirstColumnAsLabel.IsEnabled then
532 printlog " First Column as label is disabled"
534 warnlog "First Column as label is enabled, but should be disabled"
536 printlog "Check if OK button is disabled"
538 Kontext "TabChartTypeDataRange"
539 TabChartTypeDataRange.OK
540 warnlog "The OK button is not disabled"
543 printlog " The OK button is disabled"
545 printlog "Enter a valid range"
546 Kontext "TabChartTypeDataRange"
547 DataRange.SetText "$ChartFlexRange.$C$4:$G$6;$ChartFlexRange.$C$8:$G$8"
548 printlog "Check if -Data series in columns- is enabled"
549 if Columns.IsEnabled then
550 printlog " Data series in columns is enabled"
552 warnlog "Data series in columns is disabled"
554 printlog "Check if -Data series in columns- is enabled and chosen"
555 if Rows.IsEnabled then
556 printlog " Data series in rows is enabled"
557 if rows.IsChecked then
558 printlog " and checked"
560 warnlog "Data series in rows is not checked"
563 warnlog "Data series in rows is disabled"
565 printlog "Check if -First row as label- is enabled and checked"
566 if FirstRowAsLabel.IsEnabled then
567 printlog " First row as label is enabled"
568 if FirstRowAsLabel.IsChecked then
569 printlog " and checked"
571 warnlog "First row as label is not checked"
574 warnlog "First row as label is disabled"
576 printlog "Check if -First column as label- is enabled and checked"
577 if FirstColumnAsLabel.IsEnabled then
578 printlog " First column as label is enabled"
579 if FirstColumnAsLabel.IsChecked then
580 printlog " and checked"
582 warnlog "First column as label is not checked"
585 warnlog "First column as label is disabled"
587 printlog "Press Cancel button"
588 Kontext "TabChartTypeDataRange"
589 TabChartTypeDataRange.Cancel
590 printlog "Close document"
593 warnlog "It was not possible to open the test document."
597 '-------------------------------------------------------------------------
599 testcase tDataSeriesDialogCalc
600 dim sInputFile as string
601 dim iDataSeries as integer
602 dim sDataRanges as string
603 dim sRangeFor as string
604 dim sCategories as string
605 sInputFile = convertpath(gTestToolPath & "chart2/required/input/ch_flexrange04.ods")
606 printlog "Open test document gTestToolPath/chart2/required/input/ch_flexrange04.ods"
607 if fOpenTestDocumentAndSelectDataRange(sInputFile) then
609 Active.SetPage TabChartTypeDataSeries
610 Kontext "TabChartTypeDataSeries"
611 printlog "Check if the data series listbox is enabled and contains one entry"
612 iDataSeries = DataSeries.GetItemCount
613 if iDataSeries = 1 then
614 printlog " One data serie is available"
616 warnlog "There are " & iDataSeries & " data series instead of 1"
618 printlog "Check if the ADD button is enabled and click the button"
619 if AddButton.IsEnabled then
620 printlog " ADD button is enabled"
623 warnlog "ADD button is not enabled"
625 printlog "Check if there are now two entries in the data series listbox"
626 iDataSeries = DataSeries.GetItemCount
627 if iDataSeries = 2 then
628 printlog " Adding a data series was successfull"
630 warnlog "There are " & iDataSeries & " data series instead of 2"
632 printlog "Check if the new data series was added below the highlighted one"
633 if DataSeries.GetSelIndex = 2 then
634 printlog " The new data series was inserted below the highlighted (first) one"
636 warnlog "The new dataseries was not inserted below the highlighted one"
638 printlog "Use UP button on last data series and verify that it it disabled on first entry"
640 if MoveUp.IsEnabled then
641 printlog " The MoveUp button is enabled"
644 warnlog "The MoveUp button is disabled"
646 if DataSeries.GetSelIndex = 1 then
647 printlog " Moving data series was successfull"
648 if MoveUp.IsEnabled then
649 warnlog "MoveUp button is not disabled on first entry"
651 printlog " and MoveUp button is disabled on first enty"
654 warnlog "Moving data series was not successfull"
656 printlog "Use DOWN button and verify that it is disabled on last entry"
658 if MoveDown.IsEnabled then
659 printlog " The MoveDown button is enabled"
662 warnlog "The MoveDown button is disabled"
664 if DataSeries.GetSelIndex = 2 then
665 printlog " Moving data series was successfull"
666 if MoveDown.IsEnabled then
667 warnlog "MoveDown button is not disabled on first entry"
669 printlog " and MoveDown button is disabled on first enty"
672 warnlog "Moving data series was not successfull"
674 printlog "Check if the REMOVE button is enabled and click the button"
675 if RemoveButton.IsEnabled then
676 printlog " REMOVE button is enabled"
679 warnlog "REMOVE button is not enabled"
681 printlog "Check if there are now one entry in the data series listbox"
682 iDataSeries = DataSeries.GetItemCount
683 if iDataSeries = 1 then
684 printlog " Removing a data series was successfull"
686 warnlog "There are " & iDataSeries & " data series instead of 1"
688 printlog "Select first entry in Data Ranges"
690 printlog "Verify that the range for NAME matches the one in edit field"
691 'GetSelText(line,column) is a new parameter since CWS:SRC680gh13
692 'Instead of 1,2 there must be 1,4 used becqause there are two invisible
693 'label-columns in that treelist-box
694 sDataRanges = DataRanges.GetSelText(1,4)
695 sRangeFor = RangeFor.GetText
696 if sDataRanges = sRangeFor then
697 printlog " Both ranges are matching"
699 warnlog "The ranges does not match: " & sDataRanges & sRangeFor
701 printlog "Select second entry in Data Ranges"
703 printlog "Check that the range in the edit field has changed too"
704 'GetSelText(line,column) is a new parameter since CWS:SRC680gh13
705 'Instead of 1,2 there must be 1,4 used becqause there are two invisible
706 'label-columns in that treelist-box
707 sDataRanges = DataRanges.GetSelText(1,4)
708 sRangeFor = RangeFor.GetText
709 if sDataRanges = sRangeFor then
710 printlog " Both ranges are matching"
712 warnlog "The ranges does not match" & sDataRanges & sRangeFor
714 printlog "Change the range in edit field"
715 RangeFor.SetText "$ChartFlexRange.$D$5:$D$10"
716 printlog "Check that the range in Data Ranges has changed too"
717 'GetSelText(line,column) is a new parameter since CWS:SRC680gh13
718 'Instead of 1,2 there must be 1,4 used becqause there are two invisible
719 'label-columns in that treelist-box
720 sDataRanges = DataRanges.GetSelText (1,4)
721 if sDataRanges = "$ChartFlexRange.$D$5:$D$10" then
722 printlog " The data range has also changed"
724 warnlog "The data range has not changed"
726 printlog "Click on Range Chooser and change the range"
728 Kontext "AcceptOrRejectChangesArea"
729 AreaEditField.SetText "$ChartFlexRange.$D$5:$D$12"
731 printlog "Check if the range in Data ranges has changed"
732 Kontext "TabChartTypeDataSeries"
733 'GetSelText(line,column) is a new parameter since CWS:SRC680gh13
734 'Instead of 1,2 there must be 1,4 used becqause there are two invisible
735 'label-columns in that treelist-box
736 sDataRanges = DataRanges.GetSelText (1,4)
737 if sDataRanges = "$ChartFlexRange.$D$5:$D$12" then
738 printlog " The data range has also changed"
740 warnlog "The data range has not changed"
742 printlog "Edit range for Categories"
743 Categories.SetText "$ChartFlexRange.$B$5:$B$10"
744 sCategories = Categories.GetText
745 if sCategories = "$ChartFlexRange.$B$5:$B$10" then
746 printlog " The range has been modified"
748 warnlog "Modifiing the range was not successfull"
750 printlog "Click on Range Chooser and change the range to $ChartFlexRange.$B$5:$B$12"
751 SelectCategories.Click
752 Kontext "AcceptOrRejectChangesArea"
753 AreaEditField.SetText "$ChartFlexRange.$B$5:$B$12"
755 printlog "Verify that the range is taken"
756 Kontext "TabChartTypeDataSeries"
757 sCategories = Categories.GetText
758 if sCategories = "$ChartFlexRange.$B$5:$B$12" then
759 printlog " The range has been modified"
761 warnlog "Modifiing the range was not successfull"
763 printlog "Enter $ChartFlexRange.$B$5:$B$ as an invalid range"
764 Categories.SetText "$ChartFlexRange.$B$5:$B$"
765 printlog "Check that the OK button does not work"
767 Kontext "TabChartTypeDataSeries"
768 TabChartTypeDataSeries.OK
769 warnlog "The OK button is not disabled"
772 printlog " The OK button is disabled"
774 printlog "Enter as valid range $ChartFlexRange.$B$5:$B$12"
775 Kontext "TabChartTypeDataSeries"
776 Categories.SetText "$ChartFlexRange.$B$5:$B$12"
777 printlog "Press Range Chooser"
778 SelectCategories.Click
779 printlog "Move cursor to the end"
780 Kontext "AcceptOrRejectChangesArea"
781 AreaEditField.TypeKeys "<END>"
782 printlog "Enter a semicolon and the second range $ChartFlexRange.$B$14"
783 AreaEditField.TypeKeys ";$ChartFlexRange.$B$14"
784 printlog "Close Range Chooser"
786 printlog "Verify that there is a multiple range"
787 Kontext "TabChartTypeDataSeries"
788 sCategories = Categories.GetText
789 if sCategories = "$ChartFlexRange.$B$5:$B$12;$ChartFlexRange.$B$14" then
790 printlog " The range has been modified to a multiple range"
792 warnlog "Modifiing the range was not successfull"
794 printlog "Press Cancel button"
795 Kontext "TabChartTypeDataSeries"
796 TabChartTypeDataSeries.Cancel
797 printlog "Close document"
800 warnlog "It was not possible to open the test document."