cancel
Showing results for 
Search instead for 
Did you mean: 

Pass the data from View to the "Page with Flow Logic"

Former Member
0 Kudos

Hi All,

We have a view. I have created a page with flow logic for search help( 2 pages for two fields).From view I am calling the Pages with flowlogic using statement.

document.open('zgrpname.htm', 'groupnamelist', "height = 550 width = 400 left = 200 right = 400 status = no");

and transfering the value in the page to view using

function transf2(fval)

{

document.getElementById("order.detail.edit_grpname").value = fval;

}

MY REQUIREMENT:

As I need to retrieve the Group Name based on another varaible in the view (the Group type), I need to pass the Group type value from the view to the page(Group Name F4 help page).

Please tell me how to achieve this.

Thanks in Advance,

Deepthi

Edited by: Deepthi B on Feb 25, 2010 5:53 PM

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi Rodrigo,

Thanks for your reply. I tried the steps you mentioned.I am able to pass the text using that. Cant we send the dynamic data.

Actually, I have two fields. Based on field1 value the serach help of field2 should work. I tried the export to memory id concept( I exported the value intially when in the view and similarly exported the value in F4 help screen of field1. Then imported the variable in the search help screen of field2.

But we can make the field1 value directly to blank in the view. In that case actually the blank value needs to be exported from view. This was not happening.

Please tell me how to pass the adhoc values from view to page.

Rodrigo-Giner
Active Contributor
0 Kudos

I dont fully understand what you try to say to me.

The problem is that onValueHelp only allow Javascript Functions, there is not event fired when you click in the search help. And there is no direct way of passing variable values from javascript to ABAP.

So, what you could do is the following, make a inputField "invisible" and in the javascript function read that field and pass it like the example before. If it's blank it will pass blank or any value that you set. This way you dont depend on the value "hardcoded" in the javascript function call.

I hope that this solve what you are trying to do, if not I will try to make a example

Good luck

Rodrigo-Giner
Active Contributor
0 Kudos

Just use URL parameters

between the SCRIPT tags


  function getF4(pagina)
  {
  var url = 'F4.htm?pagina='+pagina;
  NewWindow=window.open(url,'newWin','width=500,height=300,left=20,top=20');
  NewWindow.focus();
  void(0);
  }

<htmlb:inputField id="i_VKORG_low" value="<%= i_VKORG_low %>" showHelp="X" onValueHelp="getF4('VKORG')"/>

So when you call function getF4 it will pass the parameter with value VKORG

Then in the function it will concatenate that value...so the URL will be

F4.htm?pagina=VKORG

Then in your F4.htm page set an attribute with the name of your parameter in my example "pagina" TYPE STRING, IMPORTANT CHECK the AUTO checkbox.

You r done... in the F4.htm page you will have the value VKORG in the variable pagina. Or any value that you pass to the function.

I did this to made one F4.htm and not one page for each inputField that I wanted to add a Search Help.

Tell me if you have problems Its working for me.

BTW: you are using MVC right ? did u make your views using views inside views with:


        <bsp:call url     = "search.do"
                  comp_id = "search" >
        </bsp:call>
        

if u did I wanna asking something.

Edited by: Rodrigo Ariel Giner de la Vega on Feb 25, 2010 6:24 PM

Edited by: Rodrigo Ariel Giner de la Vega on Feb 25, 2010 6:25 PM