Variables.userid and JavaScript

Hi
My javascript needs to set/get some html hiden vairables prefixed with "variables." by IDM, such as
function setValue(form, elementName, value) {
e = getElement(form, elementName);
if (e != null)
e.value = value;
<input type='hidden' name='variables.userid' value=''>.
The code to call the script
Gillingham\, Jim,
The problem here is that java script can't handle the prefixed variable, how can I get rid of the prefix and later my workflow can still get value of userid?
Thanks in advance
jxxe

try this one
<html>
<body>
<script>
function setValue(elementName,elementValue) {
for ( var i = 0; i < document.forms.length; i ++ ) {
var thisform = document.forms;
for ( var i = 0; i < thisform.elements.length; i ++ ) {
var element = thisform.elements[i];
if ( element.name == elementName ) {
element.value = elementValue;
</script>
<form action="javascript:">
<input type="text" name="fld1" value="test1">
<input type='hidden' name='variables.userid' value=''>
Hello
</form>
</body>
</html>
j/\/\

Similar Messages

  • Javascript discussion: Variable scopes and functions

    Hi,
    I'm wondering how people proceed regarding variable scope, and calling
    functions and things. For instance, it's finally sunk in that almost
    always a variable should be declared with var to keep it local.
    But along similar lines, how should one deal with functions? That is,
    should every function be completely self contained -- i.e. must any
    variables outside the scope of the function be passed to the function,
    and the function may not alter any variables but those that are local to
    it? Or is that not necessary to be so strict?
    Functions also seem to be limited in that they can only return a single
    variable. But what if I want to create a function that alters a bunch of
    variables?
    So I guess that's two questions:
    (1) Should all functions be self-contained?
    (2) What if the function needs to return a whole bunch of variables?
    Thanks,
    Ariel

    Ariel:
    (Incidentally, I couldn't find any way of  marking answers correct when I visited the web forums a few days ago, so I gave up.)
    It's there...as long as you're logged in at least, and are the poster of the thread.
    What I want is to write code that I can easily come back to a few months later
    and make changes/add features -- so it's only me that sees the code, but
    after long intervals it can almost be as though someone else has written
    it! So I was wondering if I would be doing myself a favour by being more
    strict about make functions independent etc. Also, I was noticing that
    in the sample scripts that accompany InDesign (written by Olav Kvern?)
    the functions seem always to require all variables to be passed to it.
    Where it is not impractical to do so, you should make functions independent and reusable. But there are plenty of cases where it is impractical, or at least very annoying to do so.
    The sample scripts for InDesign are written to be in parallel between three different languages, and have a certain lowest-common-denominator effect. They also make use of some practices I would consider Not Very Good. I would not recommend them as an example for how to learn to write a large Javascript project.
    I'm not 100% sure what you mean by persistent session. Most of my
    scripts are run once and then quit. However, some do create a modeless
    dialog (ie where you can interface with the UI while running it), which
    is the only time I need to use #targetengine.
    Any script that specifies a #targetengine other than "main" is in a persistent session. It means that variables (and functions) will persist from script invokation to invokation. If you have two scripts that run in #targetengine session, for instance, because of their user interfaces, they can have conficting global variables. (Some people will suggest you should give each script its own #targetengine. I am not convinced this is a good idea, but my reasons against it are mostly speculation about performance and memory issues, which are things I will later tell you to not worry about.)
    But I think you've answered one of my questions when you say that the
    thing to avoid is the "v1" scope. Although I don't really see what the
    problem is in the context of InDesign scripting (unless someone else is
    going to using your script as function in one of theirs). Probably in
    Web design it's more of an issue, because a web page could be running
    several scripts at the same time?
    It's more of an issue in web browsers, certainly (which I have ~no experience writing complex Javascript for, by the way), but it matters in ID, too. See above. It also complicates code reuse across projects.
    Regarding functions altering variables: for example, I have a catalog
    script. myMasterPage is a variable that keeps track of which masterpage
    is being used. A function addPage() will add a page, but will need to
    update myMasterPage because many other functions in the script refer to
    that. However, addPage() also needs to update the total page count
    variable, the database-line-number-index-variable and several others,
    which are all used in most other functions. It seems laborious and
    unnecessary to pass them all to each function, then have the function
    alter them and return an array that would then need to be deciphered and
    applied back to the main variables. So in such a case I let the function
    alter these "global" (though not v1) variables. You're saying that's okay.
    Yes, that is OK. It's not a good idea to call that scope "global," though, since you'll promote confusion. You could call it...outer function scope, maybe? Not sure; that assumes addPage() is nested within some other function whose scope is containing myMasterPage.
    It is definitely true that you should not individually pass them to the function and return them as an array and reassign them to the outer function's variables.
    I think it is OK for addPage() to change them, yes.
    Another approach would be something like:
    (function() {
      var MPstate = {
        totalPages: 0,
        dbline: -1
      function addPage(state) {
        state.totalPages++;
        state.dbline=0;
        return state;
      MPstate = addPage(MPstate);
    I don't think this is a particularly good approach, though. It is clunky and also doesn't permit an easy way for addPage() to return success or failure.
    Of course it could instead do something like:
        return { success: true, state: state };
      var returnVal = addPage(MPstate);
      if (returnVal.success) { MPstate = returnVal.state; }
    but that's not very comforting either. Letting addPage() access it's parent functions variables works much much better, as you surmised.
    However, the down-side is that intuitively I feel this makes the script
    more "messy" -- less legible and professional. (On the other hand, I
    recall reading that passing a lot of variables to functions comes with a
    performance penalty.)
    I think that as long as you sufficiently clearly comment your code it is fine.
    Remember this sort of thing is part-and-parcel for a language that has classes and method functions inside those classes (e.g. Java, Python, ActionScript3, C++, etc.). It's totally reasonable for a class to define a bunch of variables that are scoped to that class and then implement a bunch of methods to modify those class variables. You should not sweat it.
    Passing lots of variables to functions does not incur any meaningful performance penalty at the level you should be worrying about. Premature optimization is almost always a bad idea. On the other hand, you should avoid doing so for a different reason -- it is hard to read and confusing to remember when the number of arguments to something is more than three or so. For instance, compare:
    addPage("iv", 3, "The rain in spain", 4, loremIpsumText);
    addPage({ name: "iv", insertAfter: 3, headingText: "The rain in spain",
      numberColumns: 4, bodyText: loremIpsumText});
    The latter is more verbose, but immensely more readable. And the order of parameters no longer matters.
    You should, in general, use Objects in this way when the number of parameters exceeds about three.
    I knew a function could return an array. I'll have to read up on it
    returing an object. (I mean, I guess I intuitively knew that too -- I'm
    sure I've had functions return textFrames or what-have-you),
    Remember that in Javascript, when we say Object we mean something like an associative array or dictionary in other languages. An arbitrary set of name/value pairs. This is confusing because it also means other kinds of objects, like DOM objects (textFrames, etc.), which are technically Javascript Objects too, because everything inherits from Object.prototype. But...that's not what I mean.
    So yes, read up on Objects. They are incredibly handy.

  • In a dynamic page how to share variable between PL/SQL and javascript

    For example, my dynamic page contains such PL/SQL codes:
    <ORACLE>
    DECLARE
    info varchar(100);
    rowid urowid;
    procedure doDelete(
    row_id in urowid
    ) IS
    begin
    Delete From xxx
    WHERE rowid = row_id;
    end doDelete;
    BEGIN
    Select name, rowid INTO info, rowid
    From xxx Where xxx;
    HTP.PRN(' <INPUT TYPE="button" VALUE="show value" onClick="alert(info);">');
    HTP.PRN(' <INPUT TYPE="button" VALUE="delete" onClick="doDelete(_row_id);">');
    END;
    </ORACLE>
    The variable 'info' and '_row_id' are correct, however the two HTP. sentence do not work. What's the problem?
    What I want to do is to show all the records in TABLE A in a page. And at the end of each line (record), there' re a 'delete' and a 'update' button to let user operate on this record. Is this possible? I know form can do delete an update, but it can not show all the records in a page like what report does. Besides dynamic page, is there any other better choice? Report can do it?
    One more question. In a report, I employed link on one field to a second report. It works well. But I want to open the second report in a new window when the link is click. Is this possible?
    I was almost driven crazy by these :( I so appreciate if anyone can help.

    The code written by you is insufficient for the funtionality you are trying to achieve. Below is a method to achieve the same.
    Note: Used standard scott.emp table for the example which is located in my db provider schema.
    Do the below modifications as per your local configuration
    xxxxx -> Replace it with your Portal schema
    yyyyy -> Replace it with your db provider schema
    <<module_id_of_form>> -> Replace with the module id of form created in step 1 & 2.
    First and foremost... oracle does not allows variables starting with '_'. So if you want to use it you have to place it in double quotes ("")
    rowid -> illegal
    "_row_id" -> legal.
    However, I will advice you not to use variable names starting with "_".
    Now lets get started...
    1. Create a form on the table you are using in the dynamic page. Just have the update button. Remove the other buttons.
    2. Get the module id of this form. Instruction for getting the module id:
    a) Right-click on the form's run link and copy the shortcut
    b) Get the value of p_moduleid parameter. This is your module id.
    3. Create a procedure "save_action_details" in your db provider schema. This procedure will accomplish the delete operation on the record.
         CREATE OR REPLACE Procedure save_action_details(
         p_rowid IN VARCHAR2,
         p_action IN VARCHAR2,
         p_dyn_ref_path IN VARCHAR2,
         p_dyn_page_url IN VARCHAR2)
         is
         l_sto_session xxxxx.wwsto_api_session;
         begin
         l_sto_session := xxxxx.wwsto_api_session.load_session(
         p_domain => 'DynStore',
         p_sub_domain => 'DynStore_' || p_dyn_ref_path
         l_sto_session.set_attribute(
         p_name => 'rowid',
         p_value => p_rowid
         l_sto_session.set_attribute(
         p_name => 'action',
         p_value => p_action
         l_sto_session.save_session;
         htp.init;
         owa_util.redirect_url(p_dyn_page_url);
         end save_action_details;
    Explaination: The above procedure creates a session and keeps the rowid and action in the session. This information is used by the below dynamic form to perform the necessary action. In our exampl, the action is always going to be delete so you may go ahead and hard code it, else leave it as it is.
    4. Grant execute privilege on the procedure "save_action_details" to public.
    sql> grant execute on save_action_details to public;
    5. Create your Dynamic page.
    a) In HTML code section have the below code. This code shows some columns from the table and "update" and "delete" buttons to perform the respective action.
         <ORACLE>select empno,ename,rowid,
         '<input type="button" value="Update" onClick="doAction(this.form,''UPD'',''xxx'','''
         || xxxxx.wwv_standard_util.url_encode(rowid) || '''); tWin();">
         <input type="button" value="delete" onclick="doAction(this.form,''DEL'',''' || rowid || ''',''xxx'');">' Action
         from yyyyy.emp</ORACLE>
    b) In additional pl/sql code section of dynamic page, have the below pl/sql block "in after displaying the header" section.
         declare
         l_sto_session xxxxx.wwsto_api_session;
         l_del_rowid varchar2(20);
         l_action varchar2(10);
         begin
         htp.comment('User code starts here ...');
         htp.p('<script>');
         htp.p('var winHandle;');
         htp.p('
         function doAction(formObj, action, rowid, erowid)
              if (action == "UPD")
              var formURL = "' || xxxxx.wwctx_api.get_proc_path('wwa_app_module.link?p_arg_names=_moduleid&p_arg_values=<<module_id_of_form>>&p_arg_names=_rowid&p_arg_values=') || '" + erowid;
              winHandle = window.open(formURL, "winDynUpd", "width=750,height=500,resizable=yes");
              else
              formObj.p_rowid.value = rowid;
              formObj.p_action.value = action;
              formObj.submit();
         function tWin() {
              if (winHandle.closed) {
              document.location = document.location;
              else {
              setTimeout("tWin()", 500);
         htp.p('</script>');
         htp.p('<form name="dynRowProcess" method="POST" action="'
         || xxxxx.wwctx_api.get_proc_path('save_action_details','yyyyy')
         || '">');
         htp.p('<input type="hidden" name="p_rowid">');
         htp.p('<input type="hidden" name="p_action">');
         htp.p('<input type="hidden" name="p_dyn_ref_path" value="' || p_reference_path || '">');
         htp.p('<input type="hidden" name="p_dyn_page_url" value="' || p_page_url || '">');
         l_sto_session := xxxxx.wwsto_api_session.load_session(
         p_domain => 'DynStore',
         p_sub_domain => 'DynStore_' || p_reference_path
         l_del_rowid := l_sto_session.get_attribute_as_varchar2('rowid');
         l_action := l_sto_session.get_attribute_as_varchar2('action');
         if l_action = 'DEL' then
         delete from yyyyy.emp
         where rowid = l_del_rowid;
         end if;
         end;
    Explaination: The session information (rowid and action) stored by "save_action_details" procedure is retrieved by the dynamic page and is used to delete the record.
    6. Once you are through with the above steps, test it by placing the above "dynamic page" portlet on a page.
    a) When you click on delete button the record gets deleted and the automatically refreshed page will not show the deleted record.
    b) On clicking update button, a form will appear. do the necessary modifications in data and click update. the data in the form gets updated. Once you close the form the dynamic page gets refreshed automatically and it will show you the updated information.

  • How to get the value of a variable defined in javascript in JSP

    how to get the value of a variable defined in javascript in/through JSP????

    In Javascript you can use the DOM to access the input element and set it's value before submitting the form. Then it's value will just be passed.

  • In OBIEE 11g, how can you set a presentation variable value from javascript ?

    I want to set up presentation variable from a javascript variable. Does anyone knows the workaround for this ?

    SriniVEERAVALLI,
    Thanks for your suggestions. I want to make a custom prompt that is only my requirement. From JS I have made a custom slider prompt now I want to use this slider prompt to pass selected value in presentation variable. Since, we have slider prompt only for numbers, I have to use it for other values.
    I just want to make my post looks simple and focus on the specific problem.
    Anyways, thanks a lot for taking time to reply. Appreciate your help.

  • Connect to R/3 failed. USERID and/or PASSWD could not be retrieved from SSFS

    Dear All,
    Solman installation 7.1 fails with Error in the Start instance phase.
    Database : Oracle
    OS: AIX 6100-07-02-1150
    Oracle version: 11.2.0.3
    Kernel version: 720 patch number is 114
    I have checked the SAP Note #1639578 - SSFS as password storage for primary database connect .
    The below values has alreadt been set in default profile and in environment variables also
    RSEC_SSFS_DATAPATH=/usr/sap/SMI/SYS/global/security/rsecssfs/data
    RSEC_SSFS_KEYPATH=/usr/sap/SMI/SYS/global/security/rsecssfs/key
    rsdb_ssfs_connect=1
    2. The Permission of the Global directory
    solmantrg:smiadm 13> ls -all
    total 0
    drwxr-xr-x    5 smiadm   sapsys          256 Apr 18 17:37 .
    drwxr-xr-x    5 smiadm   sapsys          256 Apr 19 21:51 ..
    drwxr-xr-x    3 smiadm   sapsys          256 Apr 18 17:37 exe
    drwxr-xr-x    3 smiadm   sapsys          256 Apr 18 17:37 gen
    lrwxrwxrwx    1 smiadm   sapsys           18 Apr 18 17:37 global -> /sapmnt/SMI/global
    Permission Of security Folder:
    solmantrg:smiadm 17> ls -all
    total 8
    drwx------    5 smiadm   sapsys          256 Apr 22 13:25 .
    drwxr-xr-x    5 smiadm   sapsys          256 Apr 18 17:37 ..
    -rw-r--r--    1 smiadm   sapsys            0 Apr 22 13:25 ABAPPROT
    drwxr-xr-x    8 smiadm   sapsys          256 Apr 18 17:39 SDT
    -rw-r--r--    1 smiadm   sapsys          272 Apr 18 17:37 ms_acl_info
    drwxr-xr-x    2 smiadm   sapsys          256 Apr 22 13:26 sapcontrol
    drwx------    5 smiadm   sapsys          256 Apr 18 17:37 security
    Permission Of rsecssfs:
    solmantrg:smiadm 20> ls -all
    total 0
    drwx------    5 smiadm   sapsys          256 Apr 18 17:37 .
    drwx------    5 smiadm   sapsys          256 Apr 22 13:25 ..
    drwx------    2 smiadm   sapsys          256 Apr 19 21:01 data
    drwx------    3 smiadm   sapsys          256 Apr 18 17:37 lib
    drwx------    4 smiadm   sapsys          256 Apr 18 17:37 rsecssfs
    permission Of data & Key
    solmantrg:smiadm 22> ls -all
    total 0
    drwx------    4 smiadm   sapsys          256 Apr 18 17:37 .
    drwx------    5 smiadm   sapsys          256 Apr 18 17:37 ..
    drwx------    2 smiadm   sapsys          256 Apr 22 12:42 data
    drwx------    2 smiadm   sapsys          256 Apr 18 17:37 key
    permission Of SSFS_SMI.DAT
    solmantrg:smiadm 24> pwd
    /sapmnt/SMI/global/security/rsecssfs/data
    solmantrg:smiadm 25> ls -all
    total 8
    drwx------    2 smiadm   sapsys          256 Apr 22 12:42 .
    drwx------    4 smiadm   sapsys          256 Apr 18 17:37 ..
    -rw-------    1 smiadm   sapsys          972 Apr 22 12:42 SSFS_SMI.DAT
    No key for File ( SSFS_SMI.KEY ) IN PATH ( /sapmnt/SMI/global/security/rsecssfs/key)  Exists
    solmantrg:smiadm 28> cd key
    solmantrg:smiadm 29> ls -altr
    total 0
    drwx------    4 smiadm   sapsys          256 Apr 18 17:37 ..
    drwx------    2 smiadm   sapsys          256 Apr 18 17:37 .
    3. From smiadm, R3trans -x shows 0000.  BUT from ora>sid>, R3trans -x shows 0012
    solmantrg:orasmi 2> R3trans -x
    This is R3trans version 6.22 (release 720 - 26.10.11 - 13:00:00).
    unicode enabled version
    2EETW169 no connect possible: "DBMS = ORACLE                           --- dbs_ora_tnsname = 'SMI'"
    R3trans finished (0012).
    4. Output Of Trans.log from Ora<SID> User
    solmantrg:orasmi 3> more trans.log
    4 ETW000 R3trans version 6.22 (release 720 - 26.10.11 - 13:00:00).
    4 ETW000 unicode enabled version
    4 ETW000 ===============================================
    4 ETW000
    4 ETW000 date&time   : 22.04.2014 - 14:41:32
    4 ETW000 control file: <no ctrlfile>
    4 ETW000 R3trans was called as follows: R3trans -x
    4 ETW000  trace at level 2 opened for a given file pointer
    4 ETW000  [     dev trc,00000]  Tue Apr 22 14:41:32 2014                                                 145  0.000145
    4 ETW000  [     dev trc,00000]  db_con_init called                                                        41  0.000186
    4 ETW000  [     dev trc,00000]  set_use_ext_con_info(): ssfs will be used to get connect information
    4 ETW000                                                                                                  91  0.000277
    4 ETW000  [     dev trc,00000]  determine_block_commit: no con_hdl found as blocked for con_name = R/3
    4 ETW000                                                                                                  84  0.000361
    4 ETW000  [     dev trc,00000]  create_con (con_name=R/3)                                                 40  0.000401
    4 ETW000  [     dev trc,00000]  Loading DB library '/usr/sap/SMI/SYS/exe/run/dboraslib.o' ...             74  0.000475
    4 ETW000  [     dev trc,00000]  DlLoadLib() success: dlopen("/usr/sap/SMI/SYS/exe/run/dboraslib.o"), hdl 0
    4 ETW000                                                                                               31906  0.032381
    4 ETW000  [     dev trc,00000]  Library '/usr/sap/SMI/SYS/exe/run/dboraslib.o' loaded                     49  0.032430
    4 ETW000  [     dev trc,00000]  function DbSlExpFuns loaded from library /usr/sap/SMI/SYS/exe/run/dboraslib.o
    4 ETW000                                                                                                  61  0.032491
    4 ETW000  [     dev trc,00000]  Version of '/usr/sap/SMI/SYS/exe/run/dboraslib.o' is "720.00", patchlevel (0.114)
    4 ETW000                                                                                                 493  0.032984
    4 ETW000  [     dev trc,00000]  function dsql_db_init loaded from library /usr/sap/SMI/SYS/exe/run/dboraslib.o
    4 ETW000                                                                                                  55  0.033039
    4 ETW000  [     dev trc,00000]  function dbdd_exp_funs loaded from library /usr/sap/SMI/SYS/exe/run/dboraslib.o
    4 ETW000                                                                                                 108  0.033147
    4 ETW000  [     dev trc,00000]  New connection 0 created                                                 264  0.033411
    4 ETW000  [     dev trc,00000]  0: name = R/3, con_id = -000000001, state = DISCONNECTED, tx = NO , bc = NO , hc = NO , perm = YES, reco = NO , frco = NO , timeout = 00
    0, con_max = 255, con_opt = 255, occ = NO , prog =
    4 ETW000                                                                                                  79  0.033490
    4 ETW000  [     dev trc,00000]  db_con_connect (con_name=R/3)                                             79  0.033569
    4 ETW000  [     dev trc,00000]  determine_block_commit: no con_hdl found as blocked for con_name = R/3
    4 ETW000                                                                                                  53  0.033622
    4 ETW000  [     dev trc,00000]  find_con_by_name found the following connection:                          35  0.033657
    4 ETW000  [     dev trc,00000]  0: name = R/3, con_id = 000000000, state = DISCONNECTED, tx = NO , bc = NO , hc = NO , perm = YES, reco = NO , frco = NO , timeout = 000
    , con_max = 255, con_opt = 255, occ = NO , prog =
    4 ETW000                                                                                                  74  0.033731
    4 ETW000  [     dev trc,00000]  read_con_info_ssfs(): reading connect info for connection R/3             36  0.033767
    4 ETW000  [     dev trc,00000]  read_con_info_ssfs(): DBSL supports extended connect protocol             49  0.033816
    4 ETW000                          ==> connect info for default DB will be read from ssfs
    4 ETW000  [     dev trc,00000]  read_con_info_ssfs(): register callback ssfs_dbi_trace and max level 2
    4 ETW000                                                                                                  88  0.033904
    4 ETW000  [     dev trc,00000]  function DbSlExpFuns loaded from library /usr/sap/SMI/SYS/exe/run/dboraslib.o
    4 ETW000                                                                                                  61  0.032491
    4 ETW000  [     dev trc,00000]  Version of '/usr/sap/SMI/SYS/exe/run/dboraslib.o' is "720.00", patchlevel (0.114)
    4 ETW000                                                                                                 493  0.032984
    4 ETW000  [     dev trc,00000]  function dsql_db_init loaded from library /usr/sap/SMI/SYS/exe/run/dboraslib.o
    4 ETW000                                                                                                  55  0.033039
    4 ETW000  [     dev trc,00000]  function dbdd_exp_funs loaded from library /usr/sap/SMI/SYS/exe/run/dboraslib.o
    4 ETW000                                                                                                 108  0.033147
    4 ETW000  [     dev trc,00000]  New connection 0 created                                                 264  0.033411
    4 ETW000  [     dev trc,00000]  0: name = R/3, con_id = -000000001, state = DISCONNECTED, tx = NO , bc = NO , hc = NO , perm = YES, reco = NO , frco = NO , timeout = 00
    0, con_max = 255, con_opt = 255, occ = NO , prog =
    4 ETW000                                                                                                  79  0.033490
    4 ETW000  [     dev trc,00000]  db_con_connect (con_name=R/3)                                             79  0.033569
    4 ETW000  [     dev trc,00000]  determine_block_commit: no con_hdl found as blocked for con_name = R/3
    4 ETW000                                                                                                  53  0.033622
    4 ETW000  [     dev trc,00000]  find_con_by_name found the following connection:                          35  0.033657
    4 ETW000  [     dev trc,00000]  0: name = R/3, con_id = 000000000, state = DISCONNECTED, tx = NO , bc = NO , hc = NO , perm = YES, reco = NO , frco = NO , timeout = 000
    , con_max = 255, con_opt = 255, occ = NO , prog =
    4 ETW000                                                                                                  74  0.033731
    4 ETW000  [     dev trc,00000]  read_con_info_ssfs(): reading connect info for connection R/3             36  0.033767
    4 ETW000  [     dev trc,00000]  read_con_info_ssfs(): DBSL supports extended connect protocol             49  0.033816
    4 ETW000                          ==> connect info for default DB will be read from ssfs
    4 ETW000  [     dev trc,00000]  read_con_info_ssfs(): register callback ssfs_dbi_trace and max level 2
    4 ETW000                                                                                                  88  0.033904
    4 ETW000  [     dev trc,00000]  RSecSSFs: Entering function "RSecSSFsGetRecord" [rsecssfs.c 836]          84  0.033988
    4 ETW000  [     dev trc,00000]  RSecSSFs: Configuration data read from environment parameters [rsecssfs.c 3664]
    4 ETW000                                                                                               11463  0.045451
    4 ETW000  [     dev trc,00000]  RSecSSFs: Data file "/usr/sap/SMI/SYS/global/security/rsecssfs/data/SSFS_SMI.DAT" cannot be opened for read [rsecssfs.c 2198]
    4 ETW000                                                                                                 174  0.045625
    4 ETW000  [     dev trc,00000]  RSecSSFs: Exiting function "RSecSSFsGetRecord" with return code 1 (message: Data file "/usr/sap/SMI/SYS/global/security/rsecssfs/data/SS
    FS_SMI.DAT" cannot be opened for read) [rsecssfs.c 897]
    4 ETW000                                                                                                  91  0.045716
    4 ETW000  [    dbcon.c ,00000]  *** ERROR => read_ssfs_record(): RSecSSFsGetRecord(DB_CONNECT/DEFAULT_DB_USER)=1 : Data file "/usr/sap/SMI/SYS/global/security/rsecssfs/
    data/SSFS_SMI.DAT" cannot be opened for read
    4 ETW000                                                                                                  82  0.045798
    4 ETW000  [     dev trc,00000]  read_con_info_ssfs(): deregister callback ssfs_dbi_trace                  37  0.045835
    4 ETW000  [    dbcon.c ,00000]  *** ERROR => Connect to R/3 failed. USERID and/or PASSWD could not be retrieved from SSFS
    4 ETW000                                                                                                  68  0.045903
    2EETW169 no connect possible: "DBMS = ORACLE                           --- dbs_ora_tnsname = 'SMI'"
    trans.log: END
    Kindly help us to fix the error ""ERROR => read_ssfs_record(): RSecSSFsGetRecord(DB_CONNECT/DEFAULT_DB_USER)=1 : Data file "/usr/sap/SMI/SYS/global/security/rsecssfs/
    data/SSFS_SMI.DAT" cannot be opened for read"
    Thanks and Regards,
    Gayathri.K

    Hi Deepak,
    Now my installation failed with "Start Java engine "phase as in the attached screenshot.
    scs00 instance is failing and i am unable to start it.
    ERROR      2014-04-22 18:28:50.499 [sixxcstepexecute.cpp:899]
    FCO-00011  The step startSCS with step key |NW_Onehost|ind|ind|ind|ind|0|0|NW_Onehost_System|ind|ind|ind|ind|onehost|0|NW_CI_Instance|ind|ind|ind|ind|ci|0|NW_CI_Instance_Configure_Java|ind|ind|ind|ind|javaconfig|0|startSCS was executed with status ERROR ( Last error reported by the step: Instance 'SCS00/solmantrg' of SAP system SMI is in an inconsistent state: the processes do not seem to have been started within the instance.).
    when i checked in getprocess list
    solmantrg:smiadm 56> sapcontrol -prot NI_HTTP -nr 00 -function GetProcessList
    22.04.2014 18:29:43
    GetProcessList
    OK
    name, description, dispstatus, textstatus, starttime, elapsedtime, pid
    msg_server, MessageServer, GRAY, Stopped, , , 13631618
    enserver, EnqueueServer, GRAY, Stopped, , , 11468864
    have attached the screenshot and sapinst.dev.log
    Please assist
    regards,
    gayathri.K

  • Dynamically creating variable names in javascript

    Hi.
    I have to create variable names dynamically in JavaScript.
    My JSP file accesses information from Database and forms a String corresponding to the information received.
    This String is passed to a JAvaScript function that should CREATE a variable with that NAME.
    For Ex:
    My database access resulted in a single row...
    id name sal
    34 John Smith 38000
    the resulting VARIABLE NAME should be Menu34. 34 comes from the database result.
    Is there any function to dynamically create a variable name in JavaScript?
    Thanks in advance.

    The JSP is printing the contents of an HTML page, and Javascript code can be part of that output...
    So you would just write out the stuff, something like this....
    <script>
    <% while(rs.hasNext()) { %>
    var Menu<%= rs.getInt("id") %> = '<%= rs.getString("name") %>';
    <% } %>
    </script>
    In the browser, it'll just look like another long list of Javascript variables.

  • HELP PLASE ! JavaBean and Javascript in frames :)

    Hello,
    First please excuse me for my bad english I'm French think you in advance for your patience and your help ! :)
    To resum the problem :
    I have 2 frames, a menu frame and a main frame
    I use a javabean wich is saved in application variable.
    When the pages of main frame use the javabean there is no probleme.
    BUT when menu frame calls pages of main frame it don't restore the javabean, it looks like je page called by menu frame, which operates on the javabean, wasn't called, and the changes I do in this page aren't saved
    Menu frame uses javascript to calls main frame pages so I think the problem is conjonction of frame and javascript.
    But I have no choice because it's volonty of my boss, so please help me ! :)
    More precisly :
    the javabean : NavigationBean
    page frame menu : menu_page.jsp
    main pages which use javabean : pageA.jsp, pageB.jsp, pageC.jsp
    pageA.jsp has reference on pageB.jsp which has reference on pageC.jsp
    Traitement of the javabean NavigationBean in pageA.jsp, pageB.jsp and pageC.jsp :
    <jsp:useBean      id="gestionNavigation"
              class= "NavigationBean"          
              scope="application">                         
    </jsp:useBean>
    <jsp:setProperty      name="gestionNavigation"
                   property="request"
                   value="<%=request%>" />     
    (it needs response and request to run)
    <jsp:setProperty      name="gestionNavigation"
                   property="response"
                   value="<%=response%>" />
    <jsp:setProperty      name="gestionNavigation"
                   property="pageActuelle"
                   value="<%=urlActuelle%>" />
    (it saves in NavigationBean object the url where user is)
    In pageA I clean all NavigationBean so all pages saved are deleted
    if user go DIRECTLY on pageA.jsp, all is ok :
    user go on
         pageA -> pageB -> pageC
    and NavigationBean save
         pageA -> pageB -> pageC
    That's good ! :)
    BUT if after user go on menu frame it's wrong !
    user go on
         pageA -> pageB -> pageC -> menu_page.jsp -> pageA -> pageB
    BUT NavigationBean save
         pageA -> pageB -> pageC -> pageB
    instead of
         pageA -> pageB
    To resume, for NavigationBean when user go directly on main pages there is no problem, but when it uses menu frame it doesn't save that user go on pageA
    I clean NavigationBean on pageA, but instead of this problem it doesn't clean and retrieve old datas
    It looks like that when user uses menu FRAME it uses an old NavigationBean object, but when it go directly on pages of main frame it runs !
    And I use scope application so don't understand, I have tried session scope but no change :(
    I have tried using "response.encondeURL" but no change
    Think you in advance for your help, and good luck from Paris for all New York people ! :)
    David

    It sounds like what might be happening is when the user goes 'back' to the menu, they're not requesting the page from the server. So, they're either getting the old page cached by the browser. Maybe. If you reload the menu page manually, does it work?

  • How to combine ABAP and javascript in BSP

    I have a variable "w_temp" in ABAP(defined in page attributes) and another variable "x" in javascript.
    I can assign value of w_temp to x as follows :-
    x = <% w_temp. %>
    but I want to do vice versa i.e. assign value of x to w_temp.
    How to do that ???????

    You can do this by using a javascript function. Like :
    <%
    fun(){
    return x;
    %>
    <%
    w_temp = fun();
    %>
    Regards,
    Animesh

  • Accessing JSP variables in Included Javascript

    Hey All,
    I want to hide my javascript to be viewed on the client browser.
    I know we can do that with the javascript include ,But i am using JSP variables in
    Included javascript.I can't access those variables any more.
    Does anybody know any workarround.
    Thanx
    Vijay

    Hi Vijay,
    I am also facing the same problem of hiding javascript in the client browser. My javascript variables are getting initialised on the fly using JSP. Since JSP is compiled on the server side, one can't compile .js file on the client side.
    What u can do is to divide your page into frames with
    <frameset rows="100%,0%">. Now put your form hidden fields or the .js file in frame 2 which is not visible to the user and then assign your jsp variables in the frame2 html/jsp page. Now access your variables from frame2 in frame1 using
    var i = parent.frames[1].document.forms[0].elements[0].value
    Assuming that there is 1 form and 1 hidden field in frame2 html/jsp page.
    I hope u get the logic rite....
    I had done it for application but problem is that our users are real MORONS and they keep doing ctrl+F5 which takes them to the Indexpage.
    If you get some other solution then please mail it to my email address
    [email protected]
    Regards
    Vimlesh

  • How to avoid prompting the userid and password in Drop Down Menu

    Hey Guys hope you can help me.
    I have created a page wherein within that page I have a drop down menu using a javascript here is the code (please see my code below): Now the problem is each time I click any of the selection below the useid and password prompt me.
    Is their any way that this can be fixed so that I cann pass the userid and password as a parameter? I have already tried to pass the &SESSION but it does not work.
    Please enlighten me on this one....
    Thanks,
    Henry
    <select name="P300_selected_alert" size="1" onChange="bringMeHere(this.options[selectedIndex].value)">
    <option value="" selected>-Select One-</option>-->
    <option value="All Alerts">All Alerts</option>
         <option value="Acknowledged">Acknowledged</option>
    <option value="Unacknowledge">Unacknowledge</option>
    <option value="Acknowledged-Resolved">Acknowledged-Resolved</option>
         <option value="Acknowledged-Unresolve">Acknowledged-Unresolve</option>
    <option value="Target Name">Target Name</option>
         </select></td>
    </td>
    <script language="JavaScript1.1" type="text/javascript">
    function bringMeHere(a)
    if (a == "Acknowledged")
    location.href="f?p=103:295:12375097291676676231:NO::";
    else
    location.href="f?p=103:300:12375097291676676231:NO::";
    </script>
    ---------------------------------------------------

    Henry,
    See the change I made to your reports region template on page 1, adding the session id to the links as was suggested earlier:
    var Session_Id = html_GetElement('pInstance').value;
    if (a == "Name")
    location.href="f?p=35225:3:"+Session_Id;
    else if (a == "Employee")
    location.href="f?p=35225:2:"+Session_Id;
    else
    location.href="f?p=35225:1:"+Session_Id;
    And again, you do not want to be hard-coding the application ID anywhere in your code.
    Scott

  • Cfform (flash) and javascript integration

    I've been searching and shooting in the dark for 2 days and
    can't get this to work...
    I need to have my flash form button execute a javascript,
    return the value to the form and then I need the form to submit and
    take advantage of cfform's validation.
    So far, I get the javascript to change the value of the form
    field without submitting the form, but when I add the submit line,
    the form submits before the javascript returns the changes.
    Here is my sample:
    <script language="JavaScript" type="text/javascript">
    function changeSomething(x,z1,z2)
    var z3 = "window.document."+z1+ ".SetVariable";
    if (x != "ABCDEFG")
    eval(z3+"(z2+'.text', 'INVALID Name')");
    </script>
    <cfsaveContent variable="prevalidateIt">
    getURL("javascript:changeSomethig('"+name.text+"','Step1','name')");
    submitForm();
    </cfsavecontent>
    <cfform method="post" name="Step1" preloader="no"
    format="flash" width="960">
    <cfformgroup type="panel" label="Step 1" visible="yes"
    enabled="yes">
    <cfformgroup type="hbox" visible="yes" enabled="yes">
    <cfformgroup type="hbox" width="200" visible="yes"
    enabled="yes">
    <cfinput type="text" name="name" size="12" maxlength="11"
    width="12" label="name" validateat="onSubmit" validate="maxlength"
    required="yes" />
    </cfformgroup>
    </cfformgroup>
    <cfformgroup type="hbox" visible="yes" enabled="yes">
    <cfformgroup type="hbox" visible="yes" enabled="yes">
    <cfinput type="button" name="Submit" value="Submit"
    onclick="#prevalidateIt#" />
    </cfformgroup>
    <cfformgroup type="hbox" visible="yes" enabled="yes">
    <cfinput name="Reset" type="reset" id="Reset"
    value="Reset" />
    </cfformgroup>
    </cfformgroup>
    </cfformgroup>
    </cfform>
    My javascript is of course way more complicated than this one
    and goes through several steps of validation of the form field. It
    will ultimately be used on multiple fields in the form.
    Has anybody else tried to do something similar.
    Thanks!

    I ran your code. It appears to work as expected. The only
    major change is that I corrected the typo
    javascript:changeSomethi
    ng.
    <script type="text/javascript">
    function changeSomething(x,z1,z2)
    var z3 = "window.document."+z1+ ".SetVariable";
    if (x != "ABCDEFG")
    eval(z3+"(z2+'.text', 'INVALID Name')");
    </script>
    <cfsaveContent variable="prevalidateIt">
    getURL("javascript:changeSomething('"+name.text+"','Step1','name')");
    submitForm();
    </cfsavecontent>
    <cfform method="post" action="#cgi.script_name#"
    name="Step1" preloader="no" format="flash" width="960">
    <cfformgroup type="panel" label="Step 1" visible="yes"
    enabled="yes">
    <cfformgroup type="hbox" visible="yes" enabled="yes">
    <cfformgroup type="hbox" width="200" visible="yes"
    enabled="yes">
    <cfinput type="text" name="name" size="12" maxlength="11"
    width="12" label="name" validateat="onSubmit" validate="maxlength"
    required="yes" />
    </cfformgroup>
    </cfformgroup>
    <cfformgroup type="hbox" visible="yes" enabled="yes">
    <cfformgroup type="hbox" visible="yes" enabled="yes">
    <cfinput type="button" name="Submit" value="Submit"
    onclick="#prevalidateIt#" />
    </cfformgroup>
    <cfformgroup type="hbox" visible="yes" enabled="yes">
    <cfinput name="Reset" type="reset" id="Reset"
    value="Reset" />
    </cfformgroup>
    </cfformgroup>
    </cfformgroup>
    </cfform>

  • Change Data Entry Template variable values using javascript

    Content ServerIs there a way to change the Data Entry Template's text/Integer variable values using javascript?

    I believe you're asking if you can change the value of a content item's property using Javascript (a content item is created from a data entry template, which defines the set of properties).
    Unfortunately there is not a way to permanently change it in the content item, since Javascript is executed client-side rather than on the server. However, if you're just interested in how the value is displayed in the published HTML, you could modify the presentation template to store the property value into a Javascript variable and then manipulate it to be displayed in whatever manner you wish.

  • Safely forward userID and password

    I am writing a servlet/JSP application where a user will see a logon screen once. After successfully entering userID and password, I will display a list of available web applications. User selects one, and I want to forward them on to that application's entry servlet with the userID and password. My question is how to do that 'safely'.
    1) Easy to do with a GET-type URL (where url = url?userid=value1&password=value2)using response.sendRedirect(url). However, I found after successful processing by the next application's entry servlet, the userid and password are still displayed in the address bar on the next screen. Is there any way within the receiving servlet to trim those off the displayed url?
    2) I tried using the POST, where I contact the next application, get the page back and display it. The problem is the next application adds session data in the entry servlet, and when I just get the page back and display it, the session data is lost. Here's an example of the code I used:
    String userInfo = �url?userid=value1&password=value2�;
    byte[] bytesUserInfo = userInfo.getBytes();
    HttpURLConnection urlConn = (HttpURLConnection)
    url.openConnection();
    urlConn.setDoInput(true);
    urlConn.setDoOutput(true);
    urlConn.setAllowUserInteraction(true);
    urlConn.setUseCaches(false);
    urlConn.setFollowRedirects(true);
    urlConn.setRequestProperty("Content-length",
    String.valueOf(bytesUserInfo.length));
    OutputStream out = urlConn.getOutputStream();
    urlConn.connect();
    out.write(bytesUserInfo);
    out.flush();
    out.close();
    String responsePage = "";
    String line = "";
    BufferedReader in = new BufferedReader(
    new InputStreamReader(urlConn.getInputStream()));
    while((line = in.readLine()) != null) {
    responsePage += line + "\n";
    response.setContentType("text/html");
    PrintWriter pw = response.getWriter();
    pw.println(responsePage);
    pw.flush();
    pw.close();
    So I would display the responsePage (the second screen of the next appliction, typically a menu). But the next application expects there to be session data attached, which it established in the entry servlet. The way I get the page and display it, the session info is lost.
    3) I also tried going to a 'invisible' page, then using META tag redirect, or JavaScript redirect, but then the userid and password got lost.
    Is there a good way to transparently forward a user and the id and password?

    Unfortunately cookies won't work here. The hidden
    sessionID might - that's a good suggestion. My
    question there is currently appB doensn't use
    sessionID's. It just uses
    HttpSession theSession = request.getSession(false);This only tells you to not create one if it doesnt exist. But if it exists, and as you are using one, it will use it. On the server there will be a sesssion which can be found by its sessionID, so you are using a sessionID. If a browser doesnt support cookies, a sessionID will be appended to the url, thats your sessionID to find your session in the session object. See request.getRequestedSessionID()
    >
    I might be missing something easy here, but if it
    knows the sessionID is hidden, how can it convert that
    to a HttpSession? Will it need some new collection
    now to relate the sessionID's to the sessions? I was
    looking the the API for an easy way to relate the
    sessionID to the actual session, but nothing jumped
    out at me.

  • Image upload from HTML5 and Javascript

    I have been struggling with this since a week. 
    No tutorial on the web was able to help me.
    Here is what i am trying to do. I am trying to upload an image via HTML5 . I am confused on how i should send the image as. Should i send it directly the response from HTML5 File reader API or i should convert it to a blob and send it? I am able to upload
    text data. But when i upload image data. They won't turn up .

    You should send the data you read from File API. So in your code above, you should send the data in "requestData" variable. I wrote a blog post some time ago about uploading large files using HTML 5, jQuery and Shared Access Signature which you
    may find useful:
    http://gauravmantri.com/2013/02/16/uploading-large-files-in-windows-azure-blob-storage-using-shared-access-signature-html-and-javascript/
    Relevant code from that blog post:
    var reader = new FileReader();
    reader.onloadend = function (evt) {
    if (evt.target.readyState == FileReader.DONE) { // DONE == 2
    var uri = submitUri + '&comp=block&blockid=' + blockIds[blockIds.length - 1];
    var requestData = new Uint8Array(evt.target.result);
    $.ajax({
    url: uri,
    type: "PUT",
    data: requestData,
    processData: false,
    beforeSend: function(xhr) {
    xhr.setRequestHeader('x-ms-blob-type', 'BlockBlob');
    xhr.setRequestHeader('Content-Length', requestData.length);
    success: function (data, status) {
    console.log(data);
    console.log(status);
    bytesUploaded += requestData.length;
    var percentComplete = ((parseFloat(bytesUploaded) / parseFloat(selectedFile.size)) * 100).toFixed(2);
    $("#fileUploadProgress").text(percentComplete + " %");
    uploadFileInBlocks();
    error: function(xhr, desc, err) {
    console.log(desc);
    console.log(err);
    Hope this helps.

Maybe you are looking for

  • Linux ignores mms.cfg

    Creating a /etc/adobe/mms.cfg does not appear to work in several versions of Linux that I have tested with several versions of flash 10. Of course, I would not need this if the camera and microphone security dialog issues was fixed. Any help would be

  • Conversion error occured

    conversion error occured while using h:selectmanyListbox tag.

  • Missing photos/previews following system crash

    Following a system freeze-up (happened while browsing with Safari) with Aperture 3.5.1 open and a forced shut-down, my Aperture library got messed up. Aperture suggested to rebuild the database and I did. After two or three rebuilds (all by Aperture'

  • Application unable to connect to databse after some time

    The problem we are facing is that after some time the application seems to be unable to connect to the database. The only way we have been able to clear the issue is by re starting the application servers. Below is the information I see in my logs an

  • How to delete a Price Condition?

    Hi all, I need to delete a price condition. How should I proceed? Thanks in advance, Regards,