 | | From: | Will | | Subject: | notebook object | | Date: | Sat, 15 Jan 2005 17:05:13 -0600 |
|
|
 | I have a notebook object with 6 tabs on a form. I have several entryfields on each page of the notebook. I have a pushbutton on the form that will send the date to a field in the notebook. The problem is that when I click this button, nothing appears in the entryfields on the notebook. I tried my code on a regular form and it worked fine. I am referencing the notebook in the code example: form.notebook1.entryfield1.value = date() this is simple code that works on the form, but not on the notebook.
Is there a setting that must be turned on or off before an notebook object can receive data?
|
|
 | | From: | David Stone | | Subject: | Re: notebook object | | Date: | Sat, 15 Jan 2005 16:44:48 -0800 |
|
|
 | Will wrote:
> Is there a setting that must be turned on or off before an notebook object > can receive data?
Nope, what you are doing should work. Try the form below..
David
** END HEADER -- do not remove this line // // Generated on 01/15/2005 // parameter bModal local f f = new notebkEFsForm() if (bModal) f.mdi = false // ensure not MDI f.readModal() else f.open() endif
class notebkEFsForm of FORM with (this) height = 13.6818 left = 28.5714 top = 4 width = 53 text = "" endwith
this.NOTEBOOK1 = new NOTEBOOK(this) with (this.NOTEBOOK1) height = 10.5 left = 2.2857 top = 0.5455 width = 48.7143 dataSource = 'ARRAY {"First", "Second", "Third", "4th", "5th", "6th"}' endwith
this.NOTEBOOK1.ENTRYFIELD1 = new ENTRYFIELD(this.NOTEBOOK1) with (this.NOTEBOOK1.ENTRYFIELD1) height = 1 left = 11.4286 top = 4.2727 width = 18.1429 value = "Entryfield1" endwith
this.NOTEBOOK1.ENTRYFIELD2 = new ENTRYFIELD(this.NOTEBOOK1) with (this.NOTEBOOK1.ENTRYFIELD2) height = 1.2727 left = 10.2857 top = 4.7727 width = 23 value = "Entryfield2" pageno = 2 endwith
this.NOTEBOOK1.ENTRYFIELD3 = new ENTRYFIELD(this.NOTEBOOK1) with (this.NOTEBOOK1.ENTRYFIELD3) height = 1.1818 left = 8.1429 top = 4.5 width = 30.2857 value = "Entryfield3" pageno = 3 endwith
this.NOTEBOOK1.ENTRYFIELD4 = new ENTRYFIELD(this.NOTEBOOK1) with (this.NOTEBOOK1.ENTRYFIELD4) height = 1.0909 left = 11.7143 top = 4.9091 width = 23.8571 value = "Entryfield4" pageno = 4 endwith
this.NOTEBOOK1.ENTRYFIELD5 = new ENTRYFIELD(this.NOTEBOOK1) with (this.NOTEBOOK1.ENTRYFIELD5) height = 1.0909 left = 11.1429 top = 4.5455 width = 19.8571 value = "Entryfield5" pageno = 5 endwith
this.NOTEBOOK1.ENTRYFIELD6 = new ENTRYFIELD(this.NOTEBOOK1) with (this.NOTEBOOK1.ENTRYFIELD6) height = 1.2273 left = 9 top = 4.5 width = 25.1429 value = "Entryfield6" pageno = 6 endwith
this.PUSHBUTTON1 = new PUSHBUTTON(this) with (this.PUSHBUTTON1) onClick = class::PUSHBUTTON1_ONCLICK height = 1.2727 left = 2.1429 top = 11.6818 width = 48.7143 text = "Add dates to all EFs" endwith
function PUSHBUTTON1_onClick form.notebook1.entryfield1.value = date() form.notebook1.entryfield2.value = date() form.notebook1.entryfield3.value = date() form.notebook1.entryfield4.value = date() form.notebook1.entryfield5.value = date() form.notebook1.entryfield6.value = date() return endclass
|
|
 | | From: | Will | | Subject: | Re: notebook object | | Date: | Sat, 15 Jan 2005 21:49:47 -0600 |
|
|
 | A basic form and notebook objects works well. The problem occurs when you datalink the entryfield to a table. If you try to send data with push button to the entryfield ,nothing happens. "David Stone" wrote in message news:41E9B900.713BBC44@wholegrain.com... > Will wrote: > >> Is there a setting that must be turned on or off before an notebook >> object >> can receive data? > > Nope, what you are doing should work. Try the form below.. > > David > > ** END HEADER -- do not remove this line > // > // Generated on 01/15/2005 > // > parameter bModal > local f > f = new notebkEFsForm() > if (bModal) > f.mdi = false // ensure not MDI > f.readModal() > else > f.open() > endif > > class notebkEFsForm of FORM > with (this) > height = 13.6818 > left = 28.5714 > top = 4 > width = 53 > text = "" > endwith > > this.NOTEBOOK1 = new NOTEBOOK(this) > with (this.NOTEBOOK1) > height = 10.5 > left = 2.2857 > top = 0.5455 > width = 48.7143 > dataSource = 'ARRAY {"First", "Second", "Third", "4th", "5th", > "6th"}' > endwith > > this.NOTEBOOK1.ENTRYFIELD1 = new ENTRYFIELD(this.NOTEBOOK1) > with (this.NOTEBOOK1.ENTRYFIELD1) > height = 1 > left = 11.4286 > top = 4.2727 > width = 18.1429 > value = "Entryfield1" > endwith > > this.NOTEBOOK1.ENTRYFIELD2 = new ENTRYFIELD(this.NOTEBOOK1) > with (this.NOTEBOOK1.ENTRYFIELD2) > height = 1.2727 > left = 10.2857 > top = 4.7727 > width = 23 > value = "Entryfield2" > pageno = 2 > endwith > > this.NOTEBOOK1.ENTRYFIELD3 = new ENTRYFIELD(this.NOTEBOOK1) > with (this.NOTEBOOK1.ENTRYFIELD3) > height = 1.1818 > left = 8.1429 > top = 4.5 > width = 30.2857 > value = "Entryfield3" > pageno = 3 > endwith > > this.NOTEBOOK1.ENTRYFIELD4 = new ENTRYFIELD(this.NOTEBOOK1) > with (this.NOTEBOOK1.ENTRYFIELD4) > height = 1.0909 > left = 11.7143 > top = 4.9091 > width = 23.8571 > value = "Entryfield4" > pageno = 4 > endwith > > this.NOTEBOOK1.ENTRYFIELD5 = new ENTRYFIELD(this.NOTEBOOK1) > with (this.NOTEBOOK1.ENTRYFIELD5) > height = 1.0909 > left = 11.1429 > top = 4.5455 > width = 19.8571 > value = "Entryfield5" > pageno = 5 > endwith > > this.NOTEBOOK1.ENTRYFIELD6 = new ENTRYFIELD(this.NOTEBOOK1) > with (this.NOTEBOOK1.ENTRYFIELD6) > height = 1.2273 > left = 9 > top = 4.5 > width = 25.1429 > value = "Entryfield6" > pageno = 6 > endwith > > this.PUSHBUTTON1 = new PUSHBUTTON(this) > with (this.PUSHBUTTON1) > onClick = class::PUSHBUTTON1_ONCLICK > height = 1.2727 > left = 2.1429 > top = 11.6818 > width = 48.7143 > text = "Add dates to all EFs" > endwith > > > function PUSHBUTTON1_onClick > form.notebook1.entryfield1.value = date() > form.notebook1.entryfield2.value = date() > form.notebook1.entryfield3.value = date() > form.notebook1.entryfield4.value = date() > form.notebook1.entryfield5.value = date() > form.notebook1.entryfield6.value = date() > return > endclass > >
|
|
 | | From: | *Lysander* | | Subject: | Re: notebook object | | Date: | Mon, 17 Jan 2005 08:03:00 +0100 |
|
|
 | In article <#HPWq63#EHA.876@news-server>, toquerrio@hotmail.com says... > A basic form and notebook objects works well. The problem occurs when you= =20 > datalink the entryfield to a table. If you try to send data with push but= ton=20 > to the entryfield ,nothing happens.
if the entryfield is linked to a rowset, why not directly write the=20 value to the corresponding field of the rowset and refresh the screen?
Check also for any properties of this rowset that might block the=20 changing of values of the rowset. Is there any cansave-event, any=20 onnavigation-event... ?
ciao, Andr=E9
|
|
 | | From: | Will | | Subject: | Re: notebook object | | Date: | Mon, 17 Jan 2005 14:51:29 -0600 |
|
|
 | How can this be coded along with saving the data this already in the form "*Lysander*" wrote in message news:MPG.1c55818d3923a0a4989682@news.dbase.com... In article <#HPWq63#EHA.876@news-server>, toquerrio@hotmail.com says... > A basic form and notebook objects works well. The problem occurs when you > datalink the entryfield to a table. If you try to send data with push > button > to the entryfield ,nothing happens.
if the entryfield is linked to a rowset, why not directly write the value to the corresponding field of the rowset and refresh the screen?
Check also for any properties of this rowset that might block the changing of values of the rowset. Is there any cansave-event, any onnavigation-event... ?
ciao, André
|
|
 | | From: | Bernd Hohenester | | Subject: | Re: notebook object | | Date: | Sun, 16 Jan 2005 08:05:54 +0000 |
|
|
 | Hello Will,
> A basic form and notebook objects works well. The problem occurs when you > datalink the entryfield to a table. If you try to send data with push button > to the entryfield ,nothing happens.
i guess you have to set the rowset in edit-mode or append-mode first. Try to add the following line:
function PUSHBUTTON1_onClick
form.rowset.beginedit()
form.notebook1.entryfield1.value = date() form.notebook1.entryfield2.value = date() form.notebook1.entryfield3.value = date() form.notebook1.entryfield4.value = date() form.notebook1.entryfield5.value = date() form.notebook1.entryfield6.value = date() return
cu Bernd
|
|
 | | From: | Roland Wingerter | | Subject: | Re: notebook object | | Date: | Sun, 16 Jan 2005 10:31:31 +0100 |
|
|
 | Bernd Hohenester wrote: > i guess you have to set the rowset in edit-mode or append-mode first. > Try to add the following line: > > > function PUSHBUTTON1_onClick > > form.rowset.beginedit() > > form.notebook1.entryfield1.value = date() > form.notebook1.entryfield2.value = date() > form.notebook1.entryfield3.value = date() > form.notebook1.entryfield4.value = date() > form.notebook1.entryfield5.value = date() > form.notebook1.entryfield6.value = date() ----- And don't forget: form.rowset1.save()
Roland
|
|
 | | From: | Will | | Subject: | Re: notebook object | | Date: | Sat, 15 Jan 2005 17:24:23 -0600 |
|
|
 | I have also noticed that this happens when the entryfield is datalinked to a table. "Will" wrote in message news:4%23sXob1%23EHA.876@news-server... >I have a notebook object with 6 tabs on a form. I have several entryfields >on each page of the notebook. I have a pushbutton on the form that will >send the date to a field in the notebook. The problem is that when I click >this button, nothing appears in the entryfields on the notebook. I tried my >code on a regular form and it worked fine. I am referencing the notebook in >the code > example: form.notebook1.entryfield1.value = date() > this is simple code that works on the form, but not on the notebook. > > Is there a setting that must be turned on or off before an notebook object > can receive data? >
|
|