Copy all content from master detail form

hi folks

I am using the demo and testing some of the features before i buy.
Of course I have already asked support but they haven’t been very helpful to be honest, but this i will post else where with further questions regarding the app itself.

So I have a master detail form with the following:
1 main form with a single record insert
2x forms with editable grids inserts

What i need to do is to be able to copy all content from the 3 froms.
When I click copy at the moment firstly I think we have a bug as the 2 editable grids display an error:
nmgp_tipo_pdf) && $this->nmgp_tipo_pdf == “pb”) || (isset($this->nmgp_cor_print) && $this->nmgp_cor_print == “PB”)) { ?>

Previously with version 6 this wasn’t a problem but of course the details from the two editable grids was not copied.
so how to achieve this would be my question? (copy info from all 3 forms)

Next question would be can we get this bug fixed pls… or maybe tell me why this is???

And finally is there a way to edit the details page that is presented when using a grid view page. As using the above concept I would want to have a single grid displaying content from form 1 and then in the details page to also display the remainder information retrieved from the two other tables (2 editable grids) so that all information is provided in one view…???

Thanks in advance

yes! I have the same problem when add de Print or PDF Button in master detail Form please help!!!

show in the detail place:
nmgp_tipo_pdf) && $this->nmgp_tipo_pdf == “pb”) || (isset($this->nmgp_cor_print) && $this->nmgp_cor_print == “PB”)) { ?>

WF!!!
:confused:

Hello,

I have reported this issue to our bugs team.

regards,
Bernhard Bernsmann

[QUOTE=bartho;12351]Hello,

I have reported this issue to our bugs team.

regards,
Bernhard Bernsmann[/QUOTE]

hey what about my actual question???

help me please how can I copy all contents from all 3 forms at same time???

Copy content from all or select Master/detail forms

hi posting this again and hoping for a reply.

I am using the demo and testing some of the features before i buy, still!

So I have a master detail form with the following:
1 main form with a single record insert
2x forms with editable grids inserts

I want to be able to copy either all content from all forms or from single detail form to be reused in a new form (Master detail form) copying all content except the ID to be reused.

Thanks in advance

Not sure what you want exactly, but you need some event to make it happen. I.e. you can create a button on a detail form of type php. Then execute an appropiate sql statement to copy. The same approach can be done on grids as the grid is a result of an sql statement. You can use temporary tables for storage which might make things easier. Other apporach is to move the fields into [global_variables] which are used as default values for the insert. But I don’t get a complete picture, so I hope this reaction will bring you into the right direction.

Hey Albert
thanks for this one, am wondering if you could help a little further :slight_smile:
I get by in php and am looking to move from DW to scriptcase so am still reworking how my thoughts and coding practices, so just to make sure I understand this one correctly.

So on the details form I create multiple buttons to target/copy the content from specified grid container, to copy the selected (displayed) content and save into a [global_variables] and post to the new grid…
I imagine this would be the simplest an probably the most effective way to do so.
But how do I target content from a grid/detail form which inserted into the master/detail form?

so that I explain what I have in more detail :slight_smile:

1 Master form which contains company details say address, name, no. (single record)
1 Detail form which contains relevant information for the above company, single entry. (editable grid view)
1 Detail form which contains list of Directors multiple entries. (editable grid view)
1 Detail form containing list of Shareholders multiple entries. (editable grid view)

With the above forms in mind, and a single Form/View I need to copy either
the company details,
all listed directors,
all listed shareholders
or all 4 forms

The main question is where do you want to copy the data to? Suppose you want a grid with all listed directors. The primary key is known, so if you have a form where you need this same data then you can supply (link) the key fields and things will work. If you have a display-only situation and need to go to an editmode, I question if you have the right strategy here. Dreamweaver is a completely different story and cannot be compared with SC.
With [global_variables] you need to store all data individually. That can be done in a php array form, or [var1], [var2] etc.
But if you link to a page containing the same table and keys, you simply don’t have to do anything.

I don’t need a full explanation of what you want to do, but a small sample described in a bit more detailed way would be most helpful. I’m writing this down guessing what exactly is what you want to achieve. Sorry for that. Let’s do a step-by-step approach

Hey Albert, thanks for your reply, your being a great help :slight_smile:

Of course I see there is a massive difference between DW and SC, one of the major reasons of the move :slight_smile: As I work more with databases it sure is more powerful and the options wow…
Using SC makes me feel like a DB god :slight_smile:

So the copied content would link or copy to either another master detail which would contain the same fields/forms and also including a new form with data which would need adding.

The idea is to be able to copy the company details, the 50 directors and then the 150 shareholders or only one of the 3 groups to another near identical master form.
I have seen that the standard copy btn will copy the company details as it is a single entry, but the directors and shareholders will not copy all listed, it provides a btn for each director/shareholder.

In the grander scale I have 105 forms where the 3 main forms (company,directors,shareholders) are provided, each with its own master detail and each including a new/extra detail for entry. Each of these need to provide 4 copy buttons to copy either all,company, all directors, all shareholders.
This then links to a new form type which contains all possible forms in one, the user then selects from a drop down list the type of form they need which presents the correct block/extra details which the user is to fill in, including the standard 3 above: company,directors,shareholders.

One of the main issues that within Scriptcase every form is related to a database table. You can create master-details, but presenting data is always bound to a table. You can - however - create a control which is bound to the database, but not to a table. Then you have to master is all by yourself. You say you want to present data agregated into a new form. Best approach would be to create a presentation table you fill with the correct data by the button. You have the sql needed to provide what you see and in the php button code you can do an insert into … select from to copy the data of your current table into the presentation table. If you feel uncomfortable with this sql then you can also use a loop to follow the sql cursor and do separate inserts. If you need this data (since you do not want to copy the id) in the current table then the approach is similar, only the table is the same: insert into mytable select … from mytable where …
Hope this helps.