Solved

delphi embbebed Web Browser Help - CLICK IN RADIO BUTTONS

Posted on 2010-08-28
4
1,148 Views
Last Modified: 2012-05-10
I AM NEED CLICK IN RADIO BUTTONS WITH EMBBEDDED, FOR CLICK IN NORMAL BUTTONS I AM USE
EmbeddedWB1.OleObject.Document.all.Item('setaFilho1', 0).click; AND SUCCESS AND WHEN I TRY WITH ID OF RADIO BUTTONS THE BUTTON NOT SUCCESS CLICK. PLEASE HELP ME.
0
Comment
Question by:thaiskis
  • 2
4 Comments
 
LVL 36

Expert Comment

by:Geert Gruwez
Comment Utility
does the radio button have an id ?

have you found it in the source of the site ?
0
 

Author Comment

by:thaiskis
Comment Utility
the html of the radio is

<input type="radio" onselect="alteraCampo('cpf','cnpj');" onclick="alteraCampo('cpf','cnpj');" tabindex="7" value="2" name="indicadorPessoa" checked="checked">
<input type="radio" onselect="alteraCampo('cpf','cnpj');" onclick="alteraCampo('cpf','cnpj');" tabindex="7" value="2" name="indicadorPessoa" checked="checked">

and frined i am need select using embbedded this html, i trying using code of click button and not work, please help me

<select class="valor" style="text-align: left;" tabindex="10" name="finalidade"><option value="01">Crédito em conta corrente</option>
<option value="02">Pagamento aluguel/condomínios</option>
<option value="03">Pagamento duplicatas/títulos</option>
<option value="04">Pagamento dividendos</option>
<option value="05">Pagamento mensalidades escolares</option>
<option value="06">Pagamento salários</option>
<option value="07">Pagamento a fornecedores</option>
<option value="08">Operação câmbio/fundos/bolsa valores</option>
<option value="09">Repasse arrecadação/pagamento de tributos</option>
<option value="10">Transferência internacional em reais</option>
<option value="11">Crédito em conta de poupança</option>
<option value="23">Pagamento de bolsa auxílio</option>
<option value="24">Remuneração a cooperado</option>
<option value="25">Pagamento de honorários</option>
<option value="26">Pagamento de prebenda</option>
<option value="99">Outros</option></select>
0
 
LVL 13

Expert Comment

by:aflarin
Comment Utility
try this

  EmbeddedWB1.OleObject.Document.all.Item('indicadorPessoa', 0).click;

is it working?

you have two radio buttons with the same name - indicadorPessoa
so you can't select the second button by the name. if it's your html code, I suggest you to change the second name of the button like this:

<input type="radio" onselect="alteraCampo('cpf','cnpj');" onclick="alteraCampo('cpf','cnpj');" tabindex="7" value="2" name="indicadorPessoa1" checked="checked">
<input type="radio" onselect="alteraCampo('cpf','cnpj');" onclick="alteraCampo('cpf','cnpj');" tabindex="7" value="2" name="indicadorPessoa2" checked="checked">
then you'll be able to click on the first button
EmbeddedWB1.OleObject.Document.all.Item('indicadorPessoa1', 0).click;


and the second button:
EmbeddedWB1.OleObject.Document.all.Item('indicadorPessoa2', 0).click;





0
 
LVL 13

Accepted Solution

by:
aflarin earned 500 total points
Comment Utility
btw try this code, it should work:

for the first button:
  EmbeddedWB1.OleObject.Document.all.Item('indicadorPessoa', 0).click;

for the second button:
  EmbeddedWB1.OleObject.Document.all.Item('indicadorPessoa', 1).click;
0

Featured Post

What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

This article will show, step by step, how to integrate R code into a R Sweave document
In this post we will learn how to connect and configure Android Device (Smartphone etc.) with Android Studio. After that we will run a simple Hello World Program.
In this fifth video of the Xpdf series, we discuss and demonstrate the PDFdetach utility, which is able to list and, more importantly, extract attachments that are embedded in PDF files. It does this via a command line interface, making it suitable …
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now