Hi. I've been playing round with hyperlinks and have happily got several working. I'm now running into a problem. I'm hopeing im missing something blindingly obvious and its easy to fix.
All the hyperlinks I have working are in the format
with a function
somewhere in the plugin
if variable1 in the hyperlink were equal to "here" as an example the hyperlink when clicked prints quite simply "here"
I now have a hyperlink I would like to pass 2 variables to at the same time however using
with a function
somewhere in the plugin
If for example variable1 = "this" and variable2 = "here" in the hyperlink I now get from the function printing
"this, here: nil" (so var1 = "this, here" and var2 = nil)
Am I missing something or does the hyperlink sub function only accept single variables.
If this is so I can hack around it by passing both values as a single variable and then spliting them into 2 variables in the linked function (based on space, comma or whatever) but this isnt a particularly elegant solution as in the actual plugin the function the hyperlink is calling is used elsewhere as well where it doesnt require extra code to run through to split up lumped variables
Hope Im missing something
All the hyperlinks I have working are in the format
Hyperlink ("!!" .. GetPluginID () .. ":content_save_hyperlink(" .. variable1 .. ")", name_line, "Click", "", "", false)with a function
function content_save_hyperlink(var1)
print(var1)
endsomewhere in the plugin
if variable1 in the hyperlink were equal to "here" as an example the hyperlink when clicked prints quite simply "here"
I now have a hyperlink I would like to pass 2 variables to at the same time however using
Hyperlink ("!!" .. GetPluginID () .. ":content_save_hyperlink(" .. variable1 .. ", " .. variable2 .. ")", name_line, "Click", "", "", false)with a function
function content_save_hyperlink(var1, var2)
print(var1, ":", var2)
endsomewhere in the plugin
If for example variable1 = "this" and variable2 = "here" in the hyperlink I now get from the function printing
"this, here: nil" (so var1 = "this, here" and var2 = nil)
Am I missing something or does the hyperlink sub function only accept single variables.
If this is so I can hack around it by passing both values as a single variable and then spliting them into 2 variables in the linked function (based on space, comma or whatever) but this isnt a particularly elegant solution as in the actual plugin the function the hyperlink is calling is used elsewhere as well where it doesnt require extra code to run through to split up lumped variables
Hope Im missing something