This is a read-only snapshot of the ComputerCraft forums, taken in April 2020.
Mining_Pickaxe's profile picture

button API - attempt to index ?

Started by Mining_Pickaxe, 14 March 2015 - 07:33 PM
Mining_Pickaxe #1
Posted 14 March 2015 - 08:33 PM
Hey Guys,
I have a problem with a Program to controll some redstone.
I am using DW20s buttonAPI. If i click on a button, i get the message:"button:58: attempt to index ? (a nil value)"

How can I fix that?

ButtonAPI: pastebin XCymC90k
My Program: pastebin HSLiPMsC

(Ps: You might not understand some words cause im german)

Thanks :)/>
HPWebcamAble #2
Posted 14 March 2015 - 10:37 PM
In your Freq1, Freq2, ect functions, you use


button.flash("Freq1")

When it should be


button.flash("Crafting 1")

You need to pass the name of the button to 'flash'
Mining_Pickaxe #3
Posted 15 March 2015 - 12:22 PM
Ok:) tanks for your quick answer.