cancel
Showing results for 
Search instead for 
Did you mean: 

empty Input filed problem?

Former Member
0 Kudos

Hi all,

I developped a webdynproapplication. It has contain two views and one custom controller.

I have used to call BAPI and what everinfo contain that will display in second view .

Here my problem I want send my customer nuber from my first view to BAPI input .For that I Created an input field in the first view based on the input bapi will called.

But In the first view some time I dont want to take the input value from the input field directly when i press submit button What everuser enter into the portal that will automatically goes to the BAPI.Here only my problem.

My problem is I have call the user and give the condition in that Init() mehtod of the first view But My Empty input field will check in the OnSubmit() method.

How can Check empty input field in the OnSubmit() method If it true How can I send it to Init() method.

init()

{

getting user from portal and

bapi b = new bapi();

if(portaluser=="121")

{

input field var inf;

if(inf ==null)

b.set(121);

else

b.set(portaluser)

}

else

b.set(portaluser);

But These empty Input will check in only OnSubmit() only.

How to pass conditon(null) to Init mehtod .

Otherwise any other method help me.

Please guide me for this.

Nageswara

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

I'm assuming the uesr is clicking a button or something to initiate what you call the OnSubmit. If that is tied to an action, set the action to be run 'without validation'. Then in the action check to see if the input field is empty and set the value based on your portal user. If you want to run the same code as in your init method, just pull that part out and make it a separate method and call it from both the init and the submit action methods. Be sure to put that separate method in between the begin/end section at the bottom where the private 'other' code goes.

-Cindy