I Have A button Called Update in Doctype ( X) , i want when i press on this Update Button to update Values From Doctype (Y and Z and x). how to make this update with coding.
Please Read this Document
              
              
              1 Like
            
          @omar_salama  Please Love this  
I Hope this help you
your_button: function(){
 		frappe.db.set_value('Doctype Y', name_doc_y, {
			'name': 'Misbah'
         })
 		frappe.db.set_value('Doctype X', name_doc_x, {
			'name': 'Misbah'
         })
}
              
              
              2 Likes
            
          Just reload the page,and save again
no,it is giving this error everytime i save the page and valued doesnt save when i reload and save it again.
Run this Command
bench clear-cache
bench build
bench restart
I am uning this code snippet on custom client script of doctype (front end Js),will it work?
i forget to mention that the data i want to update it’s in child table.
