Call a login function

I created a program that acts like a login, pops a window that's asking for a username and password.
Now I want to make it a function and call it in any program that I want. Then if the credentials are ok I will let them save the changes for example and if not they will be blocked.
How do I do this?

Hi Adrain,
CReate a FM and define a screen in the FM main program to accept the users logon details.
You can call a screen within a FM.
Take a loook at the FM <b>"SSFH_PASSWORD_PROMPT"</b>
There are many FM for password. DO a F4 in se37 with PASSWORD
Cheers
VJ
Message was edited by: Vijayendra  Rao

Similar Messages

  • Calling a RFC Function Module

    Hello Guys,
    I have a question regarding calling a RFC function module.
    In BW - BI 7.0 I call a RFC function module:
    (The ABAP program in BW-BI 7.0 is below)
      CALL FUNCTION ''ZTESTFUNCTIONMODULE'  " Function module in ECC
         DESTINATION 'DECCLNT110'  " ECC system
        TABLES
          it_gl_item   = it_gl
          it_errlog_gl = it_errlog_gl.
    The 'ZTESTFUNCTIONMODULE'   is RFC enabled in the ECC system.
    The purpose is we retarct the data from BW to ECC.
    When I run the function module it always asks for the user id and password.
    The SAP logon screen appears and it asks for the user id and password.
    The destination is maintained in the SM59 transaction and also the user is maintained there. I think it should login automatically into remote system and return the tables. is it correct. How to skip the logon screen.
    Do I have to pass the user id and password in the function module. I think it should take the user id from the SM59 destination. Is it correct.
    Please advise. As always thanks for your help guys.

    Hi Senthil,
    I think you answered your query in your question itself
    The user ID and password need to be maintained in RFC destination in SM59.
    Go to SM59 and then click on test connection..if it does not ask for ID and passwoed that means correct ID and password is maintained in SM59 otherwise maintain it.
    Regards,
    Atish

  • Debuggin a Call to Remote Function Module

    Hi
    I have a scenario where i have a Remote Function Module in r3 which is being called synchronously by an external java application. The FM has a lot of input and output parameters and many tables.  The output returned by the FM is not as expected.
    Can anyone tell me how debug a Remote Function Module when a call has been made from an external application.
    I am not able to get the test data sent by the external application . So when the external application gives a call to this Remote FM and if it is possibele to debug it would be great.
    regards
    Nilesh Taunk.

    Hi Nilesh,
    1) Login to SAP with the same ID with which you will calling the RFC function module from the outside system.
    2) Goto transaction - se37/se38
    3) Goto Utilities => Settings.
    4) Select the ABAP Editor Tab.
    5) Click on the Debugging tab.
    6) Tick the Actv. button and give the user name with which you will be debugging the code. In this case the logged in user id.
    7) Press Enter.
    8) Now put an external break point inside the Function Module.
    9) Load your external application (from where you want to debug the FM) once again.
    The execution will stop in the FM.
    Hope it helps..
    Lokesh
    PS: This was a simple question, but I guess the reason no one has answered your question is due to the fact that you havent rewarded points to members helping you. Also remember to close your post once it has been answered.

  • Calling an ABAP function module

    Hi friends,
    I am developing an application in EP6 SP2 using JSPDynPage from which, want to call an ABAP function module that returns table and show the values from this table in this application.
    I went thru various blogs and APIs. I am confused between SAP JCO, JCO client service and connector framework. Do u have any documentation on how to connect to R3 systems and call a function module, retrieve results etc.
    Regards,
    Nilz

    JCo is the point to start. This gives you low level access to all rfc functions. Everything else (accept BSP and Web dynpro) are just layers of encapsulation around the low level JCo function.
    The steps are always like this:
    call the sap system for rfc login
    prepare data areas and call in java
    call the rfc in the R/3 system
    handle exceptions
    logoff and free ressource
    continue with data obtained in R/3
    There is a lot of material around jco. One book that is fairly ok is :
    SAP Interface Programming
    A comprehensive reference for RFC, BAPI, and JCo programming
    J. Meiners, W. Nüßer
    SAP PRESS ISBN 1-59229-034-5
    This helps you navigate through the wealth of information also at SDN

  • Help with login function

    I have an application where i only want user from this table to be able to login
    CREATE TABLE Supervisor
    (Supervisor_id Number PRIMARY KEY,
    Name CHAR(40) NOT NULL,
    Password varchar(15) NOT NULL,
    Area_Of_Interest varchar2(50) NOT NULL,
    Max_Supervision_Allocation Number NOT NULL,
    Current_Supervision_Allocation Number NOT NULL,
    Supervision_Slots_Left Number NOT NULL,
    Max_Second_Reader_Allocation Number NOT NULL,
    Current_SR_Allocation Number NOT NULL,
    READER_SLOTS_LEFT Number NOT NULL,
    MORE_INFO VARCHAR2(4000));
    So i created a custom authentication function that did this as so:
    create or replace function supervisor_custom_auth(
    p_username VARCHAR2,
    p_password VARCHAR2)
    return BOOLEAN is
    begin
    for c1 in (select 1
    from supervisor
    where upper(name) = upper(p_username)
    and upper(password)=p_password)
    loop
    return true;
    end loop;
    return false;
    end;
    and called it in my new schem and set the scheme to current. But this doesnt seem to work can anyone spot an error as i cant see it.
    Thanks
    Dan

    Sorry I mean the function doesnt seem to work
    create or replace function supervisor_custom_auth2(
    p_username VARCHAR2,
    p_password VARCHAR2)
    return BOOLEAN is
    begin
    for c1 in (select 1
    from Supervisor
    where upper(Name) = upper(p_username)
    and upper(Password)= upper(p_password))
    loop
    return true;
    end loop;
    return false;
    end;
    the select part
    select 1
    from Supervisor
    where upper(Name) = upper(p_username)
    and upper(Password)= upper(p_password))
    I have run the select statment in sql commands changing the p_username and p_password for the a particualr database record and it works fine.
    So i dont think it is the function that i have created that is the problem.
    When creating the scheme i accepted all the built in logic apart from the calling the authentication function when specifing a custom authentication function and i changed the logout url.
    Is there anything else i can check. I have tired running it in debug mode and the values get entered correctly so i dont know what is wrong it uses the standard login check
    wwv_flow_custom_auth_std.login(
    P_UNAME => :P101_USERNAME,
    P_PASSWORD => :P101_PASSWORD,
    P_SESSION_ID => v('APP_SESSION'),
    P_FLOW_PAGE => :APP_ID||':1'
    If anyone else has any ideas then i am all ideas and if anyone wants to have a look at it the application number is 22477 as i am totally stuck.
    The function does not bring any errors when it entered into the sql commands and there are no errors when the user tries to log in. How can i check the function is actually being called?
    Thanks
    Dan

  • [SOLVED]Call to undefined function mysql_connect()

    Hi. Up until this point I have had mysql, php, and apache up and running just fine. Recently I made a little change. I configured Apache to read my .php pages from /home/user/code/php instead of /srv/http. It wasn't working originally so I created a new http user using this command:
    useradd -d /srv/http -r -s /bin/false -U http
    And replaced /srv/http with the directory of my choice. Almost everything went fine. I was able to see all my .php files. The problem was with one file. This is the code for it:
    <?php
    mysql_connect("localhost", "root", "mypass") or die(mysql_error());
    echo "Connected to MySQL<br />";
    ?>
    Originally it displayed everything fine but once I made the switch it displayed this error:
    Fatal error: Call to undefined function mysql_connect() in /home/'user'/code/php/connect.php on line 2
    I tried to login to phpMyAdmin as well and this error is displayed:
    The mysqli extension is missing. Please check your PHP configuration. <a href="Documentation.html#faqmysql" target="documentation"><img src="themes/dot.gif" title="Documentation" alt="Documentation" class="icon ic_b_help" /></a>
    Not sure if it matters but I have made the switch to a systemd only installation and have run systemctl enable httpd.service, systemctl enable mysqld.service, systemctl start httpd.service, and systemctl start mysql.service countless times just to be sure. I have also made sure that
    extension=mysqli.so
    extension=mysql.so
    Are both uncommented in /etc/php/php.ini
    Last edited by xworld (2012-11-08 00:48:14)

    Here's phpinfo():
    Linux net 3.6.6-1-ARCH #1 SMP PREEMPT Mon Nov 5 11:57:22 CET 2012 x86_64
    Build Date Oct 17 2012 20:31:37
    Configure Command './configure' '--srcdir=../php-5.4.8' '--config-cache' '--prefix=/usr' '--sysconfdir=/etc/php' '--localstatedir=/var' '--with-layout=GNU' '--with-config-file-path=/etc/php' '--with-config-file-scan-dir=/etc/php/conf.d' '--disable-rpath' '--mandir=/usr/share/man' '--without-pear' '--disable-cli' '--with-apxs2' '--enable-bcmath=shared' '--enable-calendar=shared' '--enable-dba=shared' '--enable-exif=shared' '--enable-ftp=shared' '--enable-gd-native-ttf' '--enable-intl=shared' '--enable-mbstring' '--enable-phar=shared' '--enable-posix=shared' '--enable-shmop=shared' '--enable-soap=shared' '--enable-sockets=shared' '--enable-sysvmsg=shared' '--enable-sysvsem=shared' '--enable-sysvshm=shared' '--enable-zip=shared' '--with-bz2=shared' '--with-curl=shared' '--with-db4=/usr' '--with-enchant=shared,/usr' '--with-freetype-dir=/usr' '--with-gd=shared' '--with-gdbm' '--with-gettext=shared' '--with-gmp=shared' '--with-iconv=shared' '--with-icu-dir=/usr' '--with-imap-ssl' '--with-imap=shared' '--with-jpeg-dir=/usr' '--with-vpx-dir=/usr' '--with-ldap=shared' '--with-ldap-sasl' '--with-mcrypt=shared' '--with-mhash' '--with-mssql=shared' '--with-mysql-sock=/var/run/mysqld/mysqld.sock' '--with-mysql=shared,mysqlnd' '--with-mysqli=shared,mysqlnd' '--with-openssl=shared' '--with-pcre-regex=/usr' '--with-pdo-mysql=shared,mysqlnd' '--with-pdo-odbc=shared,unixODBC,/usr' '--with-pdo-pgsql=shared' '--with-pdo-sqlite=shared,/usr' '--with-pgsql=shared' '--with-png-dir=/usr' '--with-pspell=shared' '--with-snmp=shared' '--with-sqlite3=shared,/usr' '--with-tidy=shared' '--with-unixODBC=shared,/usr' '--with-xmlrpc=shared' '--with-xsl=shared' '--with-zlib'
    Server API Apache 2.0 Handler
    Virtual Directory Support disabled
    Configuration File (php.ini) Path /etc/php
    Loaded Configuration File /etc/php/php.ini
    Scan this dir for additional .ini files /etc/php/conf.d
    Additional .ini files parsed (none)
    PHP API 20100412
    PHP Extension 20100525
    Zend Extension 220100525
    Zend Extension Build API220100525,NTS
    PHP Extension Build API20100525,NTS
    Debug Build no
    Thread Safety disabled
    Zend Signal Handling disabled
    Zend Memory Manager enabled
    Zend Multibyte Support provided by mbstring
    IPv6 Support enabled
    DTrace Support disabled
    Registered PHP Streams compress.zlib, php, file, glob, data, http, ftp
    Registered Stream Socket Transports tcp, udp, unix, udg
    Registered Stream Filters zlib.*, string.rot13, string.toupper, string.tolower, string.strip_tags, convert.*, consumed, dechunk
    Sorry if there is a better way to post this. If so I'm willing to fix it. I posted the part that I thought was relevant
    I do have extension_dir="/usr/lib/php/modules:
    ; Directory in which the loadable extensions (modules) reside.
    ; http://php.net/extension-dir
    extension_dir = "/usr/lib/php/modules/"
    ; On windows:
    ; extension_dir = "ext"
    Also, the file /usr/lib/php/modules/mysql.so does exist.

  • How to call a C function calling a Java Method from another C function ?

    Hi everyone,
    I'm just starting to learn JNI and my problem is that I don't know if it is possible to call a C function calling a Java Method (or doing anything else with JNI) from another C function.
    In fact, after receiving datas in a socket made by a C function, I would like to create a class instance (and I don't know how to do it too ; ) ) and init this instance with the strings I received in the socket.
    Is all that possible ?
    Thank you very much for your help !

    Hard to understand the question, but by most interpretations the answer is going to be yes.
    You do of course understand that JNI is the "API" that sits between Java and C and that every call between the two must go through that. You can't call it directly.

  • How to call a SQL function from an XSL expression

    Hi
    In R12, in Payroll Deposit adivce/Check writer, We need to sort the earnings tag <AC_Earnings> in to two different categories as regular and other earnings. In the DB and form level of element defintiion we have a DFF which differentiates between the two kinds of earnings. But the seeded XML that is gerneated by the check writer does not have this field.
    The seeded template displays all the earnings in one column. How can we achieve this in the template without modifying the seeded XML.
    The one approach i have is to write a function and based on the return value sort the data. For this I need to know :
    1) How to call a SQL function from an XSL expression that is allowed in BI template.
    If anyone ahs faced similar requirements please share your approach.
    Thanks
    Srimathi

    Thank u..
    but i'd seen that link wen i searched in google..
    Is it possible without using any 3rd party JARs and all?
    and more importantly plz tell me what should be preferred way to call a javascript function?
    Do it using addLoadEvent() or Windows.Load etc
    OR
    Call it thru Xsl? (I donno how to do dis)
    Thanks in Advance..
    Edited by: ranjjose on Jun 3, 2008 8:21 AM

  • Problem while calling an RFC Function Module in Background

    Hello,
    I have created a RFC function module for reading data from an external DB system. The FM calls an external RFC program (coded in C++ using RFC SDK), which delivers the required data. This external program is maintainged as an TCP RFC Connection in SM59.
    Further I have created a report, that calls the RFC function module to get the data from the external RFC programm.
    My problem is, when I call the report in foreground, everything works OK, the RFC connection works and data can be read from the external program.
    However, when I schedule the report to run in background as a job, the report is stating in the protocoll that there was a problem calling the defined RFC connection (although the connection is working properly at that time).
    More funny is, this particular problem with running in background occurs only in the productive system, in test and development system the report works correctly also while running as a job in background.
    Can you suggest the solution to this problem? Could it be something with authorisations or server settings?
    I will be on holiday for the next 6 weeks, so take your time to answer .
    Regards,
    Dusan.
    Edited by: Julius Bussche on Jan 22, 2009 7:19 PM
    Please read the forum rules about u r g e n t ...

    This is an external RFC server program, not a remote enabled ABAP RFC function module as the others seem to be assuming, right?
    Is it possible that your DEV and QAS systems only have one application server, but the PROD has many and dedicated one(s) for processing low priority background jobs?
    It might be that the target server of your TCP connection is not this BTC instance, and your RFC server is returning the data "locally" - so, into nirvana...
    Just guessing, but might be worth checking.
    Cheers,
    Julius

  • How can I have a backing file call a JavaScript function?

    I have a Weblogic portal with a JSP portlet. The portlet has a backing file. How can I get the backing file to call a JavaScript function in my portlet?
    thanks

    Hi
    your questions are not correct because you are mixing up server side operations with client side operations.
    First server side code executes then the page is sent to the browser , then any javascript executes on the browser. So asking for javascript to be called from backing file (server side) doesn't make sense or asking for javascript to read a parameter doesnt exactly work either.
    However in your server code suppose you have a variable action in the request that you want javascript to know then in your JSP you would add something like
    <script type="text/javascript">
    var action = '${requestScope.action}';
    alert(action);//or whatever you want to do
    <c:if test="${requestScope.someOthervariable == ''xyz'}"><%-- this check is done on the server --%>
    callSomeJavascript(); <%--this javascript is only executed when the server side value of someOtherVariable is xyz --%>
    </c:if>
    </script>
    i.e. you can output the javascript that has the variables you need or the function calls you want.
    Like I said understand whats server side and whats client side.

  • How can I call a plsql function from an attribute?

    I have an attribute defined in an element. I want execute a PLSQL function from the attribute, and display the returne value with an HTML template.
    I've defined the attribute's type like PLSQL, and I've put the called of the function in the value of the attribute, but it doesn't work. The only value I obtain is an URL (I think that is the URL of the function or someting like this).
    How can I call to my function from the attribute and display the returnes value in the page?
    Thanks.

    Thanks, but it doesn't work. I have an attribute called ID_BOL and I want to associate a sequence to that attribute. I've created a function, with the sequence. This function return de value of the sequence. I want taht the attribute takes the value of the sequenece dinamically.
    I've tried it, creating the type attribute like PLSQL, and calling the function from the attribute, but it doesn't work.
    How can I return the sequence value to my attribute?
    Thanks.

  • Visual fortran calling a c function in visual studio

    Hi,
    I am running Windows 8.1 with Visual Studio Prof. 2012. I have installed Visual Fortran also. Now I wanted to make a solution with two projects one for Visual Fortran and one for C, and be able to call a C function from within the Fortran. 
    Can someone, please, show how to do this step by step? Guide with pictures would be awesome.
    Thanks in advance.

    Hi Engineer101,
    One way to integrate your code into TestStand would be to save it as a .dll file.  Cick this link for information on how to do this in visual c++ 2008. Once you have the dll, you can call it in teststand using a c/c++ dll action step.  I hope this helps, and let me know if you have any further questions!
    Al B.
    Staff Software Engineer - TestStand
    CTA/CLD

  • How to call a Javascript function from backing bean without any event

    Hi,
    Someone knows how to call a Javascript function from backing bean without any event ?
    thanks

    Please review the following thread:
    ADF Faces call javascript
    Luis.

  • How to call the 'DETAIL' function in ALV for a program?

    Dear Friends,
    I have a prf_tree (TYPE REF TO cl_gui_alv_tree), and I added below codes to add an new button for displaying the detail record, it works fine:
    CALL METHOD prf_toolbar->add_button
        EXPORTING
          fcode     = prf_tree->mc_fc_detail
          icon      = icon_detail
          butn_type = cntb_btype_button
          text      = ''
          quickinfo = 'Show Details'.
    Everytime I click this new button, a window will popup and display the record details.
    My question is: how to call this standard function  ('DETAIL' function) in a program? for example:
    CASE ldf_ok_code.
        WHEN gcf_okcode_save.
          PERFORM okcode_save.
        WHEN 'SHOW_DETAIL'.
          CHECK  gdf_nodkey_9003 IS NOT INITIAL.
          PERFORM SHOW_DETAIL.(How to write this code to display the detail data of the selected record?)
      Thanks a lot!

    Hi,
    Go for Interactive Reporting
    like When u click on the output then it will show the Detail report u want .
    for that purpose Pls
    Use Hide command .
    And call another report
    by using SUBMITT Program

  • Calling Synchronous RFC Function Module in Background

    Hi all,
    Currently we are working on some requirement where in we have to retrieve data from one system(CRM) and update the same into another system(ECC). We have developed a RFC Function in CRM system and it is being called from ECC system as in synchronous mode via a batch program.
    Now since all sychronous call to a RFC function will be dialog there is a constraint on the runtime which is being set by maximum run time for each dialog work process. So my question is there an option to call an RFC function synchronously in background (background task) so there is no runtime performance.
    The standard TRFC, QRFC calls in background runs asynchronously and so I am trying to check with the SDN world as whether has anyone tried  SRFC(Synchronous) call in background?
    Thanks in advance,
    Jagath

    So my question is there an option to call an RFC function synchronously in background (background task) so there is no runtime performance.
    One solution would be to increase the value of the "time out" parameter defined the CRM system. This i feel is not a fool-proof solution as the run-times cannot be predicted. Check this thread: Re: RFC timeout profile parameter
    For me a better solution would be to implement tRFC call instead of a synchronous call. Any reasons why you don't want to implement a tRFC ?
    BR,
    Suhas
    Edited by: Suhas Saha on Jun 26, 2010 8:52 AM

Maybe you are looking for

  • Search replace Word doc - Getting Erro : org.eclipse.swt.SWTException:

    Hi All I'm runing this Java class by a jsp to Search and Replace and saveAs a word document, when run the fisrt time it works OK, but if I run again I got this error: What is happing there? Following the Error and Source Java. Thanks 11:59:49,234 ERR

  • Problem Using XQuery Operators

    I have been able to use every XPath function in the "fn" namespace so far with no problem. Unfortunately, when I tried to use an XQuery operator from the "op" namespace, I get an error. I am trying to use "op:date-equals(xs:date, xs:date)" and I get

  • Example of Unix Korn Shell to run .scr (similar to NT .bat)??

    Wondering if anyone has an example of a Korn shell script that they use in Unixto run the Essbase script (.scr) to load up an outline.I am using NT .bat and will do the same in Unix. I will be so gratefull.Please email me [email protected]! Karim

  • Held PO triggering workflow and agent assignment to myself

    Hi experts, Is there a way where I can prevent held documents from triggering my workflow? How can I achieve the following 2 scenarios for agent assignment: 1) Create PO and workitem route back to myself 2) Release PO and workitem route back to mysel

  • Multiple display problem

    I have a 2010 2.8GHz Quad core all stock no upgrades. It is currently connected to a VGA monitor with a dual link DVI to VGA adaptor through a KVM switch and all works great. I am trying to connect a Vizio TV via mini displayport to HDMI then cat6 HD