function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion

custom button to validate a single field

Hi there,


In short, I need a custom button (in edit mode). to validate one field.

I have managed to get a button onto the record edit page via a hack using 'home page components'.



I want to stay away from VF as there are multiple record types etc.


However I don't know how to get this button to validate a field on the record.


can anyone suggest how i'd modify this? At the moment it just opens


•<script type="text/javascript">
var url = window.location.href;
window.onload = function () {
if(url.indexOf('/500')!=-1 && url.indexOf('/e')!=-1) 	
	document.getElementById('topButtonRow').innerHTML = 
					document.getElementById('topButtonRow').innerHTML + 
					'<a class="btn" style="padding: 4px 3px;margin: 0 2px;text-decoration: none;" target="_blank" href=""></a>';