Forum Discussion
QuickBaseCoachD
8 years agoQrew Captain
I have not done a full test of working code but here is a non javascript approach.
You can do successive URL calls like this, where each of the formula variables is a URL formula, such as API_AddRecord.
Here is an example of a formula I used in an app once.
var text YYOtherMonths = Right(ToText(Year(Today())),2);
var text AddJAN = URLRoot() & "db/" & [_DBID_TABLE_1] & "?act=API_AddRecord&_fid_189=" & [Project ID#]& "&_fid_197=" & "01-01-" & $YYOtherMonths;
var text AddFEB = URLRoot() & "db/" & [_DBID_TABLE_1] & "?act=API_AddRecord&_fid_189=" & [Project ID#]& "&_fid_197=" & "02-01-" & $YYOtherMonths;
var text AddMAR = URLRoot() & "db/" & [_DBID_TABLE_1] & "?act=API_AddRecord&_fid_189=" & [Project ID#]& "&_fid_197=" & "03-01-" & $YYOtherMonths;
var text AddAPR= URLRoot() & "db/" & [_DBID_TABLE_1] & "?act=API_AddRecord&_fid_189=" & [Project ID#]& "&_fid_197=" & "04-01-" & $YYOtherMonths;
var text AddMAY = URLRoot() & "db/" & [_DBID_TABLE_1] & "?act=API_AddRecord&_fid_189=" & [Project ID#]& "&_fid_197=" & "05-01-" & $YYOtherMonths;
var text AddJUN = URLRoot() & "db/" & [_DBID_TABLE_1] & "?act=API_AddRecord&_fid_189=" & [Project ID#]& "&_fid_197=" & "06-01-" & $YYOtherMonths;
var text AddJUL = URLRoot() & "db/" & [_DBID_TABLE_1] & "?act=API_AddRecord&_fid_189=" & [Project ID#]& "&_fid_197=" & "07-01-" & $YYOtherMonths;
var text AddAUG = URLRoot() & "db/" & [_DBID_TABLE_1] & "?act=API_AddRecord&_fid_189=" & [Project ID#]& "&_fid_197=" & "08-01-" & $YYOtherMonths;
var text AddSEP = URLRoot() & "db/" & [_DBID_TABLE_1] & "?act=API_AddRecord&_fid_189=" & [Project ID#]& "&_fid_197=" & "09-01-" & $YYOtherMonths;
var text AddOCT = URLRoot() & "db/" & [_DBID_TABLE_1] & "?act=API_AddRecord&_fid_189=" & [Project ID#]& "&_fid_197=" & "10-01-" & $YYOtherMonths;
var text AddNOV = URLRoot() & "db/" & [_DBID_TABLE_1] & "?act=API_AddRecord&_fid_189=" & [Project ID#]& "&_fid_197=" & "11-01-" & $YYOtherMonths;
var text AddDEC = URLRoot() & "db/" & [_DBID_TABLE_1] & "?act=API_AddRecord&_fid_189=" & [Project ID#]& "&_fid_197=" & "12-01-" & $YYOtherMonths;
var text DisplayProjectRecordinEditMode = URLRoot() & "db/" & [_dbid_projects] & "?a=er&dfid=19&rid=" & [Project ID#];
$AddJAN
& "&rdr=" & URLEncode($AddFEB)
& URLEncode("&rdr=" & URLEncode($AddMAR))
& URLEncode(URLEncode("&rdr=" & URLEncode($AddAPR)))
& URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($AddMAY))))
& URLEncode(URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($AddJUN)))))
& URLEncode(URLEncode(URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($AddJUL))))))
& URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($AddAUG)))))))
& URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($AddSEP))))))))
& URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($AddOCT)))))))))
& URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($AddNOV))))))))))
& URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($AddDEC)))))))))))
& URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($DisplayProjectRecordinEditMode))))))))))))
So one approach is to just use a version of the the button above to make 11 duplicates, each different by the month. That would work when you have the record made for month 1.
Then you could also make 11 versions of the buttons and use form rules to show / hide the appropriate buttons. For example if the month was "3", then you could show the button which would make months 4,5,6,7,8,9,10 11 and 12.
You can do successive URL calls like this, where each of the formula variables is a URL formula, such as API_AddRecord.
Here is an example of a formula I used in an app once.
var text YYOtherMonths = Right(ToText(Year(Today())),2);
var text AddJAN = URLRoot() & "db/" & [_DBID_TABLE_1] & "?act=API_AddRecord&_fid_189=" & [Project ID#]& "&_fid_197=" & "01-01-" & $YYOtherMonths;
var text AddFEB = URLRoot() & "db/" & [_DBID_TABLE_1] & "?act=API_AddRecord&_fid_189=" & [Project ID#]& "&_fid_197=" & "02-01-" & $YYOtherMonths;
var text AddMAR = URLRoot() & "db/" & [_DBID_TABLE_1] & "?act=API_AddRecord&_fid_189=" & [Project ID#]& "&_fid_197=" & "03-01-" & $YYOtherMonths;
var text AddAPR= URLRoot() & "db/" & [_DBID_TABLE_1] & "?act=API_AddRecord&_fid_189=" & [Project ID#]& "&_fid_197=" & "04-01-" & $YYOtherMonths;
var text AddMAY = URLRoot() & "db/" & [_DBID_TABLE_1] & "?act=API_AddRecord&_fid_189=" & [Project ID#]& "&_fid_197=" & "05-01-" & $YYOtherMonths;
var text AddJUN = URLRoot() & "db/" & [_DBID_TABLE_1] & "?act=API_AddRecord&_fid_189=" & [Project ID#]& "&_fid_197=" & "06-01-" & $YYOtherMonths;
var text AddJUL = URLRoot() & "db/" & [_DBID_TABLE_1] & "?act=API_AddRecord&_fid_189=" & [Project ID#]& "&_fid_197=" & "07-01-" & $YYOtherMonths;
var text AddAUG = URLRoot() & "db/" & [_DBID_TABLE_1] & "?act=API_AddRecord&_fid_189=" & [Project ID#]& "&_fid_197=" & "08-01-" & $YYOtherMonths;
var text AddSEP = URLRoot() & "db/" & [_DBID_TABLE_1] & "?act=API_AddRecord&_fid_189=" & [Project ID#]& "&_fid_197=" & "09-01-" & $YYOtherMonths;
var text AddOCT = URLRoot() & "db/" & [_DBID_TABLE_1] & "?act=API_AddRecord&_fid_189=" & [Project ID#]& "&_fid_197=" & "10-01-" & $YYOtherMonths;
var text AddNOV = URLRoot() & "db/" & [_DBID_TABLE_1] & "?act=API_AddRecord&_fid_189=" & [Project ID#]& "&_fid_197=" & "11-01-" & $YYOtherMonths;
var text AddDEC = URLRoot() & "db/" & [_DBID_TABLE_1] & "?act=API_AddRecord&_fid_189=" & [Project ID#]& "&_fid_197=" & "12-01-" & $YYOtherMonths;
var text DisplayProjectRecordinEditMode = URLRoot() & "db/" & [_dbid_projects] & "?a=er&dfid=19&rid=" & [Project ID#];
$AddJAN
& "&rdr=" & URLEncode($AddFEB)
& URLEncode("&rdr=" & URLEncode($AddMAR))
& URLEncode(URLEncode("&rdr=" & URLEncode($AddAPR)))
& URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($AddMAY))))
& URLEncode(URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($AddJUN)))))
& URLEncode(URLEncode(URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($AddJUL))))))
& URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($AddAUG)))))))
& URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($AddSEP))))))))
& URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($AddOCT)))))))))
& URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($AddNOV))))))))))
& URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($AddDEC)))))))))))
& URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($DisplayProjectRecordinEditMode))))))))))))
So one approach is to just use a version of the the button above to make 11 duplicates, each different by the month. That would work when you have the record made for month 1.
Then you could also make 11 versions of the buttons and use form rules to show / hide the appropriate buttons. For example if the month was "3", then you could show the button which would make months 4,5,6,7,8,9,10 11 and 12.
- WilliamEvans18 years agoQrew CadetInteresting idea thanks! i'll try it out and post back in a day :)
- QuickBaseCoachD8 years agoQrew CaptainThe only risk factor that I know about this is that with the successive URLEncoding, the resultant URL gets very long. Chrome and FF allow very long URLs, but I believe that IE is more limited to about 2,000 characters.
So once you get it working in say Chrome, then try the other browsers. You ca also use a formula field to determine the length of the formula, and google to see the IE limit.
https://www.google.ca/search?q=internet+exporer+maximum+url+length&oq=internet+exporer+maximum+u...\
It seems be a limit of 2,083 characters. So you may hit that limit if your individual URLs are very long. If that happens and you need it to work in IE and you want to stay low tech non javascript, then you would need to break it up into two buttons.
Mark - WilliamEvans18 years agoQrew CadetAll of my users use the latest Chrome so I think i'll be ok with the URL limit....
I am trying to get the code working with just ONE copy + Increment action first (this is my first time coding a url formula, but i'm trying to learn)
So with using the API_AddRecords - to duplicate my record will i need to map each and every source field to the target field - which since i'm creating a duplicate is just each field mapped upon itself? (thus hardcoding it in this formula - bit of a pain if the items table has new fields added at some point?) .... so the url becomes really really long because i have ~60 editable fields to copy thus your concern about the length?
- or should i instead be using "GenCopyRecord" to copy the item, and then just edit the "Month Number" field ? or is it too hard to lock onto the correct field that way?
Am I on the wrong track (i'm still reading about the API/URL formulas)
Thanks! - QuickBaseCoachD8 years agoQrew CaptainYes, if you have 60 fields to copy they need to need to be mapped individually, and yes if you add a field in the future it will not get mapped.
You can make a button to do that GenCopyRecord to save clicking to the more menu and do them one by one.
It's sort of a "choose your poison" type choice.
_ - WilliamEvans18 years agoQrew CadetHi Again,
I was able to implement the record copy and increment using API_AddRecord successfully for ONE month (one iteration) ... BUT as soon as i put in all the iterations, the URL became too long for QuickBase's html server :(
I have the errorBad Request - Request Too Long
HTTP Error 400. The size of the request headers is too long.
Here's my formula below (with api key redacted) - is there anyway to simplify this so that it will fit?
START CODE
==========================================var text AddAug = URLRoot() & "db/" & [_DBID_NEWITEMS] & "?act=API_AddRecord&_fid_8=" & [Budget Status Flag]
===============================================
& "&_fid_22=" & [Comments]
& "&_fid_25=" & [Account Code]
& "&_fid_28=" & [Related Company]
& "&_fid_244=" & [Item Status]
& "&_fid_72=" & [General Cost Currency]
& "&_fid_73=" & [General Cost Description]
& "&_fid_122=" & [Number of Days Required]
& "&_fid_156=" & [Item Vendor]
& "&_fid_160=" & [Spend Country]
& "&_fid_161=" & [Related Project Manager]
& "&_fid_9=" & [Recoverable?]
& "&_fid_165=" & [General Cost Quantity]
& "&_fid_164=" & [Predefined Daily Cost Quantity]
& "&_fid_163=" & [Predefined Cost Quantity]
& "&_fid_114=" & [Related People Cost]
& "&_fid_81=" & [Predefined Daily Cost Days]
& "&_fid_71=" & [General Unit Cost]
& "&_fid_69=" & [Related Predefined Daily Cost]
& "&_fid_68=" & [Related Predefined Cost]
& "&_fid_37=" & [Related Fx]
& "&_fid_32=" & [Item Type]
& "&_fid_47=" & [Related Sub-Project]
& "&_fid_241=" & [Original Item Project Category]
& "&_fid_43=" & "8"
& "&apptoken=thisismyapptoken_doineedtorepeatiteachtime??";
var text AddSep = URLRoot() & "db/" & [_DBID_NEWITEMS] & "?act=API_AddRecord&_fid_8=" & [Budget Status Flag]
& "&_fid_22=" & [Comments]
& "&_fid_25=" & [Account Code]
& "&_fid_28=" & [Related Company]
& "&_fid_244=" & [Item Status]
& "&_fid_72=" & [General Cost Currency]
& "&_fid_73=" & [General Cost Description]
& "&_fid_122=" & [Number of Days Required]
& "&_fid_156=" & [Item Vendor]
& "&_fid_160=" & [Spend Country]
& "&_fid_161=" & [Related Project Manager]
& "&_fid_9=" & [Recoverable?]
& "&_fid_165=" & [General Cost Quantity]
& "&_fid_164=" & [Predefined Daily Cost Quantity]
& "&_fid_163=" & [Predefined Cost Quantity]
& "&_fid_114=" & [Related People Cost]
& "&_fid_81=" & [Predefined Daily Cost Days]
& "&_fid_71=" & [General Unit Cost]
& "&_fid_69=" & [Related Predefined Daily Cost]
& "&_fid_68=" & [Related Predefined Cost]
& "&_fid_37=" & [Related Fx]
& "&_fid_32=" & [Item Type]
& "&_fid_47=" & [Related Sub-Project]
& "&_fid_241=" & [Original Item Project Category]
& "&_fid_43=" & "9"
& "&apptoken=thisismyapptoken_doineedtorepeatiteachtime??";
var text AddOct = URLRoot() & "db/" & [_DBID_NEWITEMS] & "?act=API_AddRecord&_fid_8=" & [Budget Status Flag]
& "&_fid_22=" & [Comments]
& "&_fid_25=" & [Account Code]
& "&_fid_28=" & [Related Company]
& "&_fid_244=" & [Item Status]
& "&_fid_72=" & [General Cost Currency]
& "&_fid_73=" & [General Cost Description]
& "&_fid_122=" & [Number of Days Required]
& "&_fid_156=" & [Item Vendor]
& "&_fid_160=" & [Spend Country]
& "&_fid_161=" & [Related Project Manager]
& "&_fid_9=" & [Recoverable?]
& "&_fid_165=" & [General Cost Quantity]
& "&_fid_164=" & [Predefined Daily Cost Quantity]
& "&_fid_163=" & [Predefined Cost Quantity]
& "&_fid_114=" & [Related People Cost]
& "&_fid_81=" & [Predefined Daily Cost Days]
& "&_fid_71=" & [General Unit Cost]
& "&_fid_69=" & [Related Predefined Daily Cost]
& "&_fid_68=" & [Related Predefined Cost]
& "&_fid_37=" & [Related Fx]
& "&_fid_32=" & [Item Type]
& "&_fid_47=" & [Related Sub-Project]
& "&_fid_241=" & [Original Item Project Category]
& "&_fid_43=" & "10"
& "&apptoken=thisismyapptoken_doineedtorepeatiteachtime??";
var text AddNov = URLRoot() & "db/" & [_DBID_NEWITEMS] & "?act=API_AddRecord&_fid_8=" & [Budget Status Flag]
& "&_fid_22=" & [Comments]
& "&_fid_25=" & [Account Code]
& "&_fid_28=" & [Related Company]
& "&_fid_244=" & [Item Status]
& "&_fid_72=" & [General Cost Currency]
& "&_fid_73=" & [General Cost Description]
& "&_fid_122=" & [Number of Days Required]
& "&_fid_156=" & [Item Vendor]
& "&_fid_160=" & [Spend Country]
& "&_fid_161=" & [Related Project Manager]
& "&_fid_9=" & [Recoverable?]
& "&_fid_165=" & [General Cost Quantity]
& "&_fid_164=" & [Predefined Daily Cost Quantity]
& "&_fid_163=" & [Predefined Cost Quantity]
& "&_fid_114=" & [Related People Cost]
& "&_fid_81=" & [Predefined Daily Cost Days]
& "&_fid_71=" & [General Unit Cost]
& "&_fid_69=" & [Related Predefined Daily Cost]
& "&_fid_68=" & [Related Predefined Cost]
& "&_fid_37=" & [Related Fx]
& "&_fid_32=" & [Item Type]
& "&_fid_47=" & [Related Sub-Project]
& "&_fid_241=" & [Original Item Project Category]
& "&_fid_43=" & "11"
& "&apptoken=thisismyapptoken_doineedtorepeatiteachtime??";
var text AddDec = URLRoot() & "db/" & [_DBID_NEWITEMS] & "?act=API_AddRecord&_fid_8=" & [Budget Status Flag]
& "&_fid_22=" & [Comments]
& "&_fid_25=" & [Account Code]
& "&_fid_28=" & [Related Company]
& "&_fid_244=" & [Item Status]
& "&_fid_72=" & [General Cost Currency]
& "&_fid_73=" & [General Cost Description]
& "&_fid_122=" & [Number of Days Required]
& "&_fid_156=" & [Item Vendor]
& "&_fid_160=" & [Spend Country]
& "&_fid_161=" & [Related Project Manager]
& "&_fid_9=" & [Recoverable?]
& "&_fid_165=" & [General Cost Quantity]
& "&_fid_164=" & [Predefined Daily Cost Quantity]
& "&_fid_163=" & [Predefined Cost Quantity]
& "&_fid_114=" & [Related People Cost]
& "&_fid_81=" & [Predefined Daily Cost Days]
& "&_fid_71=" & [General Unit Cost]
& "&_fid_69=" & [Related Predefined Daily Cost]
& "&_fid_68=" & [Related Predefined Cost]
& "&_fid_37=" & [Related Fx]
& "&_fid_32=" & [Item Type]
& "&_fid_47=" & [Related Sub-Project]
& "&_fid_241=" & [Original Item Project Category]
& "&_fid_43=" & "12"
& "&apptoken=thisismyapptoken_doineedtorepeatiteachtime??";
var text AddJan = URLRoot() & "db/" & [_DBID_NEWITEMS] & "?act=API_AddRecord&_fid_8=" & [Budget Status Flag]
& "&_fid_22=" & [Comments]
& "&_fid_25=" & [Account Code]
& "&_fid_28=" & [Related Company]
& "&_fid_244=" & [Item Status]
& "&_fid_72=" & [General Cost Currency]
& "&_fid_73=" & [General Cost Description]
& "&_fid_122=" & [Number of Days Required]
& "&_fid_156=" & [Item Vendor]
& "&_fid_160=" & [Spend Country]
& "&_fid_161=" & [Related Project Manager]
& "&_fid_9=" & [Recoverable?]
& "&_fid_165=" & [General Cost Quantity]
& "&_fid_164=" & [Predefined Daily Cost Quantity]
& "&_fid_163=" & [Predefined Cost Quantity]
& "&_fid_114=" & [Related People Cost]
& "&_fid_81=" & [Predefined Daily Cost Days]
& "&_fid_71=" & [General Unit Cost]
& "&_fid_69=" & [Related Predefined Daily Cost]
& "&_fid_68=" & [Related Predefined Cost]
& "&_fid_37=" & [Related Fx]
& "&_fid_32=" & [Item Type]
& "&_fid_47=" & [Related Sub-Project]
& "&_fid_241=" & [Original Item Project Category]
& "&_fid_43=" & "1"
& "&apptoken=thisismyapptoken_doineedtorepeatiteachtime??";
var text AddFeb = URLRoot() & "db/" & [_DBID_NEWITEMS] & "?act=API_AddRecord&_fid_8=" & [Budget Status Flag]
& "&_fid_22=" & [Comments]
& "&_fid_25=" & [Account Code]
& "&_fid_28=" & [Related Company]
& "&_fid_244=" & [Item Status]
& "&_fid_72=" & [General Cost Currency]
& "&_fid_73=" & [General Cost Description]
& "&_fid_122=" & [Number of Days Required]
& "&_fid_156=" & [Item Vendor]
& "&_fid_160=" & [Spend Country]
& "&_fid_161=" & [Related Project Manager]
& "&_fid_9=" & [Recoverable?]
& "&_fid_165=" & [General Cost Quantity]
& "&_fid_164=" & [Predefined Daily Cost Quantity]
& "&_fid_163=" & [Predefined Cost Quantity]
& "&_fid_114=" & [Related People Cost]
& "&_fid_81=" & [Predefined Daily Cost Days]
& "&_fid_71=" & [General Unit Cost]
& "&_fid_69=" & [Related Predefined Daily Cost]
& "&_fid_68=" & [Related Predefined Cost]
& "&_fid_37=" & [Related Fx]
& "&_fid_32=" & [Item Type]
& "&_fid_47=" & [Related Sub-Project]
& "&_fid_241=" & [Original Item Project Category]
& "&_fid_43=" & "2"
& "&apptoken=thisismyapptoken_doineedtorepeatiteachtime??";
var text AddMar = URLRoot() & "db/" & [_DBID_NEWITEMS] & "?act=API_AddRecord&_fid_8=" & [Budget Status Flag]
& "&_fid_22=" & [Comments]
& "&_fid_25=" & [Account Code]
& "&_fid_28=" & [Related Company]
& "&_fid_244=" & [Item Status]
& "&_fid_72=" & [General Cost Currency]
& "&_fid_73=" & [General Cost Description]
& "&_fid_122=" & [Number of Days Required]
& "&_fid_156=" & [Item Vendor]
& "&_fid_160=" & [Spend Country]
& "&_fid_161=" & [Related Project Manager]
& "&_fid_9=" & [Recoverable?]
& "&_fid_165=" & [General Cost Quantity]
& "&_fid_164=" & [Predefined Daily Cost Quantity]
& "&_fid_163=" & [Predefined Cost Quantity]
& "&_fid_114=" & [Related People Cost]
& "&_fid_81=" & [Predefined Daily Cost Days]
& "&_fid_71=" & [General Unit Cost]
& "&_fid_69=" & [Related Predefined Daily Cost]
& "&_fid_68=" & [Related Predefined Cost]
& "&_fid_37=" & [Related Fx]
& "&_fid_32=" & [Item Type]
& "&_fid_47=" & [Related Sub-Project]
& "&_fid_241=" & [Original Item Project Category]
& "&_fid_43=" & "3"
& "&apptoken=thisismyapptoken_doineedtorepeatiteachtime??";
var text AddApr = URLRoot() & "db/" & [_DBID_NEWITEMS] & "?act=API_AddRecord&_fid_8=" & [Budget Status Flag]
& "&_fid_22=" & [Comments]
& "&_fid_25=" & [Account Code]
& "&_fid_28=" & [Related Company]
& "&_fid_244=" & [Item Status]
& "&_fid_72=" & [General Cost Currency]
& "&_fid_73=" & [General Cost Description]
& "&_fid_122=" & [Number of Days Required]
& "&_fid_156=" & [Item Vendor]
& "&_fid_160=" & [Spend Country]
& "&_fid_161=" & [Related Project Manager]
& "&_fid_9=" & [Recoverable?]
& "&_fid_165=" & [General Cost Quantity]
& "&_fid_164=" & [Predefined Daily Cost Quantity]
& "&_fid_163=" & [Predefined Cost Quantity]
& "&_fid_114=" & [Related People Cost]
& "&_fid_81=" & [Predefined Daily Cost Days]
& "&_fid_71=" & [General Unit Cost]
& "&_fid_69=" & [Related Predefined Daily Cost]
& "&_fid_68=" & [Related Predefined Cost]
& "&_fid_37=" & [Related Fx]
& "&_fid_32=" & [Item Type]
& "&_fid_47=" & [Related Sub-Project]
& "&_fid_241=" & [Original Item Project Category]
& "&_fid_43=" & "4"
& "&apptoken=thisismyapptoken_doineedtorepeatiteachtime??";
var text AddMay = URLRoot() & "db/" & [_DBID_NEWITEMS] & "?act=API_AddRecord&_fid_8=" & [Budget Status Flag]
& "&_fid_22=" & [Comments]
& "&_fid_25=" & [Account Code]
& "&_fid_28=" & [Related Company]
& "&_fid_244=" & [Item Status]
& "&_fid_72=" & [General Cost Currency]
& "&_fid_73=" & [General Cost Description]
& "&_fid_122=" & [Number of Days Required]
& "&_fid_156=" & [Item Vendor]
& "&_fid_160=" & [Spend Country]
& "&_fid_161=" & [Related Project Manager]
& "&_fid_9=" & [Recoverable?]
& "&_fid_165=" & [General Cost Quantity]
& "&_fid_164=" & [Predefined Daily Cost Quantity]
& "&_fid_163=" & [Predefined Cost Quantity]
& "&_fid_114=" & [Related People Cost]
& "&_fid_81=" & [Predefined Daily Cost Days]
& "&_fid_71=" & [General Unit Cost]
& "&_fid_69=" & [Related Predefined Daily Cost]
& "&_fid_68=" & [Related Predefined Cost]
& "&_fid_37=" & [Related Fx]
& "&_fid_32=" & [Item Type]
& "&_fid_47=" & [Related Sub-Project]
& "&_fid_241=" & [Original Item Project Category]
& "&_fid_43=" & "5"
& "&apptoken=thisismyapptoken_doineedtorepeatiteachtime??";
var text AddJun = URLRoot() & "db/" & [_DBID_NEWITEMS] & "?act=API_AddRecord&_fid_8=" & [Budget Status Flag]
& "&_fid_22=" & [Comments]
& "&_fid_25=" & [Account Code]
& "&_fid_28=" & [Related Company]
& "&_fid_244=" & [Item Status]
& "&_fid_72=" & [General Cost Currency]
& "&_fid_73=" & [General Cost Description]
& "&_fid_122=" & [Number of Days Required]
& "&_fid_156=" & [Item Vendor]
& "&_fid_160=" & [Spend Country]
& "&_fid_161=" & [Related Project Manager]
& "&_fid_9=" & [Recoverable?]
& "&_fid_165=" & [General Cost Quantity]
& "&_fid_164=" & [Predefined Daily Cost Quantity]
& "&_fid_163=" & [Predefined Cost Quantity]
& "&_fid_114=" & [Related People Cost]
& "&_fid_81=" & [Predefined Daily Cost Days]
& "&_fid_71=" & [General Unit Cost]
& "&_fid_69=" & [Related Predefined Daily Cost]
& "&_fid_68=" & [Related Predefined Cost]
& "&_fid_37=" & [Related Fx]
& "&_fid_32=" & [Item Type]
& "&_fid_47=" & [Related Sub-Project]
& "&_fid_241=" & [Original Item Project Category]
& "&_fid_43=" & "6"
& "&apptoken=thisismyapptoken_doineedtorepeatiteachtime??";
$AddJAN
& "&rdr=" & URLEncode($AddFEB)
& URLEncode("&rdr=" & URLEncode($AddMAR))
& URLEncode(URLEncode("&rdr=" & URLEncode($AddAPR)))
& URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($AddMAY))))
& URLEncode(URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($AddJUN)))))
& URLEncode(URLEncode(URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($AddAUG))))))
& URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($AddSEP)))))))
& URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($AddOCT))))))))
& URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($AddNOV)))))))))
& URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode(URLEncode("&rdr=" & URLEncode($AddDEC))))))))))
END CODE (These Forums really need a "Code" snippet button)
_ - QuickBaseCoachD8 years agoQrew CaptainI suggest that you make a button which when clicked will add the next record and display the newly created record. The formula can "calculate" the month number for the next month.
Suffix the API string with &disprec=1 and it will land you on the record.
So then workflow will be to start with any month and then click and it will make the next month and land you on the newly created record, and then click again until you get to 12.