Graphics

 View Only
  • 1.  Inputing DataLinq Keys: Using Global Lists

    Posted 08-20-2018 17:00
    Hi all,

    Currently to fill in data into some of our graphics, our graphics operators have to look up a several-digit ID number of a specific player.

    Since we are covering an entire league and not individual games, jersey numbers or simply typing in a full name will not work for us.

    What I'd like to see is if there's a way to incorporate a global or static list selection where the datalinq number is being typed in.

    That way the operator can just type the first few digits of the player's last name and then it will fill in that player's Datalinq Key number automatically.

    On the surface it looks like you can't do anything of the sort when it comes to inputing datalinq keys.

    Is there any way to do this?

    I am on XPression Designer v7.0 build 3820.

    Thanks



  • 2.  RE: Inputing DataLinq Keys: Using Global Lists

    Posted 08-21-2018 18:20
    There is a workaround to do this...

    Don't update your Datalinq Key directly.

    Put your list in a text object, with your list as the data source for that object. Then, use a script on your scene object to modify the Datalinq Key:

    '===================================== THE SCRIPT:

    dim key as xpdatalinqkey
    dim keys as xpdatalinqkeys
    dim txt as xptextobject

    self.getobjectbyname("TEXT OBJECT NAME", txt)
    self.getdatalinqkeys(keys)
    keys.getkeybyname("DATALINQ KEY NAME", key)
    key.asstring = txt.text

    self.refreshdatalinqs

    '======END OF SCRIPT

    Hope that helps!
    #XPression


  • 3.  RE: Inputing DataLinq Keys: Using Global Lists

    Posted 08-22-2018 16:03
    So the source list (a spreadsheet) basically breaks down like this:

    I have 3 columns, one of which is the ID number (which would populate the datalinq), and name and team abbreviation columns to identify which player to choose from.

    If I save that as NFL_PLAYERS.txt, do I save that with a delimiter and then how would I put that in the script you provided - with the full path of where that lives?

    Or do I take that list and make it into a global user input list?


    Just so I'm clear on this:

    "TEXT OBJECT NAME" would be the text object I created to add this script to

    and

    "DATALINQ KEY NAME" is the the name of the particular datalinq that has already been added to the scene.

    Thanks - I'm still trying to learn the script side of some things.


    #XPression


  • 4.  RE: Inputing DataLinq Keys: Using Global Lists

    Posted 08-22-2018 19:11

    There is a great video from Ross that deals with user input controls : https://www.youtube.com/watch?v=pkACfzHp4r

    At14'50 it explains how to use global list from a text file with coma delimiter and how it can update other objects automatically.
    It seems that global lists are stored in Xpression project file : text files are used to import/export data in/from your project (path and name of the text files are not stored in the project).

    If all the player information can be stored in the global list then the list should be enough to display all data in your scene.


    In your case , imagine you have this global list and configuration : 




    then in the script provided by kirkaldie you would query :

    dim txt as xptextobject
    self.getobjectbyname("col_id", txt)


    See project sample for global list with multiple columns : TYT_global_list_multiple_columns.zip


    #XPression