Hi,
Working on a small inventory system here and running into bumps along the way. I am importing some 900 entries into this form and trying to populate a unique inventory number for each. The On Add > On Success or On Edit > On Success actions I've setup dont work for bulk edits or imports, so im thinking maybe its an idea to just have a button in the report that says 'Update Inventory Number' for those times that new records are imported which is hardly. But I dont want to go and manually update 900 entries.
I am trying to create a function in the report view that when selected, will grab data from a few fields :
First Name (First_Name)
Last Name (Last_Name)
Year (Year)
and then populate those values into a field called Inventory Number (Inv_Num1).
I attempted to create a custom function with this
- string InventoryNumber.UpdateInv(string Inv_Num1)
- {
- FN = input.First_Name.subString(0,1);
- LN = input.Last_Name.subString(0,1);
- YR = input.Year.subString(2,4);
- outputstr = FN + "/" + LN + "/" + YR;
- return outputstr;
- }
That of course resulted in an error saying First_Name is not declared. Im extremely new to Deluge scripting so im not really clear how I have to declare those values. Any help is much appreciated