Guest User

Untitled

a guest
Jun 18th, 2018
82
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.56 KB | None | 0 0
  1. // Add Row Button
  2. var oAddButton = new YAHOO.widget.Button({
  3. id:"addButton",
  4. type: 'button',
  5. label:"Add a New Page",
  6. onclick: { fn: function(e) {myDataTable.addRow({PageCategoryName: "", PageTitle: "test", PageDescription: "", PageURI: ""}); } },
  7. container:"addBTN" });
  8.  
  9.  
  10. var newRecordID = function(args) {
  11. myDataTable.unselectAllRows()
  12. myDataTable.selectRow(args.record);
  13. myDataTable.getTrEl(args.record).scrollIntoView()
  14.  
  15. }
  16.  
  17. myDataTable.subscribe('rowAddEvent', newRecordID);
Add Comment
Please, Sign In to add comment