It's likely that the execution of the code is aborted by the Lua interpreter when it wants to store the result of guiCreateStaticImage(0, 0, 1280, 960, ":loginG/imagenes/ap.png", false) into a non-existant table.
You need to add the following before any other code you may have:
local GUIEditor = {}
GUIEditor.staticimage = {}
GUIEditor.label = {}
GUIEditor.edit = {}
GUIEditor.button = {}
-- or (simply a matter of preference)
local GUIEditor = {
staticimage = {},
label = {},
edit = {},
button = {},
}