When you open the popover you need to pass it the address info from the portal record you clicked.
How are you accessing Google Maps? Are you using a custom function or are you using the default from the web viewer object for Google Maps:
"http://local.google.com/maps?" & "q=" & /*Address=*/ "" & "," & /*City=*/ "" & "," & /*State=*/ "" & "," & /*Zip Code=*/ "" & "," & /*Country=*/ ""
I am using the default web viewer - I have been trying to script this to send the correct data to the popover but have not bee very successful.
Are you sure the data sent to the WV is from the selected portal row? It sounds like the relationship may not being addressed properly, hence you get the default first matching record all the time.
I am using the default web viewer - I have been trying to script this to send the correct data to the popover but have not been very successful.
OK. But that doesn't provide any meaningful detail about exactly what you did. Recognize that an answer, exactly parallel in level of detail, would be "When I wrote a script it was successful."
What does your script look like? Can you attach a copy of the script or a clone of your file or can you make an example file that demonstrates what you are trying to do?
Web Viewers in Portals
You can’t place a web viewer in a portal. If you place a web viewer on a portal, the web viewer appears as an object on the layout that overlaps the portal.
This means that you also cannot place a web viewer in a popover in a portal – that is just like putting it directly in the portal.
Since the web viewer is not IN the portal, it will only have access to the first related record. This is the behaviour you are seeing.
Ahh yes! That makes sense. So what you need to do is capture the relevant portal row data in a script (use set variable) and post it to a WV elsewhere on your layout. done properly you would get the same effect you are seeking.
The way around it would be to load a global field with the URL required when you open the popover (OnObjectEnter script trigger for the popover). And use this global as the web viewer URL.