Button Click event inside a repeating table

M

Moe.Vafaei

Hi,
Very appreciate your help on the issue I've in InfoPath 2007:

I've a repeating table and in each row I've a date picker, a button, and 3
more text boxes. I'm using code for button click event and call a web service
to populate text boxes based on the date selected. This works fine only for
the first row. It does not work for the button event on the lets say second
row.

It seems that when a new row is created in a repeating table, the button ID
is somthing different from the first one and the code does not recognize it.
How can I fix this in order the click event happen to all buttons in the
repeating table.

Public Sub CTRL140_5_Clicked(ByVal sender As Object, ByVal e As
ClickedEventArgs)
'My code to call the web service and parse data is here.
End Sub
 
M

Moe.Vafaei

Hi Swathi,

Thank you for the instruction, but the buttons are added dynamically to each
row of the repeating table if user clicks on add a new row on the repeating
table.

The scenario is this: I've a repeating table with four columns. I added a
button on the third column. The previous columns are for date and employeeID.
After user clicks the button, web service checks if the entries are valid and
puts the output from web service in forth column. This works fine only for
the first row. So now if user adds another row to the repeating table at run
time and clicks the button, it still puts the output from web service in the
first row. Somehow I need to get the curent row that the button is clicked
and put the output in the forth column of the current row. How can I do this?

Regards,
Moe
 
M

Moe.Vafaei

Thank you for the link. I'm using VB .net as code beside, so what would be
the equivalent of: eventObj.Source.selectSingleNode("my:TextField").text in
VB .Net?

Regards,
Moe
 
J

Joel

Hi Moe,

I also have the same scenario.

I tried converting the command to: e.Source.SelectingNode("my:Field1").Value
But I'm still getting exception.

Have you find the solution for this?

Thanks
 
M

Moe.Vafaei

Hi Joel,

I'm sorry, I was not able to get the Click event working as I wanted, so I
had to change my application logic.

Moe.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top