I would like to add multiple child rows to a parent while the parent form is still in add more.

  • 0
  • 1
  • Question
  • Updated 3 years ago
  • Answered

my parent form has an  <Add Child> button which calls an Import([Record ID#]) function to load some child records.

function Import(PARENT_ID ) {

  Reads (API_DoQuery) from a master table (25) rows, append the PARENT_ID to each record

  Calls API_ImportFromCSV to load the child records

}

this works fine when the parent form is already saved because it has access to the parent RECORD_ID. how can I save the parent form and then execute my import function when the <Add Child> button is clicked.

I tried DoSave() but this takes me to the view mode of the form.



Photo of Tribs

Tribs

  • 20 Points

Posted 3 years ago

  • 0
  • 1
Photo of Scott

Scott

  • 334 Points 250 badge 2x thumb
Have you tried DoSaveAdd()?
Photo of Tribs

Tribs

  • 20 Points
Hi Scott -  Thanks for your response and apologize for the late response -  just got back from vacation.

yes, I tried it with DoSaveAdd(), the problem is I cannot get the parent record ID with the URL I'm using, if you can think of anything else then please let me know.

onClick=\"{DoSaveAdd(); ImportIAB(" & [Record ID#] & ");return true;}\">"