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
SirishaMSirishaM 

How to override button functionality

Hi,

I have created a VF page with custom extension in which I will be taken to a new page when I click a "Attach File"
button.

My problem is once I am taken to new page , I want to check a condition before I save the file. So I want to overrde the "Attach File" button in Save page of Notes and Attachment section . Is that possible ?

I can not write a VF page for  the rendered page ..so how can I overwrite the button?

Thanks,
Sirisha

SirishaMSirishaM
In short, I want to override the button in the page rendered by Pagereference method .

Sirisha
Ron HessRon Hess
There is no way to override that button with visualforce, i don't think there is an attach file component either.  you would have to write your own javascript form to use the attach servlet, and that is not a supported API.