No announcement yet.

how to create a button for each row?

  • Filter
  • Time
  • Show
Clear All
new posts

  • how to create a button for each row?

    I have a form app with Nth rows.
    How to create a "go to" button for each row?

    So that it passes key params into respective app?

  • #2
    You can create an application link to do just that. It will show a pencil to click on. If you want a button you can create a small gif of your of and then add a custom field to your grid of type image. Then you can allocate your image and beneath there are settings to define a link.
    Albert Drent
    aducom software netherlands
    scriptcase partner, reseller, support and (turn-key) development /


    • #3
      Any steps or example?


      • #4
        Originally posted by weilies View Post
        Any steps or example?
        Go to links -> application link. Select application to link to and map the key fields. Choose if you want it modal or not., That's all.


        Go to fields -> new field
        Use image
        Select the image to show and click on 'link' button below. Then it's like above, select appliation etc.
        Albert Drent
        aducom software netherlands
        scriptcase partner, reseller, support and (turn-key) development /


        • #5
          The options provided are limited, what if I need to put in PHP code control? Like if.they click row 1, it employee app, if click row two, system redirect to teacher app?


          • #6
            I was not aware that you had to jump to different applications. What you might try is to use an onrecord event to set a hyperlink on the field.
            Albert Drent
            aducom software netherlands
            scriptcase partner, reseller, support and (turn-key) development


            • #7
              Can provide a working sample?

              Thanks in millions


              • #8
                welies, did you try onRecord event as Albert told you? just go there and add the link macro to other application or variable, try it, seems logic and should will work.


                • #9
                  Working sample:
                  Create custom field (here it is {go_to})
                  print ("<style type='text/css'>.mybtn
                  	color: #FFFFFF;
                  	border: 1px solid #734500;
                  	font-weight: bold;
                  	font-size: 11px;
                  	background: #EDB817;
                  	height: 25px;
                  	width: 80px;
                  	-moz-border-radius: 3px;
                  	border-radius: 3px;
                  	vertical-align: middle;
                  	padding: 0px;
                  .mybtn:hover {
                  	cursor: pointer;
                  	background: #FED471;
                  	case 1:
                  		{go_to} = "<a href= '/live_html/livescore_start.html' target='_parent'><button class='mybtn' type='button'>Livescore</button></a>";
                  	case 2:
                  		{go_to} = "<a href= '../form_liveresult/form_liveresult.php?v_klasse=[v_klasse]&header1=[v_header1]'><button class='mybtn' type='button'>".{lang_btn_ergebnis}."</button></a>";
                  		{go_to} = check_startliste();


                  • #10
                    i managed to create the link in GRID app!
                    Thanks all for the help.

                    But i realized it doesn't work for FORM app, am i right? there is no way to add links.


                    • #11
                      well, there is link for form! but works differently, specially if single-record form,,, what you mean? wanna click on each form row to take you somewhere? i guess you mean the multiple records form which is useless otherwise how you will modify its values? if you mean the editable gird view then it is a from too, even if you managed to have it open other application on row click, what is the point!? it will lose its functionality to update the values then! not sure if i understood what you want to do exactly


                      • #12
                        hi itsme3,
                        i need to create a PERSON app, where it has a detail app PERSON_INTERFACE which is a form-Editable-GRID app
                        so for each row added, it could be a PERSON with different type (client, lecture, employee, student, etc)
                        since i want to model a very dynamic PERSON app, where it could link to different app (CLIENT, LECTURE, EMPLOYEE, etc) by click on the row in PERSON_INTERFACE based on their PERSON_TYPE field (client, lecture, employee, etc)

                        that's why i need a editable-form-GRID to achieve it rather than a normal GRID

                        the outlook is like

                        ADD BUTTON
                        PERSON_TYPE | LINK
                        Student | Go To
                        Employee | Go To


                        • #13
                          even-though, grid can serve you better, i believe. just create your table and the detailed table related to that with person_id, then create application_link to a single-form to edit that data... and in grid, you can activate the detail feature to see all the person information, no need for Go To
                          now, create a new button in SC, not in database {linkto} and link it from field_link to another grid for example to show you some other related data in other table if you like... so on for other fields

                          editable grid is a form its power is the entry point and the update point, not the linking and the navigation

                          that is what i see based on my understanding

                          good luck