Global Variable Declaration in ProcessRequest Method

Hi All,
i need to declare a variable(Global) in Process request Method and then i need to pass this variable value in ProcessRequest Method of Another Page.
it is possible to declare a Global Variable in ProcessRequest Method.
Process Request Method:
if(pageContext.getSessionValue("varBatchID")!=null && pageContext.getSessionValue("varCustomerID")!=null)
System.out.println("Second Else From Drill Down");
String strCustID=pageContext.getSessionValue("varCustomerID").toString();
String strBatchID=pageContext.getSessionValue("varBatchID").toString();
System.out.println("CustomerID:"+strCustID);
System.out.println("strngBatchID:"+strBatchID);
Serializable[] parameters={strCustID,strBatchID};
OAMessageStyledTextBean oamessagestyledtextbean=(OAMessageStyledTextBean)createWebBean(pageContext,"strCustID");
oamessagestyledtextbean.setText(pageContext,"strCustID");
pageContext.getApplicationModule(webBean).invokeMethod("backTocusttrxn",parameters);
pageContext.removeSessionValue("varCustomerID");// Here i need to close this session Value and at the same time i need to pass this session value to another page PR Method. SO For that i need to Declare a variable(Global) and pass that variable value to another page.
pageContext.removeSessionValue("varBatchID");
Could you please any one give me the solution for this.
Thanks,
Mallik.

Hi ,
Create transaction variable and pass your value into that and get the same in other CO using below code,
pageContext.putTransactionValue("IrcSelectedPersonId",value)
pageContext.getTransactionValue("IrcSelectedPersonId");
Regards,
Vijay Reddy.

Similar Messages

  • How to go to java section global variable declaration

    Hi all
    i am following this scenario
    http://www.sdn.sap.com/irj/scn/weblogs;jsessionid=(J2EE3417100)ID0446700150DB10376299506581707969End?blog=/pub/wlg/11287
    in this scenario 3rd screen shot is about global variable declaration:
    In order to build the content of the attachment (for this particular requirement) we use a global variable declared and initialized in the global sections :
    can any body tell me how to go to this java section screen , as i am unable to find this java screen....
    Thanks
    sandeep

    even i cant see this edit java section
    i am working on PI 7.1. has this feature been removed in pi 7.1
    this is replaced in PI7.1 ... check this blog on how to use the "global" variable in PI7.1:
    /people/william.li/blog/2008/02/13/sap-pi-71-mapping-enhancements-series-using-graphical-variable
    Regards,
    Abhishek.

  • Global Variables declaration in PI 7.1

    Hi All,
    In message mapping where can I declare global variables in PI 7.1.
    Thanks and regards
    Uma

    Hi Sarvesh,
    Thank you for the response.
    The blog given by you is on PI 7.0, But icon(Java Sections) is not present in PI 7.1 mapping editor .
    Please guide me how can I proceed further.
    Thanks & regards
    Uma
    Edited by: Uma Balasubramanya on Mar 20, 2009 1:11 PM

  • Global Variable declaration in Custom Infotype

    Hi All,
    I need to validate a custom infotype field, where i need to check for execution times. I need to override the field value only during first time of the run(PAI logic) and there after user can choose a value of his choice.
    I was looking out for Global variable to check if its first run. Can you please tell me how do i create global variable in custom infotype? The top include specified in the program is not editable, being standard (MPH5ATOP).
    Thanks,

    >
    Sachidanand B wrote:
    > Hi All,
    >
    > I need to validate a custom infotype field, where i need to check for execution times. I need to override the field value only during first time of the run(PAI logic) and there after user can choose a value of his choice.
    > I was looking out for Global variable to check if its first run. Can you please tell me how do i create global variable in custom infotype? The top include specified in the program is not editable, being standard (MPH5ATOP).
    >
    > Thanks,
    The system will generate an include with the naming convention ZP<Custom Infotype number>10(This program will be included in the custom infotype main program ZP<Customeinfty number>00). You can use this include for your data declarations.
    Ex: if the number of the custom infotype is 9010 the generated include name will be ZP901010.
    For more details check the link below
    http://help.sap.com/saphelp_47x200/helpdata/en/4f/d525ad575e11d189270000e8322f96/content.htm
    Regards
    Rajesh:

  • Global Variable Declaration in PI 7.1 EHP 1

    Hi Experts
    How can I declare the Global Variables in PI 7.1 EHP 1 , please let me know if there is any blog in Enhancement Pack 1
    Thanks
    PR

    On PI7.1 global variables have been removed.
    You can try one of the following:
    1. Create a global variable within an UDF;
    2. Use the solution from the blog below:
    /people/william.li/blog/2008/02/13/sap-pi-71-mapping-enhancements-series-using-graphical-variable

  • Global variable declaration in form routines

    Hi All,
    i am new of the smartforms, i have a small problem in smartforms.
    i need to display the one text based on the condtions, already i have putted the condtions in the condition tab for the text, i need to compare the one more condtion, the condtion is TB_INFORMATION IS NOT INITIAL.
    the code was devaloped in the formroutines , i need to implement the one condtion in the form routines,
    the condition is if TB_INFORMATION IS NOT INITIAL is not initial
                                  va_information = x.
                                endif.
    already i declared the variable in the global defination ,but i am getting the error.
    where can i declare the global variable in form routines.
    Please help me,
    Thanks & Regards
    charan

    declare in global data and it will be visible and available in form routines too.

  • Static used on global variable declaration

    I have inherited a CVI project that contains a single .C file and a couple of .UIR files with their associated .H files.
    Many of the global variables have STATIC in their declaration - I believe this is due to the fact the original developer originally had them inside various functions and at some point changed strategy to make them global, leaving the STATIC keyword in place when copy/pasting.
    As I understand it the ONLY implication of STATIC on a global variable would be to keep its visibility only to the .C file in which it is declared. In this instance that is moot since there is only one .C file in the project.
    Is there anything about LabWindows/CVI which I might not be aware of that makes this use of STATIC cause something different than if STATIC were not used?
    Thanks for any input you might have since I'm new to CVI

    Roberto and menchar said it well:
    "static variables are declared at compile time and survive when their block of code terminates. If declared at function level, their value survives from one call of the function to another, so that they can be used over time to store permanent values locale to the function. If declared at module level, they are common to all functions in the module and are allocated outside the stack so that their values are not lost during program life. In every case they can be accessed and modified in values by functions in the program. If arrays, they cannot be dinamically changed in size."
    "The static keyword can be used with a function name also, meaning the function name isn't exported to the linker, and the function is in scope only to code within the module."

  • Apex- global variable declaration

    Dear Friends
    I am very new to Oracle applicaiton express,
    Please let me how to declare global variable in an applcation. The variable should be accessible throught ot all the pages in that applicaion. Any one can help?

    Hi,
    use an application item for that purpose.
    Just navigate to Shared Components->Application Items and create what you need.
    Regards,
    Moritz

  • Variables declared in static methods

    Hi,
    I've got a question. Are variables (primitive and Objects) declared inside
    static methods stored in a same memory space or are the stored separately?
    I'm creating a helper class that contains static methods that canno be placed in any object in my object map.
    For example
    public static String SampleMethod(String passedString)
    String str = new String(passedString);
    ...do some more processing and sleeping
    return str;
    Let's say Object1 and Object2 make a call to SampleMethod. Object1 passes "Object1" and right before the Object1's SampleMethod returns str, Object2 makes a call passing "Object2". What would be the value of str for Object1's SampleMethodCall?
    Thanks :)

    If speaking about class members, then static members are stored in one place and are properties of the class, when non-staic members are stored in an object's memory and a properties of an object.
    However in your sample it's not the case.
    Local variables of a method are most likely allocated on registers or on stack (thus being rather properties of the call to a method).
    Thus in your case calls to SampleMethod done by Object1 and Object2 simultaneously (if you managed to do this in two different threads) will use different memory (most likely in threads' own stacks).
    As for calls to "new String" inside your method, the new string memory will be allocated dynamically each time the new operator is called, thus producing two different objects. The references to them will be stored in two local variables of two independent calls.
    Finally, Object1 will get a copy of "Object1" and Object2 will get a copy of "Object2", as expected.
    Vit

  • Global variable declaration

    Hi all,
    can u please tel me hoe to declare the variable globally in abap report so that i can use it in any of my include program in that report.
    thanx....

    >
    MONIKA DHUMAL wrote:
    > Make all Data Declarartions in TOP include.
    >
    > like
    >
    > REPORT  ZSDR_INV_INR.
    >
    > include ZSDR_Di_TOP.
    > include ZSDR_DI_FORM.
    >
    > START-OF-SELECTION.
    >
    > PERFORM get_sales_data.
    > perform get_delivery_data.
    > perform process_data.
    > perform refresh_tables.
    > perform get_sales_data_ZIO2.
    > perform get_delivery_data_ZIO2.
    > perform process_data_ZIO2.
    > *Perform Filter_Fieldcat.
    > perform display_report_DI.
    >
    >
    > Here make all ur data declarartions in ZSDR_Di_TOP .
    >
    > THEN U CAN USE ALL VARIABLES GLOBALLY.
    and if i also  have some standard includes with them, but im not making any changes to them
    like.
    std incl
    std incl
    Z    incl
    std incl
    Z   incl
    like this .
    still will it be work in this condition??
    thanx..

  • PL/SQL package global variable in Dev. 6i and newer....

    Hi,
    In db packages , the use of global variable is an appropriate method to keep the value it contains globally... without the danger of being overriden by other session....(as for each session , there is a 'private' section in memory(library cache)).
    Is the above also true to pl/sql packaged global variables kept at client's side(forms/reports)...????
    Thanks,
    Sim

    db-package variables are global to your session
    forms globals are global to your forms application
    In one case you have trouble: When you start a new forms via open_form (, new session, ) then your db-globals are global in that new session, while your forms globals are the same in all forms of the actual forms - session

  • Global variable in BADI methods..

    Hi,
         How can i declare a global variable in BADI  method ,for example " Count type I".Can any one let me know ...
    Regards,
    Veera

    Hi,
    BADI is a just an interface definition that needs to be implemented by the customer. The final implementation of a BADI is always found in a class.
    You can define the variable as attribute and static if you want it to be accessed by all objects.
    I hope this answers your question
    Regards,
    Saurabh

  • How define a global variable in a class that all the methods will recognize

    hi friends,
    i need to define a global variable in a class that all the methods will recognize it.
    any suggestions?
    thanks,
    dana.

    Dera Dana,
    In se24, create your own "Z" class.
    Open the Attributes tab.
    Insert your variable in the declaration part.
    EQ:
    Attribute     Level                       Visibility   Typing      Associated Type         Description        
    ITAB     Instance Attribute     Public     Type     Structure name     Description
    In the Layout of View page,
    <phtmlb:formLayoutDropDownListBox id                = "Dropdown"
                                              label             = "Drop Down"
                                              table             = "<%= controller->Itab %>"
                                              nameOfKeyColumn   = "CODE"
                                              nameOfValueColumn = "VALUE"
                                              selection         = "<%= controller->feild to be selected %>"
                                               />
    Hope this will be helpful
    Regards,
    Gokul.N

  • Use global variable in reports which is declared in forms

    Hi All,
    I have declared and used a global variable in Forms and after that I'm running a report and I want to use the same variable in reports.
    How can I use that.
    Regards
    Praveen Kr. Arora

    Hi Rizwan,
    Thanks for prompt reply.
    Can you explain in more detail with example.
    Though I'm calling report from menu item and I have created report file with three parameters.
    In menu item I have created a parameter list with same three parameters but whenever I tried to run then it gives Invalid ID error for all three parameters.
    Regards
    Praveen Kr. Arora

  • How to declare global variables using another global variable in ODI

    I am declaring a gloabal variable using another global variable.
    say for example:
    I have a global variable empid.
    I am decalaring another global variable empname in refreshing tab of global variables and the select statment is
    select empname from emp where empno = #GLOBAL.empid -------if i write like this i am getting error as invalid character.
    select empname from emp where empno = '#GLOBAL.empid'-------if i write like this i am getting error as invalid number.
    I have kept the datatype as numeric and action as non persistent
    Please help
    Thank you in advance.

    Hi,
    You cant test/refresh empname standalone.
    You need to create a new package drag and drop both variables and make them as refresh variable and execute that package and test.
    Flow,
    empid----> empname
    Thanks,
    Guru

Maybe you are looking for

  • How to avoid that two or more people altering the same Sales Order

    I'm looking for a way to avoid that two or more people altering the same Sales Order at the same time. If someone has entered a Sales Order in the system and something needs to be adjust it can be done by two or more people at the same time. The prob

  • Using CC on multiple devices

    Can I use a single licence CC on my Mac book Pro and Mac

  • Incorrect query forms in parent child relation

    Hello I am using jdev of RUP3 (Release 4) which is 11.1.1.6.2 and have following scenario I have a ParentVO (ProfileVO) and a child VO(CreditReceiversVO) (child VO is basically extended from another VO not in this application and included as a jar li

  • BTE Failing for WBS Element

    Hi, I need to modify the document created using FB01 / MIRO for WBS Element. I could not find any user exit or BADI to do the same. So I tried the BTE 1120... I added a structure to BSEGSUBT to add the WBS Elements... And in the FM for 1120, I am pas

  • Run-time DLL in CVI 8.0

    I never work bevore with DLL but I want to learn it. So I create without big problems a program with a static DLL in LabWindowCVI 8.0 Now I want understand the handling of dynamic DLLs. I read this (http://digital.ni.com/public.nsf/websearch/8AE57BD​