i have two collectons, one is colled royaldynasty and the other is called Variables.
i want that every time data enters the royaldynasty collection there be a function in the Variables collection that takes the value of the item in the first row in the column kingsFortune in the royaldynasty collection, and insert that value in the first row in the column currentFortune.
so i think i need to use the afterinsert() but i dont know how to write that when the data is inserted from a differnt collection. and how i write the code that take the item frim the first row in a specific column.
i will love if someone will show me how to write the code and explain to me so in the future i could write code by myself, thanks from advance and sorry for the bad english :).