Related to Datawindow(Very Urgent)

Hi
    My question is as fallows:
  I have one datawindow,in which i retrieve data from three tables,i just wanted to click the pericular row,and insert no of rows afetr that row,which should be blank,i wanted to enter new data in it,One of field of datawindow is dropdowndatawindow,so that field should be present in blank rows too,plz hepl me ,plz give a code for it,
Thanks in advance,i hope u will help me soon..
Regards
 Sanika
sanikaAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

BhattiCommented:
In dw where you want to inseret the rows just click on this row and then use the function InsertRow(row_number) in the clicked event of the dw.

InsertRow(row_number) where row_number is the row number before which row you want to insert the row or rows.

If you want to insert more then 1 row then use for loop how many rows you want to insert.

Please just have a small look on the function InsertRow(n).

Now you have a dddw in the datawindow. This dddw is the child of the parent dw. say dw you have is a dw_1. and you have a dddw in this dw_1.

In the same event (clicked) of the dw code:

//variable
datawindowchild  ldwc_child

dw_1.GetChild("name_of_column_of_dddw", ldwc_child)
ldwc_child.SetTransObject(sqlca)
ldwc_child.InsertRow(n) //where you want to insert the row.

And also please just have a look on the GetChild function.

In this function first parameter is the name of the dw_1 column where you placed the dddw.

If you have any question or you need more explaination please let me know.


Best regards


Bhatti

0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
sanikaAuthor Commented:
Its not working properly,
Tell me how i do this
If i click on perticular row,after that i ahve to add no of rows.
and second In pb7 how do i set one of my column name as detawindow,i have style as dddw,but its not working.Plz help me as soon as possible.
0
EAServerCommented:
Put the following in the clicked event of your datawindow...

IF row < 1 THEN RETURN //No row was clicked so just return
This.InsertRow(row + 1)

That's it two lines of code are all that is needed.  Now this code is going to add a new row evertime you click on a row, are you sure that is what you want?
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Editors IDEs

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.