Afterlightbox - recovering date information

I have actually tried to use the lightbox in the scheduler.
In the lightbox I have defined some custom sections ant I wanted to use the “time” section to manage starting and ending date of the event.
When I click the “Save” button, I go in the form_blocks.myEditor.get_value function that I have defined. As my zone have ID I access them without problem. I would like to recover the start and end date to have the full information on my event to save in the database. The problem is that it seems very complicated to acces to the zone.
I have to use the previousNode and ChildNode to acces to the zone and their values (the path is a bit long somthing like : node.previousNode.chilnodes[1].chilnodes[7].childnodes[0] for the starting date ,I wonder what would happen if I made a single change in the form ^^;)
I was wondering if it was as difficult as it seems or if I miss something that will get my work easier…
Thanks in advance !

Ps : I have tried to look for the onAfterLightBox event, but as I don’t have any information, I think that the event is perhaps alreay modified, but I have lost track of the event ID. I think that by saving the information in some global variable I can save the Id. As it doesn’t fill my need for now I am still looking for a better (and easier) solution !!!

PPS : A little question :
In the afterlight box can I hide the delete button that I can see in the right lower part of the lightbox screen ?

Accessing values of different form section from get_value method was a not expected use-case.
Basically, get_value must return ( or set to event object ) only values of current form section. If you need to have some custom logic for saving - event handlers can be used

a) onEventSave - occurs exactly on save button pressing and provides the event id and has of properties which was set in lightbox form - you can use that event handler if you need to call some custom saving routine.

b) onEventChanged or onEventAdded - called after lightbox was closed and new values applied. Event handler provides id of event and event object with all newly set properties.

In the afterlight box can I hide the delete button that I can see in the right lower part of the lightbox screen
You can’t fully remove it, but adding the next on the page will hide it

//css .dhx_delete_btn{ display:none; } //js scheduler.locale.labels.icon_delete = "";

I am trying to use a custom lightbox form.
I don’t really know where it is coming from but I have an error in the dhtmlxScheduler.js in loadUpdate.
It occurs when want to launch the lightbox (showLIghtBox)

   scheduler.showLightbox = function(id){
   var ev = scheduler.getEvent(id);
   scheduler.startLightbox(id, '<div id="my_form"><label for="description">Event text </label><input type="text" name="description" value="" id="description"><br><label for="custom1">Custom 1 </label><input type="text" name="custom1" value="" id="custom1"><br><label for="custom2">Custom 2 </label><input type="text" name="custom2" value="" id="custom2"><br><br>		<input type="button" name="save" value="Save" id="save" style="width:100px;" onclick="save_Lightbox()">		<input type="button" name="close" value="Close" id="close" style="width:100px;" onclick="close_Lightbox()">	</div>');			
...
}

The html code used for the custom form I have put here take your example of custom form . I have tried with my own code, but it give for all the same error.
As I have the error, the lightbox is not correctly displayed (it is under the scheduler, without border for the windows and not centered in the screen). If I hit the close button, I have the same error when calling endLightbox, and the custorm form stay in the screen (As it was not loaded successfully, it is logical that it can’t be taken off with success…

Second parameter of startLightbox must be the the html object, not the html string