Alpha Video Training
Results 1 to 12 of 12

Thread: HyperLink in Marker detail popup

  1. #1
    Member
    Real Name
    Mark Moss
    Join Date
    Aug 2015
    Posts
    38

    Default HyperLink in Marker detail popup

    HELP!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

    I have a Google Map Method (UX Component) / Map Action / Marker detail Defined as below.

    The problem that I am having is putting a HyperLink within the Marker.

    I want to be able to click on the HyperLink and go to the Detail View of the record, I have tried both of the last two line ( one at a time ) and I still am getting a javascript error that tells me nothing - "An error has occurred in the script on this page" - "Error: Script error." - "URL: a5res.javascript/a5.js"

    Has anyone done this before using a UX List Component and getting data on the client?


    Thanks for looking.

    P.S. If I take out the lines at the bottom of the script it works fine, only when I have 1 of the two lines when I run it does it fail


    Mark


    '<strong><span style="color: #ff0000;">Days Awaiting Service: </span></strong>' + data[rowNumber].Days_Awaiting_Service + '<br>' + '<br>' +
    data[rowNumber].Chain_Name + '<br>' + '<br>' +
    data[rowNumber].Store_Name + '<br>' +
    data[rowNumber].Address_1 + '<br>' +
    data[rowNumber].postOfficeCity +
    data[rowNumber].state +
    data[rowNumber].ZIP + '<br>' + '<br>' +
    data[rowNumber].Contact_Name + '<br>' +
    data[rowNumber].Phone + '<br>' + '<br>' +
    data[rowNumber].Case_Issue_Type + '<br>' + '<br>' +
    data[rowNumber].Description + '<br> + '<br>' +
    'Click <a href="#" onclick="{dialog.object}.panelSetActive('PANEL_DETAIL', false)" >here</a> to see Detail Information';
    'Click <a href="#" onclick="{grid.Object}.detailView(rowNumber)" >here</a> to see Detail Information';

  2. #2
    "Certified" Alphaholic
    Real Name
    Larry Grupido
    Join Date
    May 2010
    Posts
    1,809

    Default Re: HyperLink in Marker detail popup

    One of your codes uses dialog.object, the other is using grid.object. Is this a UX or a Grid?

  3. #3
    Member
    Real Name
    Mark Moss
    Join Date
    Aug 2015
    Posts
    38

    Default Re: HyperLink in Marker detail popup

    Igrupido,


    This is a UX, as I stated above the bottom two lines are different lines that I have used and both failed, but I only used 1 of the bottom two lines at a time.

    Thank you so much for your reply and I hope with this new information you will be able to figure out why it will not work.


    Mark

  4. #4
    "Certified" Alphaholic CharlesParker's Avatar
    Real Name
    Charles Parker
    Join Date
    Dec 2012
    Location
    New Orleans, LA
    Posts
    2,117

    Default Re: HyperLink in Marker detail popup

    The easiest thing to do is to initiate a button click, I'm at a training seminar right now so can't post an example button you may be able to figure it out, I believe Selwyn sent me some example code of two other ways but I would have to find it to post it, anyways if you have a button I believe you can simply put some button click code
    NWCOPRO: Nuisance Wildlife Control Software My Application: http://www.nwcopro.com "Without forgetting, we would have no memory at all...now what was I saying?"

  5. #5
    Member
    Real Name
    Mark Moss
    Join Date
    Aug 2015
    Posts
    38

    Default Re: HyperLink in Marker detail popup

    Charles,


    Thank you so much for you response to my problem, I will give it a try and see if I can get it working with a button as you suggest.

    However I would greatly appreciate it if you would also send me the information that you have on this, when you get back home from your seminar.

    Thanks again, will post back either way on my efforts.


    Mark

  6. #6
    Member
    Real Name
    Mark Moss
    Join Date
    Aug 2015
    Posts
    38

    Default Re: HyperLink in Marker detail popup

    Charles


    As I promised, I added the last line in the Marker Detail and all it did was give the Javascript Error.

    I sure hope that you can find that code.


    Mark


    '<strong><span style="color: #ff0000;">Days Awaiting Service: </span></strong>' + data[rowNumber].Days_Awaiting_Service + '<br>' + '<br>' +
    data[rowNumber].Chain_Name + '<br>' + '<br>' +
    data[rowNumber].Store_Name + '<br>' +
    data[rowNumber].Address_1 + '<br>' +
    data[rowNumber].postOfficeCity +
    data[rowNumber].state +
    data[rowNumber].ZIP + '<br>' + '<br>' +
    data[rowNumber].Contact_Name + '<br>' +
    data[rowNumber].Phone + '<br>' + '<br>' +
    data[rowNumber].Case_Issue_Type + '<br>' + '<br>' +
    data[rowNumber].Description + '<br>' + '<br>' +

    '<button type="button" onclick="document.write(5 + 6)">Try it</button>';

  7. #7
    "Certified" Alphaholic
    Real Name
    David Kates
    Join Date
    Apr 2008
    Location
    Unionville, ON
    Posts
    7,722

    Default Re: HyperLink in Marker detail popup

    There's nothing complicated about this... it's just that your html is malformed because of the single quotes in the .panelSetActive method. Escape the single quotes...

    Code:
    '<br><br>Click <a href="#" onclick="{dialog.Object}.panelSetActive(\'PANELCARD_2\');" >here</a>  to see Detail Information'
    or make life easy for yourself by calling a Javascript function instead. So much easier to read and your code becomes centralized.

    Code:
    '<br><br>Click <a href="#" onclick="listDetail();" >here</a>  to see Detail Information'
    Also, don't need '<br>' + '<br>'... just put them together... '<br><br>'. And you can also include the hyperlink code as above.

  8. #8
    Member
    Real Name
    Mark Moss
    Join Date
    Aug 2015
    Posts
    38

    Default Re: HyperLink in Marker detail popup

    Davidk,


    I am always thankful for each and every reply that I get, I just tried the first option and it does display correctly in the Marker Detail popup, and it does go to the Panel_Detail like I want it to, but how do I get the Panel Detail to show the Detail information of the Popup that was displayed.

    Mark


    '<strong><span style="color: #ff0000;">Days Awaiting Service: </span></strong>' + data[rowNumber].Days_Awaiting_Service + '<br>' + '<br>' +
    data[rowNumber].Chain_Name + '<br>' + '<br>' +
    data[rowNumber].Store_Name + '<br>' +
    data[rowNumber].Address_1 + '<br>' +
    data[rowNumber].postOfficeCity +
    data[rowNumber].state +
    data[rowNumber].ZIP + '<br>' + '<br>' +
    data[rowNumber].Contact_Name + '<br>' +
    data[rowNumber].Phone + '<br>' + '<br>' +
    data[rowNumber].Case_Issue_Type + '<br>' + '<br>' +
    data[rowNumber].Description +
    '<br><br>Click <a href="#" onclick="{dialog.Object}.panelSetActive(\'PANEL_DETAIL\');" >here</a> to see Detail Information'
    Last edited by markemoss; 09-22-2019 at 08:11 PM. Reason: Misspelled a work

  9. #9
    "Certified" Alphaholic
    Real Name
    David Kates
    Join Date
    Apr 2008
    Location
    Unionville, ON
    Posts
    7,722

    Default Re: HyperLink in Marker detail popup

    In the Google Map Method Action, in the onClick event...

    Code:
    var lObj = {dialog.object}.getControl('list1')
    lObj.setValue(markerData.__rowNumber,true);

  10. #10
    Member
    Real Name
    Mark Moss
    Join Date
    Aug 2015
    Posts
    38

    Default Re: HyperLink in Marker detail popup

    DavidK


    It worked like a charm, thank you so very much for you help.



    Mark

  11. #11
    Member
    Real Name
    Mark Moss
    Join Date
    Aug 2015
    Posts
    38

    Default Re: HyperLink in Marker detail popup

    DavidK,


    As a person who is returning to Alpha Anywhere after not using it for too many years, I need some help with this. You have gotten me thru the hardest part with the Hyperlink in the Map Marker detail popup. Now from that point when the user hits the Hyperlink it was going to display a UX Popup Form using the "Open a UX component to Edit Current Record in List Control in a UX Component or Enter a New Record" Action Javascript. Now that worked to some extent but due to the fact that it was based on a View it would not update fields in both tables.

    So I am going to try using the "Open a UX Command" and have unbound components, but I need to know the following

    How do I reference the Fields from the Map Marker Detail popup / List

    Where do I insert those values into the components on my UX Popup Form


    When they have modified the fields and pressed the save button, I will then update both of my tables by using SQL_Update Statements.


    Any help that you can provide will be greatly appreciated.


    Mark

  12. #12
    Member
    Real Name
    Mark Moss
    Join Date
    Aug 2015
    Posts
    38

    Default Re: HyperLink in Marker detail popup

    Guys,


    With a little help from the forum, I was able to solve this by using Arguments to pass the data between the two UXes.


    Mark Moss

Similar Threads

  1. Map Marker details - Go to Detail view
    By CharlesParker in forum Mobile & Browser Applications
    Replies: 0
    Last Post: 06-24-2019, 12:40 PM
  2. Close X on mobile google map Marker Detail does not work
    By Neville in forum Mobile & Browser Applications
    Replies: 3
    Last Post: 01-09-2016, 02:06 PM
  3. Changing color of detail view hyperlink field
    By Meekso in forum Mobile & Browser Applications
    Replies: 3
    Last Post: 07-23-2015, 07:54 AM
  4. Marker Detail not working?
    By JackByrne in forum Mobile & Browser Applications
    Replies: 0
    Last Post: 11-25-2014, 05:49 AM
  5. Making a Button/Hyperlink to popup the calendar
    By Daniel Weiss in forum Web Application Server v7
    Replies: 0
    Last Post: 07-06-2006, 05:44 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •