Stack Exchange network consists of 183 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
I want to create a VisualForce login page.Only my contacts with their username and password which is filled in the custom fields of account object should be able to redirect to next page.
Is the next page navigation triggered from a button on the Account pagelayout?
If thats the case, you can have a java script to validate the two custom fields and then if the condition is passed then call the VF using
window.location = 'apex/YourVisualforcePage';
Hope it helps,