Home » Developer & Programmer » Forms » Button next_record doesn't work (Forms 6i win XP)
Button next_record doesn't work [message #515389] Mon, 11 July 2011 05:46 Go to next message
nessedik
Messages: 10
Registered: July 2011
Junior Member
Hi,

I'm a beginner in oracle forms 6i , i have a problem with the bouton next and previous record with oracle forms 6i , i have un application developped mith a menu ( it does'nt use the default menu of orcale forms 6i) but the bouton next_record and previous_record doesn't work it displays this message : "Vous devez saisir ou supprimer un enregistrement au préalable" whatever there is a data in the database table.

I check the code behind the next record bouton , it seems to be correct : do_key('Next_record');

What can be the problem

pleaaaaaaaaaaaaase help me

I'm blocked in this proble for more than week

Thanks a lot for any help

[EDITED by LF: fixed topic title typo; was "Bouton"]

[Updated on: Wed, 13 July 2011 05:22] by Moderator

Report message to a moderator

Re: Bouton next_record doesn't work [message #515392 is a reply to message #515389] Mon, 11 July 2011 06:23 Go to previous messageGo to next message
Littlefoot
Messages: 21818
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
Quote:
there is a data in the database table

But, did you FETCH those records into a form? You can't scroll up/down if there are no records displayed.


If the above hint doesn't solve a problem: how many blocks are there in your form? I *suppose* two (at least). If that's correct, what block do your "next" and "previous" buttons belong to? Should be in a block that contains all those records.

Feel free to provide as many details as possible; we know only what you tell us, so - you can't really expect help if we don't know what you do and what you have.
Re: Bouton next_record doesn't work [message #515405 is a reply to message #515392] Mon, 11 July 2011 07:16 Go to previous messageGo to next message
nessedik
Messages: 10
Registered: July 2011
Junior Member
Hi,

thanks a lot for your reply

When I say that "There is a data in the database table" that only means there are two lines in the database table but I doesn't fetch those records into a form. I'm sorry but what do you mean by a block ??? what do you mean by "what block do your "next" and "previous" buttons belong to?" ( I'm beginner in forms so I'm sorry if it is a stupid question. I have mentionned also that there is a menu developped in the application that I work in and the code behind the next record bouton is : do_key('Next_record');there must be also a trigger to develop or what is the problem?? How can we make the bouton next-record work ?
Re: Bouton next_record doesn't work [message #515407 is a reply to message #515405] Mon, 11 July 2011 07:33 Go to previous messageGo to next message
cookiemonster
Messages: 13937
Registered: September 2008
Location: Rainy Manchester
Senior Member
Block = Datablock - found in the object navigator under "Data Block".
If there is no data in the form then what exactly do you expect next_record to do?
Does the message you get have an accompanying FRM number?
Re: Bouton next_record doesn't work [message #515409 is a reply to message #515405] Mon, 11 July 2011 07:39 Go to previous messageGo to next message
Littlefoot
Messages: 21818
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
There's a table in your database. It contains some records (two, as you say). If you want to see how they look like, you should use a tool that allows you to do that. Oracle database's built-in tool is SQL*Plus, so - if you run
select * from your_table;
in SQL*Plus, you'll get those records displayed on the screen.

You chose to use Forms, a tool that allows you to create user-friendly GUI ("a form") so that your users wouldn't have to use SQL*Plus. In order to do that, you have to get that table into a form. A block contains columns (which are, in Forms, called "items") that represent your table. The simplest way is to do that by following the Wizard's instructions; take a table, select all its columns, display it in a tabular mode.

When you compile and run a form, it is empty (although it is based on your table). If you want to display those records, you have to (virtually) perform
select * from your_table
In Forms, you do that by "executing a query". Now that you have records displayed on the screen, each of them in its own block record, you can scroll up ("previous record") and down ("next record"). There's no use to scroll through an empty block, don't you agree?

Forms built-in toolbar contains useful buttons (including next and previous record ones). You chose not to use it, but to develop your own one. That's OK, as long as you know what you are doing.

Unfortunately, you are brand new to Forms and - as it seems - didn't read any documentation (at least, the basics) or attend training lessons. I'm afraid that you won't be able to work with Forms with knowledge you have at the moment. Try to find a tutorial, read Forms Online Help, ask someone who worked with Forms to show you at least something so that you'd be able to explain what's bothering you. You don't even know the terminology ... gosh, you and we will have a long, hot Summer.
Re: Bouton next_record doesn't work [message #515549 is a reply to message #515409] Tue, 12 July 2011 03:28 Go to previous messageGo to next message
nessedik
Messages: 10
Registered: July 2011
Junior Member
Hi,

thanks a lot for your reply
Quote:

Block = Datablock - found in the object navigator under "Data Block".


Unfortunately, in the file maint.mmb for the menu does'nt contain a datablock in the object navigator

Quote:
Does the message you get have an accompanying FRM number?


when I click on the bouton next record I have this message with the frm number: "FRM-40102 : Vous devez saisir ou supprimer un enregistrement au préalable"

Quote:
There's a table in your database. It contains some records (two, as you say). If you want to see how they look like, you should use a tool that allows you to do that. Oracle database's built-in tool is SQL*Plus, so - if you run


==> Yes, I have checked that there is a data on my database table , i'm using the plsql developper tool and it shows me that there is a data on my table

Thanks a lot for your Information Littlefoot.

Yes , you have reason I did'nt learn enough documentation about forms I just begin with an application that is already developped and i'm trying to correct it that may be a mistake. Can you please give me some links to forms tutorial or good documentation

Thanks a lot for your help ( I'm sorry for my english because I have a french culture )

A+++
Re: Bouton next_record doesn't work [message #515557 is a reply to message #515549] Tue, 12 July 2011 03:41 Go to previous messageGo to next message
Littlefoot
Messages: 21818
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
Forms 6i documentation (read it from bottom up, as patches are now on the top of the page).
Re: Bouton next_record doesn't work [message #515559 is a reply to message #515549] Tue, 12 July 2011 03:53 Go to previous messageGo to next message
cookiemonster
Messages: 13937
Registered: September 2008
Location: Rainy Manchester
Senior Member
nessedik wrote on Tue, 12 July 2011 09:28

Quote:

Block = Datablock - found in the object navigator under "Data Block".


Unfortunately, in the file maint.mmb for the menu does'nt contain a datablock in the object navigator

The menu doesn't, but then the menu doesn't have records either. It's attached to a form. Next_record acts on the form.

nessedik wrote on Tue, 12 July 2011 09:28

when I click on the bouton next record I have this message with the frm number: "FRM-40102 : Vous devez saisir ou supprimer un enregistrement au préalable"


Form Builder help is a wonderful thing, you can look up error messages in it:
Form Builder help topic

FRM-40102: Record must be entered or deleted first.
Cause:  You pressed [Next Record] or [Down] in a context where it is meaningless.
Either:

1. The last record in a block is the current record.
2. The block is empty.
3. You are in a new record in the middle of the block created by pressing [Insert Record].

Action:  No action is necessary.


I suggest you spend a while reading the docs LF linked to.
Re: Bouton next_record doesn't work [message #515561 is a reply to message #515557] Tue, 12 July 2011 04:00 Go to previous messageGo to next message
nessedik
Messages: 10
Registered: July 2011
Junior Member
thanks a lot littleFoot It seems to be a good documentation I will read it and I hope find a solution for my problem

Re: Bouton next_record doesn't work [message #515594 is a reply to message #515561] Tue, 12 July 2011 05:26 Go to previous messageGo to next message
nessedik
Messages: 10
Registered: July 2011
Junior Member
Hi,

I have seen the documentation it 's good but I did'nt find a simple tutorial that build a simple application with form builder 6i can any one give me some links for forms toturials

Thank's a lot in advance
Re: Bouton next_record doesn't work [message #515595 is a reply to message #515594] Tue, 12 July 2011 05:31 Go to previous messageGo to next message
Littlefoot
Messages: 21818
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
I *think* that there's the "Quick Tour" on a CD (you used to install the product). Take a look, maybe you'll find it. I don't have any tutorial, but documentation provided by Oracle (which is located on a page you already visited).
Re: Bouton next_record doesn't work [message #515608 is a reply to message #515595] Tue, 12 July 2011 06:47 Go to previous messageGo to next message
nessedik
Messages: 10
Registered: July 2011
Junior Member
Ok thanks littleFoot
Unfortnatelly, I have'nt the CD.

Thanks for your help

the documentation is good but for a beginner is difficult


I will search

I'm still looking for a simple tutorial to perform a application on my work

Please help me I'm blocked in my work

Thanks In advance

A+++
Re: Bouton next_record doesn't work [message #515612 is a reply to message #515559] Tue, 12 July 2011 07:12 Go to previous messageGo to next message
nessedik
Messages: 10
Registered: July 2011
Junior Member
thanks a lot cookiemonster for your help , the help of forms builder seems to be good I will try learn it.

I haven't solve my problem till now, the bouton next_record still not working although there is a data in my database table Sad

Help me please

Thanks and regards
Re: Bouton next_record doesn't work [message #515617 is a reply to message #515612] Tue, 12 July 2011 07:47 Go to previous messageGo to next message
cookiemonster
Messages: 13937
Registered: September 2008
Location: Rainy Manchester
Senior Member
Again - what exactly are you expecting next_record to do?
The error description from help above is quite clear. So I assume you are trying to do something that next_record can't do.
Is there data visible in the screen when you press the button?
Re: Bouton next_record doesn't work [message #515620 is a reply to message #515617] Tue, 12 July 2011 08:06 Go to previous messageGo to next message
cookiemonster
Messages: 13937
Registered: September 2008
Location: Rainy Manchester
Senior Member
Answer me this - Do you think that next_record will cause the form to populate an empty record on screen with data from the database table?
Re: Bouton next_record doesn't work [message #515743 is a reply to message #515620] Wed, 13 July 2011 03:06 Go to previous messageGo to next message
nessedik
Messages: 10
Registered: July 2011
Junior Member
Hi,

Thanks a lot for your reply cookiemonster
Quote:

Again - what exactly are you expecting next_record to do?


==> I expect that next_record will allow me to navigate between the dataset of the table of the database i'll be able to see the data of that is on the table correspondent to the form

Quote:
Is there data visible in the screen when you press the button?


==> No , there is no data visible in the screen although that there is a data on the database table

Quote:
Answer me this - Do you think that next_record will cause the form to populate an empty record on screen with data from the database table?


==>I did'nt you understand enough you but next_record is displaying no thing on the screen

Thanks and regards

A+++

Re: Bouton next_record doesn't work [message #515748 is a reply to message #515743] Wed, 13 July 2011 03:10 Go to previous messageGo to next message
cookiemonster
Messages: 13937
Registered: September 2008
Location: Rainy Manchester
Senior Member
Next_record does not do what you think it does. To get records from a database table into a database block in the form you need to use execute_query.
You really need to spend some time reading the docs, you have no understanding of how the basics of forms work.
Re: Bouton next_record doesn't work [message #515787 is a reply to message #515748] Wed, 13 July 2011 04:24 Go to previous messageGo to next message
nessedik
Messages: 10
Registered: July 2011
Junior Member
Hi,

thanks for the information cookiemonster , you have reason I must spend sone time reading the docs but the problem I didn't find any docs that is simple and shows the basics of forms the oracle documentation that I found at the documentation link is so advanced and doesn't show the basics of forms for a bigenner lik me

Please Some have some links to the basics of forms or some tutorials?

Best thanks and regards

A++
Re: Bouton next_record doesn't work [message #515793 is a reply to message #515787] Wed, 13 July 2011 04:37 Go to previous messageGo to next message
cookiemonster
Messages: 13937
Registered: September 2008
Location: Rainy Manchester
Senior Member
Have you tried googling?
Looks like there's some on youtube.
Re: Bouton next_record doesn't work [message #515809 is a reply to message #515793] Wed, 13 July 2011 06:39 Go to previous message
nessedik
Messages: 10
Registered: July 2011
Junior Member
thanks cookiemonster

Yes I have make some google search but I didn't find a good tutorial

Yes I have seen the youtube vedeo demo it seems to be interesent

If any one knows good tutorials will greatly welcome

Thanks a lot

best regards

A+++
Previous Topic: problem with upload excel form
Next Topic: strange FORMS behavior
Goto Forum:
  


Current Time: Sun Sep 08 23:00:23 CDT 2024