macro no get data from web....
scenario, to the default have a page with frame:
pagina1.asp top
pagina3.asp center
pagina2.asp bottom
now after i have clicked on button cerca appear in center of this page a new page named elementi_trovati.asp with the result of serach...
How to get data from new page assuming is have this piece of code (i have tested this piece of code but tno get nothig all test var are blank!!!!!!!!!!):
In effect i want get the data from cells where is:
IMPARATO SALVATORE
A16492.19
6477
Q.D.3
00024683
8505
ADD.SERVIZI GENERALI
REGIONE SUD
SERVIZI GENERALI
TEST_TAG_1 = UCase(.document.all.tags("table").Item(3).Rows(0). Cells(3).innerText)
Range("C" & lngRow) = Trim(TEST_TAG_1) 'Trim(UCase(.document.all.tags("table").Item(3).Ro ws(0).Cells(3).innerText))
'FILIALE
TEST_TAG_2 = UCase(.document.all.tags("table").Item(3).Rows(1). Cells(3).innerText)
Range("D" & lngRow) = Trim(TEST_TAG_2) 'Trim(UCase(.document.all.tags("table").Item(3).Ro ws(1).Cells(3).innerText))
'INDIRIZZO
TEST_TAG_3 = UCase(.document.all.tags("table").Item(3).Rows(2). Cells(1).innerText)
Range("E" & lngRow) = Trim(TEST_TAG_3) ' Trim(UCase(.document.all.tags("table").Item(3).Row s(2).Cells(1).innerText))
'CITTA
TEST_TAG_4 = UCase(.document.all.tags("table").Item(3).Rows(3). Cells(1).innerText)
Range("F" & lngRow) = Trim(TEST_TAG_4) 'Trim(UCase(.document.all.tags("table").Item(1).Ro ws(3).Cells(1).innerText))
'CAP
TEST_TAG_5 = Format(UCase(.document.all.tags("table").Item(3).R ows(4).Cells(1).innerText), "#00000")
Range("G" & lngRow) = Trim(TEST_TAG_5) 'Trim(Format(UCase(.document.all.tags("table").Ite m(3).Rows(4).Cells(1).innerText), "#00000"))
'End With
html code:
<head>
<title></title>
</head>
<body link="#00FFFF" vlink="#00FFFF" bgcolor="#344AB1" alink="#00FFFF">
<p style="margin-top: 0; margin-bottom: 0" align="center">
<span style="background-color: #000080"> DIREZIONE OPERATIONS - Pro.P.A. - MOE GOVERNANCE - HR e Comunicazione
</span> <a href="info.asp" target="centrale">
INFO</a></p>
<div align="center">
<center>
<table border="0" cellpadding="0" cellspacing="0" width="731" height="1" background="images/sfondocell3.jpg">
<tr>
<td width="211" bgcolor="" height="4" valign="middle" align="left">
<p style="margin-left: 10; margin-top: 0; margin-bottom: 0"><b>
Ub.
Nominativo
</b></p>
</td>
</center>
<td width="69" bgcolor="" height="4" valign="middle" align="left">
<p align="left">Sel.
Abbr.
</td>
<center>
<td width="84" height="4" valign="middle" align="left">
<p align="center"><b>Telefono</b></td>
<td width="79" bgcolor="" height="4" valign="middle" align="left">
<p align="center">Qualifica</td>
<td width="92" bgcolor="" height="4" valign="middle" align="left">
<p align="right">CID</td>
<td width="102" bgcolor="" height="4" valign="middle" align="left">
<p align="center">Cod.sede</td>
<td width="82" bgcolor="" height="4" valign="middle" align="left">
<p align="center">Società </p>
</td>
</tr>
</table>
</center>
</div>
<p style="margin-top: 5; margin-bottom: 5">
<div align="center">
<center>
<table border="0" cellpadding="0" cellspacing="0" width="731" background="images/sfondocell2.gif" style="border-collapse: collapse" bordercolor="#111111">
<tr>
<td width="19" bgcolor="" height="6" valign="middle" align="left">
<p align="center">
</p>
</td>
<td width="182" bgcolor="" height="1" valign="middle" align="left"><b>
IMPARATO SALVATORE </b> </td>
<td width="81" bgcolor="" height="6" valign="middle" align="left">
<p align="left">
A16492.19
</td>
<td width="113" height="6" valign="middle" align="center">
<p align="left"><b>
6477
</b></p>
</td>
<td width="61" bgcolor="" height="6" valign="middle" align="left">
<p align="left">Q.D.3
</td>
<td width="70" bgcolor="" height="6" valign="middle" align="left">
<p align="right">
00024683
</td>
<td width="82" bgcolor="" height="6" valign="middle" align="left">
<p align="center">
<b>
<a href="TROVADIPENDENZE.ASP?START=1&NPAG=1&VPARTENZA =1&TIPRIC=1&vcerca=8505">8505</a></b></td>
<td width="55" bgcolor="" height="6" valign="middle" align="center">
<a href="TROVA1.ASP?START=1&NPAG=1&VPARTENZA=1&TIPORI CERCA=9&vcerca=BNL">BNL</a>
</td>
<td width="27" bgcolor="" height="6" valign="middle" align="center">
</td>
</tr>
<tr>
<td width="289" bgcolor="" height="18" valign="middle" align="left" colspan="3">
<p style="margin-left: 30">
ADD.SERVIZI GENERALI</td>
<td width="367" bgcolor="" align="left" colspan="6">
<b>
123456</b></td>
</tr>
<tr>
<td width="289" bgcolor="" height="18" valign="middle" align="left" colspan="3">
<p style="margin-left: 30">
<a href="trovaufficio1.asp?vcerca=REGIONE SUD &vcerca1=SERVIZI GENERALI&vlink=1&NPAG=1&START=1&VP ARTENZA=1&Ord=1" target="_self" Title = "Risultato: Tutti i nominativi di questa sede" >REGIONE SUD</a></td>
<td width="367" bgcolor="" align="left" colspan="6">
<p style="margin-top: 0; margin-bottom: 0">
<a href="TROVAUFFICIO1.ASP?NPAG=1&VLINK=2&ORD=1&START =1&VPARTENZA=1&vcerca=REGIONE SUD &vcerca1=SERVIZI GENERALI " target="_self" Title = "Risultato: Tutti i nominativi di questo Ufficio" >SERVIZI GENERALI</a>
</td>
</tr>
</table>
</center>
</div>
<p style="margin-left: 15; margin-top: 0; margin-bottom: 0" align="center">
<b></b>
</p>
<p style="margin-left: 15; margin-top: 0; margin-bottom: 0" align="center">
</p>
<p style="margin-left: 15; margin-top: 0; margin-bottom: 0" align="center"> </p>
</body>
|