Click here to Skip to main content
15,887,822 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
Kindly, been working on an app for about 40 hours this week. Trying to get the Onclick method to go to a Url. I am new to coding and this is a difficult task for me. I have a list view set, one list. And a search bar functioning where u can search out any of the list accurately by typing in all or some of the list letters or numbers. Now all I need is a basic Onclick method that takes the list item to a specific Google map url. Which will allow people to find that locations address in Google map just by a click. Simple. But can't figure out how

What I have tried:

I tried new activity window. Tried Onclick method and on click listener but IDK how to make the click go to url.
Posted
Updated 3-Nov-17 4:54am
Comments
Karthik_Mahalingam 3-Nov-17 22:04pm    
how does the url mapped to the list items?
show the code or few sample data.
Member 13501738 3-Nov-17 23:15pm    
I am not sure how to make a list of urls. I dont knw how to make a second list. And I don't knw how to link the click listener to go to the list of urls which will be the Google map address of the places on this list
Karthik_Mahalingam 3-Nov-17 23:42pm    
so what do you know?
javascript?
Member 13501738 3-Nov-17 23:46pm    
I am a beginner. I have been learning Java script for a couple of months now. I have a basic list view of hotels and a search view which can show which hotel name u type in. Within the list. All I need to add code which will allow me to click a hotel name in the list and take me to a short link url of the Google map link
Karthik_Mahalingam 3-Nov-17 23:50pm    
just put the list of hotel name and the google map coordinates url to an Array and add it to the list and finally add event to the list item.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900