Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to click a radio button inside a webtable
#1
Not Solved
I am having a webtable in that i am having 2 rows and 1 col...

i am having one value in (1,1) other value in (2,1)
Beside (1,1) i am having a radio button
Beside (2,1) i am having a radio button
When i spy that radio button it is identifying as webelement.

now i need to click on one radio button which matches my data from data base


Help me...

(10-15-2012, 01:49 PM)silpavinod Wrote: I am having a webtable in that i am having 2 rows and 1 col...

i am having one value in (1,1) other value in (2,1)
Beside (1,1) i am having a radio button
Beside (2,1) i am having a radio button
When i spy that radio button it is identifying as webelement.

now i need to click on one radio button which matches my data from data base


Help me...

I worked in this way..

Code:
For i=1 to 2

val=Browser("qvolume").Page("qvolume").WebTable("I am happy with the sound.").GetCellData(i,1)
Msgbox val
My this i got the values from the 1st col...

For EX: i want to click on a radio button beside the value but the radio button is identiying as webelement and it is not showing in any row and col when i use standard checkpoint.
Reply
#2
Not Solved
Check your QTP add-ins are loaded correctly or not ?

Srinath
Reply
#3
Not Solved
Unless u select the radio button spy will not recognize it. Try to spy the radio button after selection.



(10-15-2012, 01:49 PM)silpavinod Wrote: I am having a webtable in that i am having 2 rows and 1 col...

i am having one value in (1,1) other value in (2,1)
Beside (1,1) i am having a radio button
Beside (2,1) i am having a radio button
When i spy that radio button it is identifying as webelement.

now i need to click on one radio button which matches my data from data base


Help me...

(10-15-2012, 01:49 PM)silpavinod Wrote: I am having a webtable in that i am having 2 rows and 1 col...

i am having one value in (1,1) other value in (2,1)
Beside (1,1) i am having a radio button
Beside (2,1) i am having a radio button
When i spy that radio button it is identifying as webelement.

now i need to click on one radio button which matches my data from data base


Help me...

I worked in this way..

For i=1 to 2

val=Browser("qvolume").Page("qvolume").WebTable("I am happy with the sound.").GetCellData(i,1)
Msgbox val
My this i got the values from the 1st col...

For EX: i want to click on a radio button beside the value but the radio button is identiying as webelement and it is not showing in any row and col when i use standard checkpoint.
Reply
#4
Not Solved
(10-15-2012, 01:49 PM)silpavinod Wrote: I am having a webtable in that i am having 2 rows and 1 col...

i am having one value in (1,1) other value in (2,1)
Beside (1,1) i am having a radio button
Beside (2,1) i am having a radio button
When i spy that radio button it is identifying as webelement.

now i need to click on one radio button which matches my data from data base


Help me...

(10-15-2012, 01:49 PM)silpavinod Wrote: I am having a webtable in that i am having 2 rows and 1 col...

i am having one value in (1,1) other value in (2,1)
Beside (1,1) i am having a radio button
Beside (2,1) i am having a radio button
When i spy that radio button it is identifying as webelement.

now i need to click on one radio button which matches my data from data base


Help me...

I worked in this way..

For i=1 to 2

val=Browser("qvolume").Page("qvolume").WebTable("I am happy with the sound.").GetCellData(i,1)
Msgbox val
My this i got the values from the 1st col...

For EX: i want to click on a radio button beside the value but the radio button is identiying as webelement and it is not showing in any row and col when i use standard checkpoint.

Hi,

If u want to click on radio btn then istead of using Getcell data use ChildItem......U can check QTP help file for its syntax.

Let me know in case of any queries.

Regards,
Sankalp
Reply
#5
Not Solved
(10-15-2012, 03:26 PM)sshukla12 Wrote:
(10-15-2012, 01:49 PM)silpavinod Wrote: I am having a webtable in that i am having 2 rows and 1 col...

i am having one value in (1,1) other value in (2,1)
Beside (1,1) i am having a radio button
Beside (2,1) i am having a radio button
When i spy that radio button it is identifying as webelement.

now i need to click on one radio button which matches my data from data base


Help me...

(10-15-2012, 01:49 PM)silpavinod Wrote: I am having a webtable in that i am having 2 rows and 1 col...

i am having one value in (1,1) other value in (2,1)
Beside (1,1) i am having a radio button
Beside (2,1) i am having a radio button
When i spy that radio button it is identifying as webelement.

now i need to click on one radio button which matches my data from data base


Help me...

I worked in this way..

For i=1 to 2

val=Browser("qvolume").Page("qvolume").WebTable("I am happy with the sound.").GetCellData(i,1)
Msgbox val
My this i got the values from the 1st col...

For EX: i want to click on a radio button beside the value but the radio button is identiying as webelement and it is not showing in any row and col when i use standard checkpoint.

Hi,

If u want to click on radio btn then istead of using Getcell data use ChildItem......U can check QTP help file for its syntax.

Let me know in case of any queries.

Regards,
Sankalp

I can use childitems if the webelements are in webtable.. here when i check the webtable it has only 2 rows 1 col...
(1,1)--value1
(2,1)--value2

i am not bale to see the webelements

(10-15-2012, 02:28 PM)srinath_QTP Wrote: Check your QTP add-ins are loaded correctly or not ?

Srinath

Hi srinath,

I am using trail version to check whether QTP supports our application or not...hope addins is the problem for this issue..

Thanks for the reply
Reply
#6
Not Solved
(10-15-2012, 04:08 PM)silpavinod Wrote:
(10-15-2012, 03:26 PM)sshukla12 Wrote:
(10-15-2012, 01:49 PM)silpavinod Wrote: I am having a webtable in that i am having 2 rows and 1 col...

i am having one value in (1,1) other value in (2,1)
Beside (1,1) i am having a radio button
Beside (2,1) i am having a radio button
When i spy that radio button it is identifying as webelement.

now i need to click on one radio button which matches my data from data base


Help me...

(10-15-2012, 01:49 PM)silpavinod Wrote: I am having a webtable in that i am having 2 rows and 1 col...

i am having one value in (1,1) other value in (2,1)
Beside (1,1) i am having a radio button
Beside (2,1) i am having a radio button
When i spy that radio button it is identifying as webelement.

now i need to click on one radio button which matches my data from data base


Help me...

I worked in this way..

For i=1 to 2

val=Browser("qvolume").Page("qvolume").WebTable("I am happy with the sound.").GetCellData(i,1)
Msgbox val
My this i got the values from the 1st col...

For EX: i want to click on a radio button beside the value but the radio button is identiying as webelement and it is not showing in any row and col when i use standard checkpoint.

Hi,

If u want to click on radio btn then istead of using Getcell data use ChildItem......U can check QTP help file for its syntax.

Let me know in case of any queries.

Regards,
Sankalp

I can use childitems if the webelements are in webtable.. here when i check the webtable it has only 2 rows 1 col...
(1,1)--value1
(2,1)--value2

i am not bale to see the webelements

(10-15-2012, 02:28 PM)srinath_QTP Wrote: Check your QTP add-ins are loaded correctly or not ?

Srinath

Hi srinath,

I am using trail version to check whether QTP supports our application or not...hope addins is the problem for this issue..

Thanks for the reply

Hi Srinath,

i tried in lincesed version with addins but same problem... i got one solution please suggest me whether i am correct r not...

I understood that the development is done like they placed all objects in one controll... there is no difference in any radio button... so i think i can work by x and y coordinates... hope no other way..
Reply
#7
Not Solved
I suggest not to go with X and Y co-ordinates. It may not work properly if you are porting the code from your machine to other machine.
Reply
#8
Not Solved
(10-15-2012, 05:18 PM)silpavinod Wrote:
(10-15-2012, 04:08 PM)silpavinod Wrote:
(10-15-2012, 03:26 PM)sshukla12 Wrote:
(10-15-2012, 01:49 PM)silpavinod Wrote: I am having a webtable in that i am having 2 rows and 1 col...

i am having one value in (1,1) other value in (2,1)
Beside (1,1) i am having a radio button
Beside (2,1) i am having a radio button
When i spy that radio button it is identifying as webelement.

now i need to click on one radio button which matches my data from data base


Help me...

(10-15-2012, 01:49 PM)silpavinod Wrote: I am having a webtable in that i am having 2 rows and 1 col...

i am having one value in (1,1) other value in (2,1)
Beside (1,1) i am having a radio button
Beside (2,1) i am having a radio button
When i spy that radio button it is identifying as webelement.

now i need to click on one radio button which matches my data from data base


Help me...

I worked in this way..

For i=1 to 2

val=Browser("qvolume").Page("qvolume").WebTable("I am happy with the sound.").GetCellData(i,1)
Msgbox val
My this i got the values from the 1st col...

For EX: i want to click on a radio button beside the value but the radio button is identiying as webelement and it is not showing in any row and col when i use standard checkpoint.

Hi,

If u want to click on radio btn then istead of using Getcell data use ChildItem......U can check QTP help file for its syntax.

Let me know in case of any queries.

Regards,
Sankalp

I can use childitems if the webelements are in webtable.. here when i check the webtable it has only 2 rows 1 col...
(1,1)--value1
(2,1)--value2

i am not bale to see the webelements

(10-15-2012, 02:28 PM)srinath_QTP Wrote: Check your QTP add-ins are loaded correctly or not ?

Srinath

Hi srinath,

I am using trail version to check whether QTP supports our application or not...hope addins is the problem for this issue..

Thanks for the reply

Hi Srinath,

i tried in lincesed version with addins but same problem... i got one solution please suggest me whether i am correct r not...

I understood that the development is done like they placed all objects in one controll... there is no difference in any radio button... so i think i can work by x and y coordinates... hope no other way..

is that .net control or third party control ...can u check with your Dev ?

Srinath
Reply
#9
Not Solved
(10-15-2012, 05:39 PM)ricks_ngl Wrote: I suggest not to go with X and Y co-ordinates. It may not work properly if you are porting the code from your machine to other machine.

Is there any other way?
Reply
#10
Not Solved
(10-15-2012, 03:26 PM)sshukla12 Wrote:
(10-15-2012, 01:49 PM)silpavinod Wrote: I am having a webtable in that i am having 2 rows and 1 col...

i am having one value in (1,1) other value in (2,1)
Beside (1,1) i am having a radio button
Beside (2,1) i am having a radio button
When i spy that radio button it is identifying as webelement.

now i need to click on one radio button which matches my data from data base


Help me...

(10-15-2012, 01:49 PM)silpavinod Wrote: I am having a webtable in that i am having 2 rows and 1 col...

i am having one value in (1,1) other value in (2,1)
Beside (1,1) i am having a radio button
Beside (2,1) i am having a radio button
When i spy that radio button it is identifying as webelement.

now i need to click on one radio button which matches my data from data base


Help me...

I worked in this way..

For i=1 to 2

val=Browser("qvolume").Page("qvolume").WebTable("I am happy with the sound.").GetCellData(i,1)
Msgbox val
My this i got the values from the 1st col...

For EX: i want to click on a radio button beside the value but the radio button is identiying as webelement and it is not showing in any row and col when i use standard checkpoint.

Hi,

If u want to click on radio btn then istead of using Getcell data use ChildItem......U can check QTP help file for its syntax.

Let me know in case of any queries.

Regards,
Sankalp

Make sure you Highlight object whenever QTP is not able to identify.
Usually try spying on the radio-button, i think you are spying Label next to radio button.

Please try below code,
Code:
db_value="xxx"

If Browser(...).Page(...).WebTable(...).GetCellData(1,1) = db_value Then
  Browser(...).Page(...).WebTable(...).ChildItem(1,1,"WebRadioGroup",1).Select "#0"
Else
Browser(...).Page(...).WebTable(...).ChildItem(2,1,"WebRadioGroup",1).Select "#1"

End If
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
MyBB how can i automatically click ok button in msgbox popup test 11 24,859 07-12-2022, 11:50 PM
Last Post: akash warke
  no action on click for particular wpf button jlavrecka 1 1,417 05-21-2020, 11:33 PM
Last Post: jlavrecka
  Help for instruction to click on Skip button in the warning message vijilesh 0 1,504 09-16-2018, 03:48 PM
Last Post: vijilesh
  Set Value in JavaEdit Inside JavaTable yonobev 9 12,971 11-08-2017, 11:12 PM
Last Post: lotos
  Objects inside WpfList shinji458 23 22,284 11-08-2017, 10:54 PM
Last Post: lotos

Forum Jump:


Users browsing this thread: 1 Guest(s)