agtjazz Posted April 30, 2008 Posted April 30, 2008 I have a simple database test (that is attached) and can't seem to add rows to the portal with IWP.... it works just fine in filemaker client- but really need to be able to do it via the web Any advice or help is greatly appreciated Thanks in advance PortalSample.fp7.zip
agtjazz Posted May 6, 2008 Author Posted May 6, 2008 I know that repeating fields are not recommended, but should I use them for the IWP database?
Ugo DI LUCA Posted May 6, 2008 Posted May 6, 2008 In order to do what you want, you need a "Open Record" command. Though I would recommand that the creation of a new row be scripted. Once the related record created, you could just have the script go to the correct portal row based on the number of related records. There are plenty of examples here around of how to accomplish such a creation.
agtjazz Posted May 6, 2008 Author Posted May 6, 2008 Would the creation of the new row, be done on this layout or another layout in IWP? Thanks for your assistance
Ugo DI LUCA Posted May 6, 2008 Posted May 6, 2008 (edited) You may do it directly from this layout but switching to another to do the job is not problematical Something along the lines... Set Variable [$id ; PrimaryID ] Go to layout [ relatedTableLayout ] New Record Set Field [parentID ; $id ] Commit Record Go to layout [original ] Open Record Go to Object [Your Portal ObjectName ] Go to Portal Row [ Count ( RelatedTable::PrimaryID ) ] If you don't want to switch Layout, you'd need another relation to create a new record, and the existing relationship for displaying related ones. And another key. The relation is established from that key, a global, that I'd call MagicKey to the Primary key in the related table Then Set Fied [ MagicKey ; "" ] Set Field [ RelatedCreate::ParentKey ; PrimaryKey ] Commit Record Set Fied [ MagicKey ; "" ] Go to Object [Your Portal ObjectName ] Go to Portal Row [ Count ( RelatedTable::PrimaryID ) ] There are plenty of method, that's the one I'm using. hth Edited May 6, 2008 by Guest
agtjazz Posted May 6, 2008 Author Posted May 6, 2008 ... If you don't want to switch Layout, you'd need another relation to create a new record, and the existing relationship for displaying related ones. And another key. The relation is established from that key, a global, that I'd call MagicKey to the Primary key in the related table Then Set Fied [ MagicKey ; "" ] Set Field [ RelatedCreate::ParentKey ; PrimaryKey ] Commit Record Set Fied [ MagicKey ; "" ] Go to Object [Your Portal ObjectName ] Go to Portal Row [ Count ( RelatedTable::PrimaryID ) ] There are plenty of method, that's the one I'm using. hth I am very interested in this and think I follow... but not exactly sure. Are there any examples you could point me to so I can study it closer? Or I can take a stab at it and post when I get stuck? Thanks bunches (again)
agtjazz Posted May 13, 2008 Author Posted May 13, 2008 Here is my attempt at adding a row to the portal in the same layout... via IWP and it's not working What did I do wrong? Any help would be greatly appreciated Thanks in advance! PortalSample.fp7.zip
DblWide Posted August 29, 2008 Posted August 29, 2008 I had the same problem...I have a portal in IWP and it would not automatically create a new row. I placed a button on the row that would call the "add portal row" script. The script Ugo DI LUCA gave us worked beautifully! Thanks!
Recommended Posts
This topic is 6198 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now