How to get the VARIANT name in the program
Hi Guys,
Can somebody tell me how to get the VARIANT name in a program.
I have to perform some code with specific variant only. So I want to check in program which variant has been used to call the program.
Thanks,
Hi,
Variants are stored in table VARI and VARID.
You can use RS_ALL_VARIANTS_4_1_REPORT to get all the variants for a report program.
please check out the link below it will be helpful to you
Re: Programs for a transaction variant
Hope this helps.
ashish
Similar Messages
-
How to get the program where the User exit is use
Hi,
Could anyone let me know how to get the program which is using the user exit
EXIT_SAPLFMR4_002 .
Thank you.
Donny~You can do a where used on the functino module EXIT_SAPLFMR4_002 in SE37.
In this case, you user exit is called from a function module FMRE_FI_BELEG_CHECK. Which in my system, doesn't appear to be called directly. It could be called dynamically.
Regards,
RichHeilman -
How to get the program name from transformation id.
Dear Folks,
Could you kindly share to me how to make it please .. ? :-).
As we know that every update rules/transfer rules has it's own program.
Do you know how to find the program for particular update/transfer rules .. ? If i'm not mistaken there is particular comprising about this information.
Could you share to me what table is that and how to find it .. ?
Tks a lot ..
Regards,
Niel.Hi Sumit,
Tks a lot for your quick response, why i can't fetch the data from that table... ?
What i did is like this ..
1. tcode rsa1.
2. expand the tree for info-provider.
3. ctrl+c, in tech. names for update rules.
4. Open rstran table, and input for that tech. id.
5. Execute it.
But no data i get.
Does this happen only for business content ? Or Could I fetch the data even this is for customized object ..
Still need your guidance.
Btw, i'm now running BI 7
Regards,
Niel. -
How to get the programs (elements and premiere)from my old computer on my new PC?
Can I get the programs from my old computer and use tham on my new (windows 8.1) computer?
what do I do?I just did this so I hope I can remember. I have a MAC so I went into my MAC hard drive and then library > application support > adobe > photoshop elements > 10 > creations > effects. I selected all of my files and copied them. I then went back to photoshop elements > 12 > creations and pasted the files into effects. I then restarted PSE and all of my files were there!
-
How to get the Program Access Details
hi,
I want to get the last run details of all the program
I would like to give the date as a selection parameter.
It should give tha program names which are all acessed on that date.
where the details like when the program is run at last will be saved.
Is there any file/standard tables contain such details?
Thanks,
Mythili>
Mythili Sakthivel wrote:
> HI Gautham,
>
> I got the posts only abt last run of a program.
That is what you asked in your first post.
if you forgot just find below line from your post:
I want to get the last run details of all the program -
How to get main class name in running program?
How can I get classname, which main method is executed? Of course in running program?
Please help,
ChrisSomething like (not tested this)StackTraceElement[] foo = new Throwable().getStackTrace();
String whichClass = foo[foo.length-1].getClassName(); -
How to get the variants for LAV LIST or GRID?
Hi,
How to get the variants which are stored in table like JVSO1, using function module REUSE_ALV_VARIANT_F4 ?
Thanks.Hi,
Delcare
DATA : st_variant TYPE disvariant, "Work area for variant
st_variant1 TYPE disvariant. "Work area for variant
SELECTION-SCREEN BEGIN OF BLOCK b3 WITH FRAME TITLE text-041.
PARAMETERS : p_varnt TYPE disvariant-variant MODIF ID md8. "Variant
SELECTION-SCREEN END OF BLOCK b3.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_varnt.
*--Local Variables
DATA: l_exit(1) TYPE c. "ALV exit
*--Call the function module to display the list of Variants
CALL FUNCTION 'REUSE_ALV_VARIANT_F4'
EXPORTING
is_variant = st_variant
i_save = c_save
IMPORTING
e_exit = l_exit
es_variant = st_variant1
EXCEPTIONS
not_found = 1
program_error = 2.
*--Check Subrc
IF sy-subrc <> 2 AND l_exit IS INITIAL.
p_varnt = st_variant1-variant.
ENDIF.
start-of-selection.
IF NOT p_varnt IS INITIAL.
CLEAR st_variant1.
MOVE st_variant TO st_variant1.
MOVE p_varnt TO st_variant1-variant.
*--Call the function module to check the variant exist
CALL FUNCTION 'REUSE_ALV_VARIANT_EXISTENCE'
EXPORTING
i_save = c_save
CHANGING
cs_variant = st_variant1.
st_variant = st_variant1.
ENDIF.
DATA : lv_repid TYPE sy-repid.
*--Pass the Report name
lv_repid = sy-repid.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
i_callback_program = lv_repid
it_fieldcat = it_fcat
is_variant = st_variant
it_events = it_events
i_save = 'A'
i_callback_user_command = 'USER_COMMAND'
TABLES
t_outtab = it_zsd_ra
EXCEPTIONS
program_error = 1
OTHERS = 2.
IF sy-subrc <> 0.
MESSAGE e368(00) WITH 'Alv Display failed'(044) .
ENDIF.
regards,
Prashant -
How to get the Text name to pass in the parameter header in save_text
Hi,
I am trying to change the long text of operation for historical order by using the flat file.I am using the save_text to do this.I would like to know how to get the text name in order to pass the parameter header in save_text.
I went to the tcode iw62 to get the header information of the long text.300100000009200000001
i would like to know what this 1000000092 indicates and where is this value updated in the table so that i can link it thru the order no to get the link and pass it in the text_name.
can anyone help me out?
krishnanHi,
Your query is.
I went to the tcode iw62 to get the header information of the long text.300100000009200000001
i would like to know what this 1000000092 indicates
In above number
300 - Client
1000000092 - AUFPL - Routing number of operations in the order (You can fetch this from table HIVG)
00000001 - APLZL - General counter for order ( You can fetch this from table HIVG).
BR,
Vijay -
Dear Expert,
I have one requirement like to read the selected workset name in portal by the current user.I have read two documents regarding how to retrieve the PCD contents (iViews, Pages, Worksets and Roles) and its properties like Created by, Changed by, Last changed by and others using PCD API.
http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/6112ecb7-0a01-0010-ef90-941c70c9e401?overridelayout=true
http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/508baf88-9335-2d10-efa6-c6ad61e5fc4b?quicklink=index&overridelayout=true
But I am not able to understand how to get the specific name of the workset which is currently selected by the user.Can you please help me.
I am using portal 7.0.
Thanks & Regards,
PatralekhaHi Expert,
I found that we can use Interface INavigationHelperService to read Portal Role selected by user at runtime from http://scn.sap.com/thread/52194
But this class is available in SAP NetWeaver 7.30 Enterprise Portal .
But in SAP NetWeaver 7.0 Enterprise Portal that interface is not available.
INavigationService is available there.
But didn't get any proper discussion on this interface for the same requirement.
Can you please help me.
Thanks & Regards,
Patralekha -
How to get the current transaction variant ?
dear guru,
could you please tell me how to get the current transaction variant?
i tried the following method:
DATA l_tcvariant TYPE tcvariant.
CALL 'DY_GET_TX_VARIANT'
ID 'VARIANT' FIELD l_tcvariant.
but it failed.
best regards.
zjTry something like this
DATA: VARIANT LIKE SHDTVCIU-TCVARIANT.
CLEAR VARIANT.
CALL FUNCTION 'RS_HDSYS_GET_TC_VARIANT'
IMPORTING
TCVARIANT = VARIANT
* FLAG_CLIENT_INDEPENDENT =
* RC =
* TABLES
* T_SCREEN_VARIANTS =
* T_INACTIVE_FUNCTIONS = -
How to get the current schema name
Hi,
Can anybody please tell me how to get the current schema name, there is some inbuilt function for this,but i am not getting that. Please help me.
Thanks
Jogeshok folks, I found the answer at Tom's as usual.
http://asktom.oracle.com/tkyte/who_called_me/index.html
I rewrote it into a function for kicks. just pass the results of DBMS_UTILITY.FORMAT_CALL_STACK to this function and you will get back the owner of the code making the call as well some extra goodies like the name of the code and the type of code depending on the parameter. This ignores the AUTHID CURRENT_USER issues which muddles the schemaid. Quick question, does the average user always have access to DBMS_UTILITY.FORMAT_CALL_STACK or does this get locked down on some systems?
cheers,
paul
create or replace
FUNCTION SELF_EXAM (
p_call_stack VARCHAR2,
p_type VARCHAR2 DEFAULT 'SCHEMA'
) RETURN VARCHAR2
AS
str_stack VARCHAR2(4000);
int_n PLS_INTEGER;
str_line VARCHAR2(255);
found_stack BOOLEAN DEFAULT FALSE;
int_cnt PLS_INTEGER := 0;
str_caller VARCHAR2(30);
str_name VARCHAR2(30);
str_owner VARCHAR2(30);
str_type VARCHAR2(30);
BEGIN
str_stack := p_call_stack;
-- Loop through each line of the call stack
LOOP
int_n := INSTR( str_stack, chr(10) );
EXIT WHEN int_cnt = 3 OR int_n IS NULL OR int_n = 0;
-- get the line
str_line := SUBSTR( str_stack, 1, int_n - 1 );
-- remove the line from the stack str
str_stack := substr( str_stack, int_n + 1 );
IF NOT found_stack
THEN
IF str_line like '%handle%number%name%'
THEN
found_stack := TRUE;
END IF;
ELSE
int_cnt := int_cnt + 1;
-- cnt = 1 is ME
-- cnt = 2 is MY Caller
-- cnt = 3 is Their Caller
IF int_cnt = 1
THEN
str_line := SUBSTR( str_line, 22 );
dbms_output.put_line('->' || str_line);
IF str_line LIKE 'pr%'
THEN
int_n := LENGTH('procedure ');
ELSIF str_line LIKE 'fun%'
THEN
int_n := LENGTH('function ');
ELSIF str_line LIKE 'package body%'
THEN
int_n := LENGTH('package body ');
ELSIF str_line LIKE 'pack%'
THEN
int_n := LENGTH('package ');
ELSIF str_line LIKE 'anonymous%'
THEN
int_n := LENGTH('anonymous block ');
ELSE
int_n := null;
END IF;
IF int_n IS NOT NULL
THEN
str_type := LTRIM(RTRIM(UPPER(SUBSTR( str_line, 1, int_n - 1 ))));
ELSE
str_type := 'TRIGGER';
END IF;
str_line := SUBSTR( str_line, NVL(int_n,1) );
int_n := INSTR( str_line, '.' );
str_owner := LTRIM(RTRIM(SUBSTR( str_line, 1, int_n - 1 )));
str_name := LTRIM(RTRIM(SUBSTR( str_line, int_n + 1 )));
END IF;
END IF;
END LOOP;
IF UPPER(p_type) = 'NAME'
THEN
RETURN str_name;
ELSIF UPPER(p_type) = 'SCHEMA.NAME'
OR UPPER(p_type) = 'OWNER.NAME'
THEN
RETURN str_owner || '.' || str_name;
ELSIF UPPER(p_type) = 'TYPE'
THEN
RETURN str_type;
ELSE
RETURN str_owner;
END IF;
END SELF_EXAM; -
How to get the current function name in java
How to get the current function name in java.
In c it is done as
printf("%s",__func__);
Thanx in advance.j0o wrote:
System.out.println("Class Name: " + new Exception().getStackTrace()[0].getClassName() +
"/n Method Name : " + new Exception().getStackTrace()[0].getMethodName() +
"/n Line number : " + new Exception().getStackTrace()[0].getLineNumber());
I pointed the OP at this approach yesterday in one of his multi-posts. I still have not been given my Dukes! -
How to get the pull path name from a file upload window
Hello everyone!
I have encountered the following problem with the following JSP code:
<form method="post" action="filename.jsp">
Upload JAVA program:
<input type=file size=20 name="fname" accept="java">
<input type=submit value="go">
</form>
<%
String s = "";
if (request.getParameter("fname") != null)
s = request.getParameter("fname")
%>
The value of s is alway the filename. However I want to get the full path in addition to the filename, so that I can read the file. Does anyone know how to get the pull name of the file?
thanks a lot in advance,Dear Sir,
thanks a lot for your reply. Please let me explain what I intended to do: I want to upload a file from the local machine and then read the content of the file. Therefore I need to the fullpath of the filename like /var/local/file.java instead of file.java. The latter is what I got.
The problem I have with your code is that the function like "request.getServerScheme()" is not recognized. Maybe is it because I didn't install servelet package? I only installed javax package btw. Also my application runns on Tomcat server if this could give you some information. The error message I had is as follows:
org.apache.jasper.JasperException: Unable to compile class for JSP
An error occurred at line: 36 in the jsp file: /addExercise.jsp
Generated servlet error:
[javac] Compiling 1 source file
/usr/local/jakarta-tomcat-5.0.12/work/Catalina/localhost/tutor/org/apache/jsp/addExercise_jsp.java:133: cannot resolve symbol
symbol : method getServerScheme ()
location: interface javax.servlet.http.HttpServletRequest
url = request.getServerScheme()
^
An error occurred at line: 36 in the jsp file: /addExercise.jsp
Generated servlet error:
/usr/local/jakarta-tomcat-5.0.12/work/Catalina/localhost/tutor/org/apache/jsp/addExercise_jsp.java:136: cannot resolve symbol
symbol : method getServerScheme ()
location: interface javax.servlet.http.HttpServletRequest
+ ((("http".equals(request.getServerScheme()) && request.getServerPort() != 80)
^
An error occurred at line: 36 in the jsp file: /addExercise.jsp
Generated servlet error:
/usr/local/jakarta-tomcat-5.0.12/work/Catalina/localhost/tutor/org/apache/jsp/addExercise_jsp.java:137: cannot resolve symbol
symbol : method getServerScheme ()
location: interface javax.servlet.http.HttpServletRequest
||("https".equals(request.getServerScheme()) && request.getServerPort() != 443))
^
An error occurred at line: 36 in the jsp file: /addExercise.jsp
Generated servlet error:
/usr/local/jakarta-tomcat-5.0.12/work/Catalina/localhost/tutor/org/apache/jsp/addExercise_jsp.java:139: cannot resolve symbol
symbol : method getServletConfig ()
location: interface javax.servlet.http.HttpServletRequest
+ "/" + request.getServletConfig().getServletName()
^
An error occurred at line: 36 in the jsp file: /addExercise.jsp
Generated servlet error:
/usr/local/jakarta-tomcat-5.0.12/work/Catalina/localhost/tutor/org/apache/jsp/addExercise_jsp.java:140: cannot resolve symbol
symbol : variable path
location: class org.apache.jsp.addExercise_jsp
+ "/" + path
^
5 errors
org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:128)
org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:351)
org.apache.jasper.compiler.Compiler.generateClass(Compiler.java:413)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:453)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:437)
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:555)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:291)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:301)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:248)
javax.servlet.http.HttpServlet.service(HttpServlet.java:856) -
How to get the full path instead of just the file name, in �FileChooser� ?
In the FileChooserDemo example :
In the statement : log.append("Saving: " + file.getName() + "." + newline);
�file.getName()� returns the �file name�.
My question is : How to get the full path instead of just the file name,
e.g. C:/xdirectory/ydirectory/abc.gif instead of just abc.gif
import java.io.*;
import java.awt.*;
import java.awt.event.*;
import javax.swing.*;
import javax.swing.filechooser.*;
public class FileChooserDemo extends JFrame {
static private final String newline = "\n";
public FileChooserDemo() {
super("FileChooserDemo");
//Create the log first, because the action listeners
//need to refer to it.
final JTextArea log = new JTextArea(5,20);
log.setMargin(new Insets(5,5,5,5));
log.setEditable(false);
JScrollPane logScrollPane = new JScrollPane(log);
//Create a file chooser
final JFileChooser fc = new JFileChooser();
//Create the open button
ImageIcon openIcon = new ImageIcon("images/open.gif");
JButton openButton = new JButton("Open a File...", openIcon);
openButton.addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent e) {
int returnVal = fc.showOpenDialog(FileChooserDemo.this);
if (returnVal == JFileChooser.APPROVE_OPTION) {
File file = fc.getSelectedFile();
//this is where a real application would open the file.
log.append("Opening: " + file.getName() + "." + newline);
} else {
log.append("Open command cancelled by user." + newline);
//Create the save button
ImageIcon saveIcon = new ImageIcon("images/save.gif");
JButton saveButton = new JButton("Save a File...", saveIcon);
saveButton.addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent e) {
int returnVal = fc.showSaveDialog(FileChooserDemo.this);
if (returnVal == JFileChooser.APPROVE_OPTION) {
File file = fc.getSelectedFile();
//this is where a real application would save the file.
log.append("Saving: " + file.getName() + "." + newline);
} else {
log.append("Save command cancelled by user." + newline);
//For layout purposes, put the buttons in a separate panel
JPanel buttonPanel = new JPanel();
buttonPanel.add(openButton);
buttonPanel.add(saveButton);
//Explicitly set the focus sequence.
openButton.setNextFocusableComponent(saveButton);
saveButton.setNextFocusableComponent(openButton);
//Add the buttons and the log to the frame
Container contentPane = getContentPane();
contentPane.add(buttonPanel, BorderLayout.NORTH);
contentPane.add(logScrollPane, BorderLayout.CENTER);
public static void main(String[] args) {
JFrame frame = new FileChooserDemo();
frame.addWindowListener(new WindowAdapter() {
public void windowClosing(WindowEvent e) {
System.exit(0);
frame.pack();
frame.setVisible(true);simply use file.getPath()
That should do it!Thank you !
It takes care of the problem !! -
How to get the name of the current tab.
Hi Experts,
I have two tabs in my tab strip and a button common to both the tabs.Can you please let me know how to get the name of the current tab in the event method of the push button.
Thanks in advance.
Regards,
Arun1.Declare an Action for OnSelect event of Tabstrip. This event is triggered whenever any change in tab occurs.
2. Declare an Import Parameter in this method
Tab type String.
3. This parameter has value of the selected TAB.
4. You can set this value in some Attribute in Attribute Tab in this event only (OnSelect):
wd_this->Att = Tab.
Att is the attribute created by you in Attributes Tab of View. ( of type String)
5. Now the selected Tab ID is stored in this Attribute Att.
6. In the Onaction of Button , retrieve the selected tab value from this attribute using :
Data : lv type string.
lv = wd_this->Att
Now lv has your selected TAB ID.
I hope it would help you.
Edited by: Saurav Mago on Oct 13, 2009 2:22 PM
Maybe you are looking for
-
I am running Bridge CS5 for the first time and I receive this error when attempting to create a contact sheet. "There is insufficient disk space to complete this operation." The image files I am using are web optimized and very small. The error even
-
Hello Gurus, which transaction code can be used to show up all long-time running jobs in bw? how can we identify if a job is running too long? Many thanks, frank
-
My macbook pro 2012 keeps restarting saying there is a problem
My macbook pro with retina display 2012 keeps restarting saying there is a problem. tHEN A REORT POPS UP
-
Oracle DB Link x Oracle DBCO Connection
Hi all, Can anybody explain to me which the difference is between using the Oracle DB Link or Oracle DBCO Connection? And which are the advantages and disadvantages in using each one? Thanks for help, Douglas Marques
-
My imac suddenly shuts down while on line.
My imac suddenly shuts down while on line. It has to be unpluged for a couple of hours before it will restart. Could it be the battery dying? Any other sugestions?