How to Enter Values in to another Form Through Menu Item

Hii All

I have small requirement.Please help me and here is my Requirement

I have FormA with fields Sno , Subject, Name and FormB with fields Sno and Subject .FormB is the MenuButton in FormA.When i am Opening FormB(Menu Buttom)in Form A ) through FormA i am Geeting Sno defaulted from FormA.

Here my requirement is that when we enter Subject in FormB through Menu Item that should be updated in FormA for the particular Sno.

Thank You

Regards

Chinna

Hi Chinna,

I want to know that are you using the same table in both forms?

if so… U have to refresh the DB.or U have to insert the values to the FormA.

if, Do u want insert the subject to the selected record of the FormA.

Pass the selected record using args.

means in menuButton clicked method-> args.record(DaraSourceName);

get this recrod in FormB. in init() method.

Table_buffer = element.args.record();

using this u can insert a subject from FormB for that selected record in FormA

Best Wishes.

Hai chinna,

Try it thru relation.

Reagards

Shon

Hi Chinna,

Same S.No in form B through Form A is because you have given relation between two tables. You need to write update method matching the S.No.

Regards,

Kuppusamy S

Hi Chinna,

In the Form A menuitem,override clicked method, and write the update Query if you are using two diff tables for the Form A and B.

and refresh the form A from the form B. hope this will help you out:-)

Hai chinna,

In regards to you statement:

" Here my requirement is that when we enter Subject in FormB through Menu Item that should be updated in FormA for the particular Sno "

I jus reread it, sorry that i understood wrong before:

Well the solution to fulfill your requirement would be.

In form B → override the modified method of the field subject-

nd

Table A A;

;

select forupdate A where A.slno == B.slno;

ttsbegin;

A.subject = B.subject;

a.update();

ttscommit;

This will definitly update the subject- just you need to refresh your form A;

Regards

Shon