return false is returned at onClick event in apex command button

Hi Folks,

I have two apex command buttons namely SaveDraft and Submit. I'm calling a apex page Reference method in action tag of command button. But I did not call any javascript function at Onclick event.Moreover, you could see it is returning return false statement which prevents my action getting called.

Please provide your inputs to get me out of this problem

Here is the code to be called by apex commandbutton Save Draft.

public Pagereference SavePartialSurvey() {     try{     system.debug('inside SavePartialSurvey');     SubmitSurvey(false);     system.debug('-------------------'+bVal);     if (bVal == true) {         ResultPanel = true;         QuestionPanel = false;         ApexPages.addMessage(new ApexPages.Message(ApexPages.Severity.Info,'Your survey has been saved successfully. Please click on the same link to complete the survey.'));          return null;     } else {         return null;     }     }     catch(Exception ex)     {         system.debug('Message+++'+ex.getMessage());         system.debug('LineNumber+++'+ex.getLineNumber());     }     return null; } 

here is the link

Thank you, prasanth

Replay

Category: apex Time: 2016-07-31 Views: 3

Related post

iOS development

Android development

Python development

JAVA development

Development language

PHP development

Ruby development

search

Front-end development

Database

development tools

Open Platform

Javascript development

.NET development

cloud computing

server

Copyright (C) avrocks.com, All Rights Reserved.

processed in 0.127 (s). 12 q(s)