Forum Discussion
MCFNeil
8 years agoQrew Captain
Regardless of the AddRecord or AddGenRecordForm (which your examples shows AddGenRecordForm),
You will want to use the 'LinkAway' function in a formula text field, like so:
// This works because you have turned on the table's advance settings, "Save parent record automatically when a child record is created."
// This also is borrowing the LinkAway that gets automatically added for formula url fields. We are invoking it here so when we are directed to the success.html page the record is first saved.
You will want to use the 'LinkAway' function in a formula text field, like so:
"<a class='Vibrant Success' href='javascript:LinkAway(\""&[URL Formula]&"\");'>Submit and redirect</a>"
// This works because you have turned on the table's advance settings, "Save parent record automatically when a child record is created."
// This also is borrowing the LinkAway that gets automatically added for formula url fields. We are invoking it here so when we are directed to the success.html page the record is first saved.
- JordanBeatty18 years agoQrew CaptainSo in order to do this, I need to create a field for the API call and a separate field for what you have described above?
- MCFNeil8 years agoQrew CaptainKeep the formula URL field that you have from above (you know if already works), but insert that field into the formula I pasted, replacing [URL Formula].
Then on the table A's advanced settings there is a checkbox:
Make sure that is checked, then the new formula text field will (1) Save the current record and (2) go to your new Form. - JordanBeatty18 years agoQrew CaptainThe original URL Formula seems to be working on its own, and I have that box checked off, though it doesn't not seem to be working
[Add Activity Formula] = URLRoot() & "db/" & [_DBID_ACTIVITY_LOG] & "?a=API_GenAddRecordForm&_fid_11=" & "Tasked to Team Member: " & URLEncode ([Description]) & "&_fid_50=" &URLEncode([Company Name (ref)]) & "&_fid_47=" &URLEncode([Worker or Project Name (ref)])
And I'm using:
"<a class='Vibrant Success' href='javascript:LinkAway(\""&[Add Activity Formula]&"\");'>Save Task and Add Activity</a>".
I'm getting asked I wanted to leave the page and it's not saving, and it does still redirect me to the correct form, though no information is passed.
EDIT:
My mistake, I forgot to enable HTML tags, this did the trick, thank you guys!