Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Current Record in a Recordset
Message
De
07/07/1999 09:25:18
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Applications Internet
Divers
Thread ID:
00237942
Message ID:
00238228
Vues:
16
>>
>>I am pumped up to see people implementing XML... these question are getting very intersting.
>
>
>XML Rules!!!
>
>Ok, I am getting extremely close. Here's what my 'simple' code is doing...
>
>*Calls a VFP COM Server to query a table and return a Data Island - it is an Intranet so speed is extremely fast, and we are not going to update the data.
><%
>Set oVfpObject = Server.CreateObject("ssikb.ssikb")
>Response.Write(oVFPObject.conf_payor())
>%>
>
>** I can get the value of the currently clicked field
>SCRIPT
>function fnShowResults(){
> lcValue = window.event.srcElement.parentElement.innerText;
> alert(lcValue);
>}
>SCRIPT
>
>** But, as you see, there are three fields - only one of which contains the value/key for the table (REMOTE). I need to get the value of the REMOTE field whenever a user clicks on the row.

You can do this with the second example I showed you that gets the value for the nth column in the table when any column is clicked. The script in oyur code will return the text for the entire row, becuase the parentElement for the clicked cell is the row. Suppose the field that holds "REMOTE" is in the first column of your table, and you want to get that value when any column is clicked. Use this code:

lcValue = window.event.srcElement.parentElement.Cells(0).innerText;
alert(lcValue);

Once you grasp that you have an object reference to the row, you can drill back down to whichever of its children (rows) you need to.

HTH
Erik Moore
Clientelligence
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform