DCkid64
|
  |
| Joined: 23 Nov 2013 |
| Total Posts: 90 |
|
|
| 17 Sep 2016 05:46 PM |
| I'm having some issues with table names and I can't embed a string or int value into a table name. My code is as follows: #code Exceptions{script.Parent.Parent.ID.Value} = ########### Is my syntax correct? If not, what is the correct syntax? #code ################ |
|
|
| Report Abuse |
|
|
|
| 17 Sep 2016 05:47 PM |
Try uploading to pastebin so your code doesn't get censored Post the pastebin link on multiple lines so that isn't censored either lol |
|
|
| Report Abuse |
|
|
DCkid64
|
  |
| Joined: 23 Nov 2013 |
| Total Posts: 90 |
|
|
| 17 Sep 2016 05:47 PM |
Sorry for hashtags, that's supposed to be {"plrname"}
|
|
|
| Report Abuse |
|
|
DCkid64
|
  |
| Joined: 23 Nov 2013 |
| Total Posts: 90 |
|
|
| 17 Sep 2016 05:49 PM |
| ################################################################################################################################################################################################# |
|
|
| Report Abuse |
|
|
TimeTicks
|
  |
| Joined: 27 Apr 2011 |
| Total Posts: 27115 |
|
|
| 17 Sep 2016 05:50 PM |
tab[StringVal.Value] = true
|
|
|
| Report Abuse |
|
|
DCkid64
|
  |
| Joined: 23 Nov 2013 |
| Total Posts: 90 |
|
|
| 17 Sep 2016 05:53 PM |
I dont to change just one value inside the table, I want the table name to be Exceptions23 if ID.Value is 23
|
|
|
| Report Abuse |
|
|
L2000
|
  |
| Joined: 03 Apr 2008 |
| Total Posts: 77448 |
|
|
| 17 Sep 2016 05:57 PM |
You can't manually set variable names unless you store them in a table of some sort. Well, you can, using getfenv(), but that just gives you a table of all variables in your script.
The best thing to do is make a general table and store it in there - like variables[Exceptions23]
|
|
|
| Report Abuse |
|
|
TimeTicks
|
  |
| Joined: 27 Apr 2011 |
| Total Posts: 27115 |
|
|
| 17 Sep 2016 06:10 PM |
tab['Exceptions'..id.Value] = true
|
|
|
| Report Abuse |
|
|