Javascript popups don't work using global variables?
I have a "References" menu region that contains links to several pop-up pages showing valid data entry codes filtered for the user's location. I tried to make this work from another page by changing the references from page variables to global/application variables, but this doesn't work. Can anyone suggest a workaround? Here's the code I'm using:
URL target in link
javascript:callEmpPopup('P1050_ORG_ID')Javascript
function callMyPopup (formItem1,formRow1) {
var formVal1 = document.getElementById(formItem1).value;
var formVal2 = 1;
var url;
url = 'f?p=&APP_ID.:1056:&APP_SESSION.::::P1056_FACTORY_ID,P1056_ROW:' + formVal1 + ',' + formVal2;
w = open(url,"winLov","Scrollbars=1,resizable=1,width=1000,height=600");
if (w.opener == null)
w.opener = self;
w.focus();
}
Javascript can reference and manipulate only those elements that are part of the HTML page (DOM elements). Application items are not part of the HTML that constitutes an APEX page and as a consequence cannot be accessed using Javascript.
Varad
Similar Messages
-
Using Global variable in Record Group
Hi,
I have a requirement where in I need to pull a column name from a table and then use that value in the select statement of a record group. I have tried using global variables but it is not working. Here is the record group I would like to use.
RG_DOMAIN is based on LOV_DOMAIN
SELECT :GLOBAL.DOMAIN_COLUMN_NAME, DESCRIPTION FROM
DM_T_DOMAIN_VALUES
WHERE DOMAIN_NAME := BLOCK.ATTRIBUTE;
In the Key-Listval I have a select statement in which does this :
SELECT DOMAIN_COLUMN
INTO :GLOBAL.DOMAIN_COLUMN_NAME
FROM DM_T_DOMAIN_RULES WHERE DOMAIN_NAME = :BLOCK.ATTRIBUTE;
SHOW_LOV('LOV_DOMAIN');
The problem is I am not getting the value I am just getting the Domain_column name. For example for Domain_name 'CALC_TYP' the Domain_column is COLUMN_10 and I just see COLUMN_10 my LOV when I want to see the value of COLUMN_10 from the DM_T_DOMAIN_VALUES table.
I tried using Name_in and Copy but not working. Can anyone suggest a solution?
ThanksFrancois ,
I tried this but I am getting error saying record group does not exist. Can you tell me what should I go in Populate_group... and show_lov..maybe I am doing something wrong?
Declare
LC$Req Varchar2(512) ;
Begin
LC$Req := 'SELECT ' || :GLOBAL.DOMAIN_COLUMN_NAME || ' FROM ....' ;
Create_Group_From_Query( rg_group, LC$Req ) ;
Populate_group(RG_DOMAIN); ?? --- is this correct?
Show_Lov(LOV_DOMAIN) ; -- and is this correct?
End; -
Using Global Variables in Data Quality Address Cleanse Transforms
I am currently developing in Data Services 12.2.
I am trying to dynamically populate the List Owner information in the option tabs of the USA Regulatory Address Cleanse by using global variables. It populates the 3553 with the variable name instead of the value assigned.
According to the Technical Manual, it is possible to use global variables in Data Quality Address Cleanse transforms:
However, you can use substitution parameters in all places where global variables are supported, for example:
Query transform WHERE clauses
Mappings
SQL transform SQL statement identifiers
Flat-file options
User-defined transforms
Address cleanse transform options
Matching thresholds
Does anyone know if it is possible to use global variables in the option tab of the Address Cleanse; if so, can you describe how it is done?
Thanks in advance,
RickHi,
U can refer to the following links in help.sap.com
GlobalContainer Object
http://help.sap.com/saphelp_nw04/helpdata/en/75/8e0f8f3b0c2e4ea5f8d8f9faa9461a/content.htm
Container Object
http://help.sap.com/saphelp_nw04/helpdata/en/78/b4ea10263c404599ec6edabf59aa6c/content.htm
Also some of the RUN TIME CONSTANTS are available in your BPM. So if you are trying to retrieve those variables in your Mapping(that is used in BPM), also read the following thread.
Re: Message id in BPM
Cheers,
Siva Maranani. -
Can i use global variable in web forms
guys can any one tell me if i can use global variables when i am
deplying the forms on the web,.....
thank you
vas
nullGlobal variables work in their perfection even when you deploy
your forms on the WEB.
null -
Hello
I made a Global Variable XX_DATE in Transaction Form Personalization with a value =:TACC_ACC_ASSGN.GL_POSTED_DATE.
I'm planning to get the value from XX_DATE to one of the fields in Receipts thru Receipt Personalization.
But a got the following error when I validate the value in Actions
FRM-40815: Variable GLOBAL.XX_DATE does not exist.
The String =:GLOBAL.XX_DATE could not be evaluated because of an errorAny help on this please?
I just wanted to transfer data (GL_POSTED_DATE) from Transactions to Receipts using Global Variable.
Any other ideas?
Thanks a lot
emgeeeIn WHEN_NEW_FORM_INSTANCE set the property INITIAL_VALUE for the global variable.
-
Javascript debugger don't work
I love the webdevelopment tool in firefox, but my javascript debugger don't work :(
I only can pause / unpause javascript but all other buttons have no function.
Must I activate something in about:config or is my computer too old? (The tilt function is not supported by my graphic card)
Thanks for answers.fifo85 wrote:
> Hi,
>
> I have just tried the following code putting the script
header to execute it
> on the client side:
> <script>
> if(ParentValue == String("Y"))
> {
> EnableSubGroup();
> }
> else
> {
> DisableSubGroup();
> }
> </script>
onload=function(){
document.forms["SubForm"].elements["SubGroupDD"].disabled =
!(ParentValue == "Y")
This will disable SubGroup if "ParentValue" is not "Y"
Mick
>
> I do not get the object expected error anymore
> but the functions don't work, why is this?
>
> ----Function definition ------
> <script type="text/javascript">
> function EnableSubGroup()
> {
>
document.forms["SubForm"].elements["SubGroupDD"].disabled='false';
> }
> function DisableSubGroup()
> {
>
document.forms["SubForm"].elements["SubGroupDD"].disabled='true';
> }
> </script>
>
> Thanks
>
> Fifi
> -
Use global Variable for Formatstring
Hello
I wanna use a global variable for a format string. see picture. But I don't work.
Can anybody give me an idea, why it won't work?
Thanks a lot!!!
Attachments:
GlobalVariable.jpg 61 KBAs others said, the problem is not the global.
See attached a picture of how to do what you want. Since the Format String is unknown at edit time, you must provide the types to all inputs that are not DBL.
From your example, the while loop has been coded exactly like a for loop. It can be replaced with a for loop with auto-indexing, unless you really want the local variable to be update at each iteration every 50 ms. This delay is not necessary unless the computed array is huge and you want to leave some CPU time to other code in your application. Even then you can enter a delay of 0ms to force to swap to other tasks.
I don't know what your INT>BOOL VI does but using Scan from String you can read a number directly into a boolean. The number i
s rounded to an unsigned integer and 0 is False and >0 is True.
For example you scan a string for a boolean with format string %d.
"0" --> False
"24" --> True
"-18" -- False (coerced to unsigned = 0)
You scan a string for a boolean with format string %f:
Negative number up to "0.5" --> False (coerced and rounded to 0)
Number greater that 0.5 --> True
LabVIEW, C'est LabVIEW
Attachments:
diag.jpg 15 KB -
Javascript popup link not working
I've searched everywhere so trying to post here to see if anyone has encountered this. I have a javascript popup link in a PDF. Using Reader 9 and IE8. When I click the link it asks me if I want to allow or not. When I say allow, I then get an IE error that reads:
Internet Explorer cannot download file .
Unspecified Error
I've noticed that if I already have IE running, then the link works. But if I don't have an IE window open I get the error. The link looks like this:
javascript:void(window.open('http://servername/appname/apppage.aspx?id=2','_blank','width=700,height=500,tool bar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0'))
This link has to be a javascript window.open based on how it is generated. The PDF is generated by SQL reporting services and the online version of the report needs to launch a new window for this application - the PDF is created directly from the online version of the report.Please repost in the Acrobat Scripting forum.
-
What are the best practices to use GLOBAL Variables
Hi,
Please guide how Global Variables can be declared and how they can be initialized.
Further please guide what are the impacts of Global Variables(if any) on the memory of CLIENT or SERVER, if they are not initialized or freed up after usage.
Thanks.
Regards.spilgrim wrote:
My preference is not to use them and to use parameters or package variables. There is not real control on globals so you can end up with an applicatios that has lots of them that are only used once but persist for the user session.I second that. I don't know how often I searched for bugs caused by typos in the names of global variables. Plus the fact that they are only of datatype VARCHAR2. If you are using share_library_data you could also use Package globals in a forms library to share data between called and calling forms. Or you could use a database package...
cheers -
Using Global variables in business rules
In EAS after expanding the Business Rules section there is a Global Variables section. I have created some global variables in this section and I am trying to use them in the Rule editor and not having much luck. Are they retrieved differently to local variables...Currently this is how I am calling them within a FIX....
FIX([Global_Varaiable])
calculation;
EndFix
Please correct me if I am wrong, also can any one provide some good documentation and some gd links for writing business rules. I'm just starting out to create some business rule which runs on save on some input forms I am creating and finding it rather difficult.... :-(..
Many Thanks
StephenHi,
Global variables will work in the same way as local variables so you are using them correctly.
Business rules are just really glorified calc scripts, if you want to know about calc script commands have a read of the tech ref :- http://download.oracle.com/docs/cd/E12825_01/epm.111/esb_techref/frameset.htm?launch.htm
It will have all the calculation commands and functions and descriptions on how they work.
Cheers
John
http://john-goodwin.blogspot.com/ -
XI 3.0: Using global variables in mapping
Hi everybody
Since it seems that during mapping you have only access to messages fields, does anybody has got idea or a workaround to use global/external variables or constants during mapping??
Example: i would like to store the mail address where i send my error mails outside each mapping program (something like using a properties file or something like that).
Any idea???Hi,
U can refer to the following links in help.sap.com
GlobalContainer Object
http://help.sap.com/saphelp_nw04/helpdata/en/75/8e0f8f3b0c2e4ea5f8d8f9faa9461a/content.htm
Container Object
http://help.sap.com/saphelp_nw04/helpdata/en/78/b4ea10263c404599ec6edabf59aa6c/content.htm
Also some of the RUN TIME CONSTANTS are available in your BPM. So if you are trying to retrieve those variables in your Mapping(that is used in BPM), also read the following thread.
Re: Message id in BPM
Cheers,
Siva Maranani. -
Using global variable in package
Hi. I have created a function (Retrieve_SerialNo) which returns a variable, which I use throughout my package. I would like to assign this variable as a global variable to be used by all functions and procedures in the package. Can someone help me in the declaration of this variable as a global variable? Also, is it necessary for me to initialize this variable whenever the package executes. If yes, how would I do this?
CREATE OR REPLACE PACKAGE BODY Supply_Item_Interface AS
FUNCTION Retrieve_SerialNo RETURN VARCHAR2 IS
v_serial_no VARCHAR2(20);
CURSOR Serial_Code IS
SELECT S.Serial_Code
FROM Spare_Parts s, Orders r
WHERE s.serial_code = r.serial_code;
BEGIN
OPEN Serial_Code;
LOOP
FETCH Serial_Code
INTO v_serial_no;
EXIT WHEN Serial_Code%NOTFOUND;
v_serial_no := v_serial_no;
END LOOP;
CLOSE Serial_Code;
RETURN v_serial_no;
EXCEPTION
WHEN OTHERS THEN
RETURN NULL;
END;user13415143 wrote:
Hi. I have created a function (Retrieve_SerialNo) which returns a variable, which I use throughout my package. I would like to assign this variable as a global variable to be used by all functions and procedures in the package.All variables have scope or "visibility". A variable defined in a procedure is only visible within that procedure.
A variable defines in a package body. is visible within that package body (i.e. procedures and functions in that package body can "see" that variable.
A variable defined in the package definition? Well, who can see the definitions of procedures and function in a a package header/definition? Everyone else basically (other PL/SQL packages and procedures and functions). So this is also true for variables defined in the package interface. These are global variables that not only can be used by the code in that package's body, but also can be used by other packages and PL/SQL code.
So when you create a global variable you need to decide on its scope:
- define it in package header for global usage in all PL/SQL code
- define it in package body for global usage within that package only
CREATE OR REPLACE PACKAGE BODY Supply_Item_Interface AS
..snipped..Ugly code as there is no need to use an explicit cursor if returning a value from a single row. Also buggy code. If there are multiple rows returned by the cursor, the function returns the serial of the last random row. How does this make sense?
This is what I would expect to see from a function like this. You pass it a unique identifier and it returns the applicable attribute (column) value for it.
E.g.
create or replace function GetSerialNo( orderNo number ) return number is
serialNo number;
begin
select
s.serial_code into serialNo
from spare_parts s,
orders o
where s.serial_code = o.serial_code
and o.order_no = orderNo;
return( serialNo );
exception when NO_DATA_FOUND then
return( null )
end;Also note that there is no need to write ugly uppercase code. This is not a proper coding standard. Programming standards for all languages (ranging from C# to Java to Delphi to Visual Basic to C/C++) specify that camelcase should be used for variables and pascalcase for procedures/functions/methods. Uppercase is very seldom used and then only for constant names and compiler options/flags for example.
Coding reserved words in uppercase? That is just plain silly - and not found in today's programming languages. Do yourself a favour and forget the idiotic standards used by some for PL/SQL and look at the standards for Java and .Net/C# - as the latter are the de facto standards for programming (and have been for the last 2 decades and more). -
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. AroraHi 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 -
Select tables filed name by using global variables
Hi
I try to redesign a BODI jobs for monthly statistics. At the moment, I have a job for every month because in the source system (MS Axapta) the source table have the following design:
YEAR JAN FEB MARCH ...
2010 100 231 233
So, if I load the data for the January, I will load only this filed from the table:
select YEAR, JAN from STATISTICS
For the February, I will load only this filed:
select YEAR, FEB from STATISTICS
otherwise, I have a lot of dublicated BODI Jobs and a lot of work for maintenance.
In this case, I try to use a variable in the mapping field in a Query transform, but doesn't working. Also in the SQL transform, but I was not able to do that.
I know, that I can solve that with a Pivot-Transform, but I have to load some millions of data and I have no time to wait until the Pivot is finish.
Do anybody have a other idee to solve my problem?
Many thanks
ChristophThanks for your answer.
How can I do that in the SQL Transform?
If I try the with the following SQL Code, I become a ORA-00911 Error Message:
SELECT Year, $Periode from STATISTIK
Any idea
Thanks
Christoph -
Is there a way to use Global variable in HANA
Hi Developers,
Is there anything like a Global variable in SAP HANA which can be used to pass data from one procedure to another (Visible to all the procedures in a session)?
Thanks
S.SrivatsanHi Sundar,
In best of my understanding, there is no context variable or global variable available under SQL SCRIPT scope . You may need to maintain the variable as a parameter in the procedure interface and pass it to the procedures where ever you need it to be available . Or,(DB table is in memory, so its just memory unit) you can create a DB table to store the variable(s) and access it anywhere .
Sreehari
Maybe you are looking for
-
Hi Can i adjust advance payment to vendors in MIRO. Pls suggest Best regards, Arahanth
-
Change Browser window dynamically
Hi, I want to change the Browser 's height with a Button click from my swf file. Can I do this? Thank you, Luciewong
-
Command line printing - AdobeReader left open
Hello everyone, I've a problem by printing pdfs using the command line. My VB-script contains a code line like following (including the quotation marks for document and printer): process=myShell.Exec("c:\Program Files\Adobe\Reader\Reader 8.0\AcroRd32
-
Export gallery - enhancements from customer view
Hello I'm coming from the customer side here. Many of the photographers I've been working with the past years are using Lightroom to export images in a webgallery, a flash one, where I am supposed to select which ones I want for my article. Now, this
-
Guide: BIOS-Downgrade from 5FCN95WW to 5FCN35WW
hi! I've just upgraded to Windows 10. would it be safe to downgrade to 5FCN35WW? I've got the file from the time when I was using Windows 7.