How can a jsp page tell which Oracle Responsibility the user has selected?

We have two responsibilities - Timecard Administrator and Timecard Viewer. Everything that they can access is the same, except for one particular jsp page which we want to present a slightly different view if the user's responsibility is Timecard Viewer (specifically, the edit link in the results page will be suppressed). Unfortunately in order to implement this, the jsp code needs to be able to distinguish which of those two responsibilities the user has selected. I have written jsp code to print all the environment variables and unfortunately the environment is essentially identical regardless of which of the two responsibilities the user selected.
How do I pass in the active responsibility to that page/environment in a way that can be tested by the jsp code?
Thank you,
Graham Toal <[email protected]>

Yes, I tried something like this (shortened to the basics for this post):
<pre>
sqlQuery="select responsibility_name from fnd_responsibility_vl where responsibility_id = FND_GLOBAL.RESP_ID";
stmt=con.createStatement();
rs=stmt.executeQuery(sqlQuery);
int field_count=rs.getMetaData().getColumnCount();
while (rs.next()) {
for (int i=0; i<field_count; i++) {
logger.write("Responsibility: "+rs.getObject(i+1),"JSP",objName,0,-1,1001);
</pre>
However it did not print any results at all.
I'm trying a different approach at the moment - I've cloned the menus from the Administrator responsibility to the new Viewer responsibility, and have altered the top-level menu so that I can insert a new variable into the process state myself; that way by the time the user navigates to the changed page, there should be a variable there that can be tested.
Unfortunately the top-level menu isn't just a simple menu, it's a piece of code that issues an HTML redirect depending on the parameter passed in - which is set in the Oracle function screen for the function attached to that menu.
(was something like utpa_top_menu.jsp?ADMIN and I changed it to utpa_top_menu.jsp?VIEWER, with appropriate tests for the new module name:
<tt>
else if ("VIEWER".equals(moduleName))
url = "/utpa/jsp/admin_reports-viewer.jsp";
</tt>
In admin_reports-viewer.jsp I've added <tt>session.putValue("REPVIEWER","y");</tt> and in the actual target main page I have:
<pre>
if (session.getValue("REPVIEWER") == "y") {
// viewer
out.println("<CENTER><B>You are using the Timecard Viewer responsibility</B></CENTER><BR>");
} else {
</pre>
And although the URL bar at the top of the screen is displaying the correct (redirected) URL, the page that is displayed is blank. Completely empty. 0 bytes. The file is present on the filing system; has content; has the correct ownership and permissions; I've reloaded apache, even had the systems guys reboot completely. I'm at a loss :-/
Graham

Similar Messages

  • How can I hide page thumbnails navigation bar at the start up of Adobe Reader and open a pdf file?

    How can I hide page thumbnails navigation bar at the start up of Adobe Reader and open a pdf file? I could not find this option under Preferences tab? Thanks

    Hey there,
    Thanks for your reply. That works for the files I do what you said. However, for files I have not done that, It still shows the navigation bar. Any idea, how to do it default for any files?
    Thanks agian

  • I just bought macbook pro with 10.8.3 os. When i start the system, all applications automatically start up as well! How can I turn them off. I checked the user settings and no application is set tom open automatically!

    I just bought macbook pro with 10.8.3 os. When i start the system, all applications automatically start up as well! How can I turn them off. I checked the user settings and no application is set tom open automatically!

    You have 14 days to return the computer w/no questions asked.  Plus you have 90 days of FREE phone tech support on top of your standard 1 year warranty unless you also purchased AppleCare which gives you an additional 2 years of coverage plus FREE phone support.
    Strongly suggest that you take FULL advantage of the above before it runs out.  Let Apple deal w/the problems.

  • How can I create a scrolling effect where when the user scrolls down the image will blur out?

    How can I create a scrolling effect where when the user scrolls down the image will blur out?

    Hi there,
    You can create a scroll motion where the image will fade out on scrolling, you need to use the Opacity tab under Scroll Effects Panel.
    If you particularly need the image to be blur out, then you need to edit that image in any image editing program and make one copy of that image as blurred, then place both images (actual and blurred) on that page and use scroll motion or fade option to replace images.

  • How can I uninstall Trend Micro Safe Surfing once the app has been deleted from my Mac OS X?

    How can I uninstall Trend Micro Safe Surfing once the app has been deleted from my Mac OS X?

    Check to see if there's such a folder as  either
    /Library/Application Support/Trend Micro
    ~/Library/Application Support/Trend Micro
    and if so, see if either contains an uninstaller.
    Failing that, download the demo version of the app from Trend Micro, and try the uninstaller that it should contain.
    If all else fails, the manual way would be to use something like EasyFind and search for anything with "com.trendmicro" in the filename (you can use Finder, but be sure to include system files and invisible files in the search options). Pay particular attention to the folders
    /Library/LaunchAgents
    /Library/LaunchDaemons
    ~/Library/LaunchAgents
    ~/Library/Internet Plug-Ins
    ~/Library/Preferences

  • How can I extract pages from a PDF? The Tools menu is missing.

    I used to be able to extract pages from my PDF file. I don't see the tools icon anymore. How can I access the tools icon?

    Hi lenm,
    To extract pages, you need to use Acrobat (not Adobe Reader). As I can attest (because I do have both Reader and Acrobat installed on the same computer), it is quite easy to open files in Reader when you mean to open then in Acrobat. So, please make sure you have the right app open. (I pull this one all the time!)
    Now, if the Tools menu is missing from Acrobat, choose View > Show/Hide > Toolbar Items > Show Toolbars to make them reappear.
    Please let us know how it goes.
    Best,
    Sara

  • How can I separate 2 ipads which are on the same account?

    I have an ipad and my husband also recently bought one.  Unfortunately my son set my husband's ipad up on the same account as mine so we now have exactly the same music and photos on both plus my Gmail account is sending the messages to both.  How can I separate these now but still carry on using the same laptop?

    You will have to transfer the ringtones from the phone that has them to your iTunes library.
    File>Transfer Purchases.
    Then you can sync them to the other phone.

  • How can I create icloud account which I tried and it has showing the message that multiple free accounts have been activated on this device how should I install icloud and I got from apple support if you have mac then create a new icloud account but I don

    How will have an option to create an icloud id

    Hello there, vishal274.
    The following Knowledge Base article provides a great FAQ that provides some great answers to some of the more common questions about iCloud, including yours:
    Creating an iCloud account: Frequently Asked Questions
    http://support.apple.com/kb/ht4436
    How do I sign up for iCloud?
    You can sign up for iCloud on an iPhone, iPad, or iPod touch with iOS 5 or later, or through System Preferences on a Mac with OS X Lion v10.7.4 or later. Just follow the setup instructions for your iOS device or Mac.
    You may need to verify the email address that you use for your Apple ID. See Frequently Asked Questions About Apple ID for more information.
    I had a free Find My iPhone account. How do I sign up for iCloud?
    Update the devices that you use with Find My iPhone to iOS 5 (iOS 6 recommended). When you're asked to enter an Apple ID during setup, enter the Apple ID you were using for Free Find My iPhone. Your account will be automatically updated to iCloud.
    I had a MobileMe account. How do I sign up for iCloud?
    To use your MobileMe account for iCloud, follow the iCloud setup instructions and enter your @me.com or @mac.com email address as your Apple ID. If you had an @me.com address, it will be reactivated for email when you sign up for iCloud. If you had an @mac.com address, it won't be reactivated for email, but you can set up a new @icloud.com email address to use with iCloud.
    Important: You will need a verified email address associated with your @me.com or @mac.com Apple ID to set up iCloud. To add a verified email address, go to My Apple ID (appleid.apple.com), sign in with your @me.com or @mac.com email address, and add a valid email address to your account.
    Thanks for reaching out to Apple Support Communities.
    Cheers,
    Pedro.

  • How can I delay my MBP from hibernating until the lid has been closed for a set period of time?

    After extensive research, I have been unable to solve this problem and I'm hoping someone can explain this to me.   Everytime I close the lid on my 13-inch, Early 2011 Macbook Pro, it immediately starts to write to disk (solid light on the front) for several seconds until it finally goes into Hibernate mode (flashing light on the front).  The problem is, I frequently close the lid, then immediately reopen it within 15-30 seconds to resume typing or to add something I may have forgotten.   Each time I reopen the lid before the light has started flashing, the MBP wakes for a moment, and allows me to resume typing.  However, the Hibernation process has already begun and within 30 seconds, the screen goes blank.   I have to wake it AGAIN, which is very annoying.
    Based on my research, I could use pmset to change the hibernatemode to 0 (it is currently set at 3).   However, I dont wish to disable hibernate mode completely; I DO want it to save a hibernation image to disk if it happens to run out of battery, so that when I resume I havent lost anything.   
    I then researched using standby and standbydelay to attempt a delay of the write to disk when going into standby mode.   According to the pmset manual:
    standby causes kernel power management to automatically hibernate a machine after it has slept for a
         specified time period. This saves power while asleep
    standbydelay specifies the delay, in seconds, before writing the hibernation image to disk and powering
         off memory for Standby
    I then set these values as below, expecting the laptop to wait 4200 seconds (70 minutes) before trying to write to disk when I close the lid:
    standbydelay         4200
    standby              1
    Unfortunately, that did not work either.   If I close the lid, the light glows solid immediately (indicating it is writing to disk), and if I try to reopen the lid before it is done, it will wake and seem fine, then 30 seconds later it goes blank right in the middle of me typing something.   I usually have to click the mouse several times, or even the power button to re-wake it.  
    I do have InsomniaX installed, for when I want to close the lid and keep the machine awake permanently (while watching videos on airplay) and I have tried quitting that application to test this.  However, when I close/reopen the lid..the result is the same.   I cant keep InsomniaX enabled all the time, because it will never go to sleep when I truly want it to.   If I am not using InsomniaX, I just want to delay hibernation until he lid has been closed for a set period (say 15 minutes or more).  If I have not reopened the lid within that time, I want it to write to disk and go into hibernation mode.  And if the battery runs all the way out, I want it to go into hibernation mode before shutting down so I can recover.
    I would appreciate any help in solving this problem.  Also any insight as to why the standbydelay setting above did not work.   Thanks!

    Whats with the MBP lid? Dont close it ... if you're so concerned! Just go to System Preferences/Energy Saver and set it to how you like it.

  • I have created a newsletter in indesign cs4 how can I set zooms for each article for the user

    I have created a e-newsletter in Indesign. I have successfuly saved it as a SWF then as a PDF from acrobat.
    The problem is that when the user zooms in the resolution is not good.
    How can I let the user zoom in to read each article. Would I create buttons with zoom settings for each article. If this is the case do I do it in Indesign or Flash and can I still save it as a PDF file and it will keep the interactivity?
    I would greatly appreciate any help with this issue. It is driving me mad trying to get the information I need.
    Thank you

    Hi Bob
    Dont know what you mean by deleting my signature in the forum. Sorry its my
    first time using a forum.
    So just to confirm if I want a user to zoom in on an article I can't do it
    in Indesign or Flash.
    cheers
    PAMELA
                                                                                    BobLevine                                                    
                 <[email protected]                                            
                 >                                                          To
                                           pamela hettrick                    
                 17/08/2010 14:09          <[email protected]>  
                                                                            cc                                                                               
    Please respond to                                     Subject
                 clearspace-143433         I have created a        
                 1873-767197-2-305         newsletter in indesign cs4 how can 
                 [email protected].         I set zooms for each article for   
                     adobe.com             the user                                                                               
    You don't. There are third party solutions available for that. Sorry but I
    don't have any links handy right now.
    And please delete your signature...it's making a mess of the forum display
    of your posts.
    Bob

  • How can I read an input which only contain the 26 upper case letter

    Are there any method that can read an input which only contain 1 character and it is in upper case too.
    should I use readChar( ), or readString( )??
    How should I implement them if I do use one of them?
    thx

    Try this :
    import java.io.*;
    public class Read
    public static void main(String[] x)
    System.out.println("Upper case char typed : "+readUpperCaseChar());
    public static char readUpperCaseChar()
    // method that read char and return the last upper case char
    char x='\0',tmp='\0';
    try
    while(tmp!='\n')
    tmp=(char) System.in.read();
    if(tmp >= 'A' && tmp <= 'Z')
    x=tmp;
    catch(IOException ioex)
    ioex.printStackTrace();
    return x;

  • How can I save pages as a document with the new Mavericks version of pages?

    Is there any way to save a pages document as a Microsoft document?  Additionally, is there any way to save a numbers document as an Excel document?
    Since I have downloaded the new Mavericks software with the new Pages, Numbers, and Keynote, I can't save anything as a Microsoft document anymore.  Can anyone please help?  I'm a student needing an answer because most institutions only use Microsoft.  This is an extremely upsetting fall back for Apple if there isn't a way to accomplish these activities.
    Also, if anyone has any information if Apple is going to provide new drivers for old HP printers and scanners, please inform me.  My multi-functional printer is obsolete (according to a phone conversation with HP).  Currently, I have to jump through hoops to get the scanner to work and Preview crashes most of the time (with the Mavericks update). 

    Welcome to Apple Support Communities
    iWork does not let you save a document as an Office document by default, so you have to do some extra steps. First open the document and go to File menu (on the menu bar) > Export to, and choose the Office app to create a document for Microsoft Office.
    Respecting to printer drivers, Apple does not provide newer drivers for an obsolete printer. Instead, see if Gutenprint works > http://gimp-print.sourceforge.net/MacOSX.php

  • How can I make a synced audio track match the length of selected clips in a multicam seq?

    I have a continuous multicam sequence of about 13 minutes containing a synced master audio track recorded from seperate microphones. I want to rearrange scenes from it into my final sequence, but when I select a range of clips to nest the entire length of audio gets pasted into the new sequence. I want to trim the audio to match just the clips I've selected but not lose sync. Is there a way to do this or is nesting not the way to chop up a sequence and rearrange the scenes in it?
    Thanks.
    Mike

    Me too!!!  I have a multicam sequence from 2 cameras with the audio staying on camera 1. I also have a seperate, continuous  audio track recorded from microphones which I have synced to the timeline. I'm trying to select a group of sequential clips of different camera angles from the timeline to create scenes which I can insert into a final sequence but in a different order from how they are on the timeline. Let's say I want to take a series of clips that start at 3:30 on the timeline and go until 4:30 on the timeline.  It will contain several cuts between the different cameras and I want to use that section as the first scene of my new sequence. If I select all of the clips in that time period and nest them into a new sequence, I only get the audio from camera 1 on the new TL. If I try window selecting those clips to include the continuous audio track, I get a new TL with 3 minutes and 30 seconds of the desired audio, then the video clips, and then the rest of the audio making a 13 minute TL. I just learned, after searching around, about marking in and out points on my multicam seq. and using the trick of "LIFTing" and then "UNDOing" to keep my  multiseq intact, and then pasting into a new sequence. That works, but I'm only getting the audio track from off the camera. It won't select and lift the section of the other audio track that I want. I'm rushed for time so that's the way I've ended up finishing the video for now. The camera audio is just going to have to do although the mic recording is much better. The more I try to explain this the more confused I get and I'm sure everybody reading it does too. Any ideas?   Thanks!

  • How can i find out what cursor the user has selected on an xy graph?

    I have an XY graph in which while the program runs it will be creating cursors in certain locations on the plot. I want to give information about this cursor when selected upon, I THOUGT that active cursor does this.. but appreently not.. it seems to jsut keep spitting out 0, any ideas?

    > I have an XY graph in which while the program runs it will be creating
    > cursors in certain locations on the plot. I want to give information
    > about this cursor when selected upon, I THOUGT that active cursor does
    > this.. but appreently not.. it seems to jsut keep spitting out 0, any
    > ideas?
    You might look at the Selected Cursors property. It indicates which
    cursors will be acted upon by the movement palette. It should be
    equivalent to the small LED buttons on the cursor palette.
    Greg McKaskle

  • How to find if the user has selected one or many files using a file chooser

    I have a file chooser but want it to return either a file or file array depending on whether more than one file is selected but there doesn't seem to be any way to find out if that is the case or not. I want it to look something like:
                if(fileChooser.getSelectedFile().isDirectory()==true)
                    selectedFile=fileChooser.getCurrentDirectory();
                else if(fileChooser.multipleFilesSelected())
                    fileChooser.getSelectedFiles();//we have more than one file selected
                else   
                    fileChooser.getSelectedFile();    //if we have one file selected
                }am I going about dealing with this in the right way?

    OK, I scoured the API again and found I could avoid the problem altogether by using
    http://java.sun.com/j2se/1.4.2/docs/api/javax/swing/JFileChooser.html#isMultiSelectionEnabled()
    and
    http://java.sun.com/j2se/1.4.2/docs/api/javax/swing/JFileChooser.html#setFileSelectionMode(int)

Maybe you are looking for