0

“Is there a way in Ninox to get the display name of the current table through a script? I don’t want the tableId (which returns a unique ID)

“I’m looking for a function similar to tablename() in other systems, but it seems Ninox doesn’t provide it. Is there any workaround?”

3 replies

null
    • Fred
    • 5 days ago
    • Reported - view

    Since there is no command to do it there are work arounds. I saw demonstrate a solution where you have a table that stores the table name and then you have the appropriate record in table name table linked to each record in the other tables. 

      • gold_cat
      • 4 days ago
      • Reported - view

       Hi Fred, long time no see! That’s a smart solution — thank you!

    • Ninox partner
    • RoSoft_Steven.1
    • 2 days ago
    • Reported - view

    You can get this by API also... If you have a public cloud or a private cloud:

    let postUrl := "https://api.ninox.com/v1/teams/" + teamId() + "/databases/" + databaseId() +
        "/tables/" +
        tableId(this);
    let postHeaders := {
            Authorization: "Bearer " + YOURAPIKEY,
            Accept: "application/json"
        };
    let response := do as server
            http("GET", postUrl, postHeaders, {})
        end;
    let resp := response.result;
    Tablename := resp.name
    

    This only works in a button. Also "Tablename" is a text-field.

Content aside

  • Status Answered
  • 2 days agoLast active
  • 3Replies
  • 39Views
  • 3 Following