Extract filename from a path

Hi folks!
Anybody knows if there is a MF to extract the filename from a path...
for example, if i have a path like:
server\filename.ext
c:filename.ext
c:\>filename.txt
i want to extract the filename: 'filename.ext' (or just, 'filename')
Thank's in advance!
Xavi.

Hi,
You can use the FM <b>CACS_SPLIT_PATH</b>
  Import parameters               Value         
  I_PATH                          C:TEST.TXT                                                                               
Export parameters               Value         
  E_PATH                          C:           
  E_FILENAME                      TEST.TXT      
  E_PSERVER                       X  
Regards
vijay

Similar Messages

  • Regexp problem when extracting filename from path

    I'm trying to extract filename and full path from string: \dir1\dir2\file.name
    import java.util.regex.*;
    public class Main {  
        private static final String REGEX = "(\\S*\\)*(\\S*)";
        private static final String INPUT = "\\dir1\\dir2\\file.name";
        public Main() {    }   
        public static void main(String[] args) {
           Pattern p = Pattern.compile(REGEX);
           Matcher m = p.matcher(INPUT); // get a matcher object
           int count = 0;      
           if(m.find()) {
               count++;          
               System.out.println("group1: "+m.group(1));
               System.out.println("group2: "+m.group(2));                     
    }I expect group1 to be \dir1\dir2\ and group2 file.name
    when I run program exception is thrown:
    Exception in thread "main" java.util.regex.PatternSyntaxException: Unclosed group near index 12
    (\S*\)*(\S*)
    ^
    at java.util.regex.Pattern.error(Pattern.java:1650)
    at java.util.regex.Pattern.accept(Pattern.java:1508)
    at java.util.regex.Pattern.group0(Pattern.java:2460)
    at java.util.regex.Pattern.sequence(Pattern.java:1715)
    at java.util.regex.Pattern.expr(Pattern.java:1687)
    at java.util.regex.Pattern.compile(Pattern.java:1397)
    at java.util.regex.Pattern.<init>(Pattern.java:1124)
    at java.util.regex.Pattern.compile(Pattern.java:817)
    at javaapplication2.Main.main(Main.java:15)

    'jverd' is right but if you are just trying to split the INPUT into a path + filename then why not just look for the last '\'. i.e.
    int lastSlash = INPUT.lastIndexOf('\\');
    String group1 = INPUT.substring(0, lastSlash);
    String group2 = INPUT.substring(lastSlash+1);
    As it stands, your example will not give you group 1 as \dir1\dir2. For that you would need something like
    "((?:\\[^\\])*)(\\.*)"
    to make sure you capure all the path in group 1.

  • (fileSystem::extract Blob From Local Path) after installing B.O. XI 3.1

    Hello,
    I've installed B.O. XI 3.1 client tool on a laptop, but when I try to run Designer, or Deski the following error occurs (REPOSITORY ERROR (fileSystem::extract Blob From Local Path) file not found) and the application quits.
    Anyone has an idea?

    Hi
    What operating system are you using on your laptop?
    I have a colleague having a similar problem using Windows Vista, whereas I am fine (using XP).
    Did you manage to resolve this issue? (And if so, how)
    regards, Lara

  • How to get FILENAME from FILE PATH

    does anyone know how to get filename from a file path for example
    FILE PATH: C:\Project\uploadbean\web\uploads\Button.txt
    returns
    FILENAME: Button.txt

    @BalusC
    ust for a reference cause i'm new in JSP This has nothing to do with JSP, but with basic knowledge of an essential API. I have given you the link to the File API. Are you saying that you refused to read the API documentation, which clearly explains you how to use the File and shows which methods are all available to you undereach the straightforward getName() method, and expecting that the others may chew the answers for you? Loser.

  • Filename from complete file path

    Hi,
       can anybody let me know the method to get the filename from the complete filepath( this path includes both directory as well as filename)
    regards.
    venkat.

    Hi,
    Check the below code:
    data : ig_path type standard table of tp_path,
           wg_path type tp_path.
    data : g_lines     type i          ,
           g_filename  type string     .
    parameter : p_input type rlgrap-filename.
      split p_input at '\' into table ig_path.
      describe table ig_path lines g_lines.
      read table ig_path index g_lines into wg_path.
      g_filename = wg_path-val.
    write : g_filename.
    Regards,
    Raghu

  • Extracting files from Portfolio - problem with outlook email created portfolios

    Currently I have developed a plugin that can extract files from portfolios using:-
    PDNameTree tree = PDDocGetNameTree(pdDoc, ASAtomFromString("EmbeddedFiles"));
    and
    PDFileAttachmentFromCosObj
    But i've noticed with Outlook email created portfolios the above is PDNameTree invalid.  any suggestions?   is it under another atom string or something?
    Thanks,
    Lee.

    ok, found something out here... if I close the doc using AVDocClose then re-open in the code using PDDocOpen then the PDNameTree tree = PDDocGetNameTree(pdDoc, ASAtomFromString("EmbeddedFiles"));  works!!!
    but now I have a problem getting the original pdf open filename.
    usually can get it with below code but it's returning the Folder path + garbage instead. (this only happens with portfolios created by outlook that I have tested)
    There must be a better way of doing this, any ideas? thanks, lee.
    ASFile asFile = PDDocGetFile(pdDoc);
    ASPathName asPathName = ASFileAcquirePathName(asFile);
    char* temp = ASFileSysDIPathFromPath(ASGetDefaultFileSys(), asPathName, NULL);

  • Extract files from a zip file

    Here is my scenario:
    I have a zip file, DataStore.zip, which as two layers of zip files.
                                         DataStore.zip
                                               |
               01.zip       02.zip         03.zip      04.zip etc
                                 |
                     02a.zip          02b.zip         02c.zip        
     etc
                         |
                cert1.zip   cert2.zip     cert3.zip     etc
    I need to search for  any cert.zip embedded at layer3, for which I have written the following program.
    I have two issues. First one is, when the files at level 1 (01.zip etc are written to the disk folder c:\ extract, it doesn't allow me to read back from that folder., I get "access to path c:\extract is denied". I researched and found that this
    is a security issue with windows 8 and 7. ( I tried both versions). How can I overcome this?
    second issue is, if in the  first read cycle  it fails with "unknown block type, stream may be corrupted", I need to bypass that corrupted zip file and continue, until I get my target file.
    The code is give below. Appreciate any help.. Thanks.
    using System;
    using System.Collections.Generic;
    using System.ComponentModel;
    using System.Data;
    using System.Drawing;
    using System.Linq;
    using System.Text;
    using System.Threading.Tasks;
    using System.Windows.Forms;
    using System.IO;
    using System.IO.Compression;
    namespace TPMCert
    {   // Utility to copy a TPM certificate from the master file.
        public partial class Form1 : Form
            public Form1()
                InitializeComponent();
            private void Form1_Load(object sender, EventArgs e)
            private void btnSelDrv_Click(object sender, EventArgs e)
                if (folderBrowserDialog1.ShowDialog() == DialogResult.OK)
                    string filePath1 = this.folderBrowserDialog1.SelectedPath; //
                    this.txtDrv.Text = filePath1;
            }//btnselDrv
            private void btnTpmReq_Click(object sender, EventArgs e)
                    OpenFileDialog openFile1 = new OpenFileDialog();
                    if (openFile1.ShowDialog() == System.Windows.Forms.DialogResult.OK)
                        txtRqstFileName.Text = openFile1.FileName.Remove(0, 3); //remove first 3 chars which is c:/ etc
            private void btnGo_Click_1(object sender, EventArgs e)
                    string zPath = txtDrv.Text + "\\" +"TpmDataStore.zip"; //drive & filename to to search.....
                    string extractPath= txtDrv.Text
    +@"\extract";
                    string extractPath2 = txtDrv.Text + @"\extract\certs";
                    string copyPath = txtDrv.Text; // location of the tpm certificate finall written to..
                    bool filefound = false;
                     //look for the file. read only allowed...
                   // try
                        using (ZipArchive archive = ZipFile.OpenRead(zPath)) //open Tpm file for reading
                            txtInfo.AppendText("Processing ....  Please wait!" + "\n");
                            Cursor.Current = Cursors.WaitCursor; //busy cursor
                            foreach (ZipArchiveEntry zEntry in archive.Entries) //each top level zip file is written to \extract dir
                                zEntry.ExtractToFile(Path.Combine(extractPath, zEntry.FullName), true); //true- overwrite
                                txtInfo.AppendText(" First write passed...");
                                //next iterate thro' all zip files in \extract dir
                               using (ZipArchive archive2 =ZipFile.Open(extractPath, ZipArchiveMode.Update)) //read files in extract
                                   foreach (ZipArchiveEntry childEntry in archive2.Entries)
                                       childEntry.ExtractToFile(Path.Combine(extractPath2,
    childEntry.Name), true); //true- overwrite
                                       MessageBox.Show(childEntry.Name);
                                       txtInfo.AppendText(" Second cycle....");
                                       if (childEntry.Name == txtRqstFileName.Text)
                                               filefound
    = true; //
                                               //MessageBox.Show(zEntry.FullName);
                                               txtInfo.AppendText("Found
    file " + childEntry.Name + "\n");
                                               txtInfo.AppendText("File
    copied as " + copyPath + "\\" + childEntry.Name + "\n");
                                }//second using..
                            }//foreach
                            if (filefound == false ) // given file is not there
                                txtInfo.AppendText("File not found" +  "\n");
                        }//using
                    }//try
                       // catch (Exception ex)
                               // MessageBox.Show(" Error:" + "\n" + ex.Message);
                                return;
                             //finally
                            { Cursor.Current = Cursors.Default;
                // next
            } //btnGo..
        }//class form1
    }//namespace

    Hi friend,
    We'd better to ask one question in each thread. If you have another issue, you can consider to open up a new thread in this forum.
    Now for the first question, do you mean this picture? It throws access exception in archive2.
    If so , because your extractPath is a path, not a directory.You should add +"xxx.zip". For more information, please refer to
    ZipFile.Open
    Method (String, ZipArchiveMode).
    For the second question, you can use the following code to skip the error message.
    while (true)
    try
    //do something;
    catch (Exception ex)
    { continue; }
    Good day!
    Kristin
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • Extracting data from Excel To Illustrator javascript or vbscript

    Hi all-
    I was wondering if there was a way to extract data from Excel to be used in Illustrator. I know there is an option of variables and xml, and I don't want that. I've seen and tried out how to read illustrator and write to excel, and I get that.  What I would like to do is pretty much the opposite:
    1.Pre-fill in an Excel file(.xls,.csv, doesn't matter) with data such as a filename in column 1 and (Replacement Text) in column 2 and close manually.
    2. Run script(VBSCRIPT,Javascript, doesn't matter)
    3.For each column in Excel file where cell in first column is not empty, open Illustrator Template with placeholder of "DWG" textframe and replace the frame titled "DWG" with Replacement text from Excel in Column2.
    4, Save each to a PDF file and name file with text from Excel Column1(Filename)
    In a nutshell, there will be a single illustrator template with a premade textFrame with a name of "DWG". Excel will contain two columns, one for the filename to be named and one for the relative text to replace with the placeholder in AI. I hoped I explained this well enough without causing too much confusion. Thanks in advance.
    Filename
    Replacement Text
    test1.pdf
    DWG01
    test2.pdf
    DWG02
    test3.pdf
    DWG03
    test4.pdf
    DWG04

    As text… \n is new line character and \r is return character. I can't remember which excel uses but they both equate to a line/paragraph… I very quickly threw together an example for you…
    #target Illustrator
    textToPDF();
    function textToPDF() {
              if ( app.documents.length == 0 ) { return; }
              var doc, csvFile, i, fileArray, opts;
              csvFile = File( '~/Desktop/ScriptTest/Test.csv' );
              if ( !csvFile.exists ) { return; }
              fileArray = readInCSV( csvFile );
              doc = app.activeDocument;
              opts = new PDFSaveOptions();
              opts.pDFPreset = '[Press Quality]';
              // Here we loop the main array
              for ( i = 0; i < fileArray.length; i++ ) {
                        // Here we get the second item of sub array i
                        doc.textFrames.getByName( 'DWG' ).contents = fileArray[i].[1];
                        // Here we get the first item of sub array i
                        doc.saveAs( File( fileArray[i].[0] ), opts );
    function readInCSV( fileObj ) {
              var fileArray, thisLine, csvArray;
              fileArray =[];
              fileObj.open( 'r' );
              while( !fileObj.eof ) {
                        thisLine = fileObj.readln();
                        csvArray = thisLine.split( ',' );
                        fileArray.push( csvArray );
              fileObj.close();
              return fileArray;
    I haven't tested it but it should be close…?

  • Extract data from a table

    Hi All,
    How to extract data from a table to a excel sheet.
    I want matnr and desc from MARA.
    Please help me.
    Thanks
    Veni

    Programmatically it would like something like this.
    report  zrich_0001.
    data: begin of imakt occurs 0,
          matnr type makt-matnr,
          maktx type makt-maktx,
          end of imakt.
    start-of-selection.
      select matnr maktx into table imakt from makt.
      call method cl_gui_frontend_services=>gui_download
        exporting
    *      BIN_FILESIZE              =
          filename                  = 'C:makt.xls'
           write_field_separator     = 'X'
        changing
          data_tab                  = imakt
        exceptions
          others                    = 24
    Regards,
    Rich Heilman

  • File name from file path

    Hi Friends,
    i am using METHOD CL_GUI_FRONTEND_SERVICES=>FILE_OPEN_DIALOG
    i want to know the file name selected from the path.
    example : c:\folder\file.txt.
    here i want to know which file i have selected. if it is a small path then we can use SPLIT command but if the path selected is long with special chareters then?
    urget requirement.
    regards
    Kumar M.

    u can use this function...
    CALL FUNCTION 'WS_FILENAME_GET'
       EXPORTING
         DEF_PATH         = 'C:\'
         MASK             = '*.xls'
         MODE             = 'O'
         TITLE            = SY-TITLE
       IMPORTING
         FILENAME         = FILENAME
       EXCEPTIONS
         INV_WINSYS       = 1
         NO_BATCH         = 2
         SELECTION_CANCEL = 3
         SELECTION_ERROR  = 4
         OTHERS           = 5.
    have a nice day...

  • Problem to extract text from HTML document

    I have to extract some text from HTML file to my database. (about 1000 files)
    The HTML files are get from ACM Digital Library. http://portal.acm.org/dl.cfm
    The HTML page is about the information of a paper. I only want to get the text of "Title" "Abstract" "Classification" "Keywords"
    The Problem is that I can't find any patten to parser the html files"
    EX: I need to get the Classification = "Theory of Computation","ANALYSIS OF ALGORITHMS AND PROBLEM COMPLEXITY","Numerical Algorithms and Problem","Mathematics of Computing","NUMERICAL ANALYSIS"......etc .
    The section code about "Classification" is below.
    Please give any idea to do this, or how to find patten to extract text from this.
    <div class="indterms"><a href="#CIT"><img name="top" src=
    "img/arrowu.gif" hspace="10" border="0" /></a><span class=
    "heading"><a name="IndexTerms">INDEX TERMS</a></span>
    <p class="Categories"><span class="heading"><a name=
    "GenTerms">Primary Classification:</a></span><br />
    � <b>F.</b> <a href=
    "results.cfm?query=CCS%3AF%2E%2A&coll=ACM&dl=ACM&CFID=22820732&CFTOKEN=38147335"
    target="_self">Theory of Computation</a><br />
    � <img src="img/tree.gif" border="0" height="20" width=
    "20" /> <b>F.2</b> <a href=
    "results.cfm?query=CCS%3A%22F%2E2%22&coll=ACM&dl=ACM&CFID=22820732&CFTOKEN=38147335"
    target="_self">ANALYSIS OF ALGORITHMS AND PROBLEM
    COMPLEXITY</a><br />
    � � � <img src="img/tree.gif" border="0" height=
    "20" width="20" /> <b>F.2.1</b> <a href=
    "results.cfm?query=CCS%3A%22F%2E2%2E1%22&coll=ACM&dl=ACM&CFID=22820732&CFTOKEN=38147335"
    target="_self">Numerical Algorithms and Problems</a><br />
    </p>
    <p class="Categories"><span class="heading"><a name=
    "GenTerms">Additional�Classification:</a></span><br />
    � <b>G.</b> <a href=
    "results.cfm?query=CCS%3AG%2E%2A&coll=ACM&dl=ACM&CFID=22820732&CFTOKEN=38147335"
    target="_self">Mathematics of Computing</a><br />
    � <img src="img/tree.gif" border="0" height="20" width=
    "20" /> <b>G.1</b> <a href=
    "results.cfm?query=CCS%3A%22G%2E1%22&coll=ACM&dl=ACM&CFID=22820732&CFTOKEN=38147335"
    target="_self">NUMERICAL ANALYSIS</a><br />
    � � � <img src="img/tree.gif" border="0" height=
    "20" width="20" /> <b>G.1.6</b> <a href=
    "results.cfm?query=CCS%3A%22G%2E1%2E6%22&coll=ACM&dl=ACM&CFID=22820732&CFTOKEN=38147335"
    target="_self">Optimization</a><br />
    � � � � � <img src="img/tree.gif" border=
    "0" height="20" width="20" /> <b>Subjects:</b> <a href=
    "results.cfm?query=CCS%3A%22Linear%20programming%22&coll=ACM&dl=ACM&CFID=22820732&CFTOKEN=38147335"
    target="_self">Linear programming</a><br />
    </p>
    <br />
    <p class="GenTerms"><span class="heading"><a name=
    "GenTerms">General Terms:</a></span><br />
    <a href=
    "results.cfm?query=genterm%3A%22Algorithms%22&coll=ACM&dl=ACM&CFID=22820732&CFTOKEN=38147335"
    target="_self">Algorithms</a>, <a href=
    "results.cfm?query=genterm%3A%22Theory%22&coll=ACM&dl=ACM&CFID=22820732&CFTOKEN=38147335"
    target="_self">Theory</a></p>
    <br />
    <p class="keywords"><span class="heading"><a name=
    "Keywords">Keywords:</a></span><br />
    <a href=
    "results.cfm?query=keyword%3A%22Simplex%20method%22&coll=ACM&dl=ACM&CFID=22820732&CFTOKEN=38147335"
    target="_self">Simplex method</a>, <a href=
    "results.cfm?query=keyword%3A%22complexity%22&coll=ACM&dl=ACM&CFID=22820732&CFTOKEN=38147335"
    target="_self">complexity</a>, <a href=
    "results.cfm?query=keyword%3A%22perturbation%22&coll=ACM&dl=ACM&CFID=22820732&CFTOKEN=38147335"
    target="_self">perturbation</a>, <a href=
    "results.cfm?query=keyword%3A%22smoothed%20analysis%22&coll=ACM&dl=ACM&CFID=22820732&CFTOKEN=38147335"
    target="_self">smoothed analysis</a></p>
    </div>

    One approach is to download Htmlparser from sourceforge
    http://htmlparser.sourceforge.net/ and write the rules to match title, abstract etc.
    Another approach is to write your own parser that extract only title, abstract etc.
    1. tokenize the html file. --> convert html into tokens (tag and value)
    2. write a simple parser to extract certain information
    find out about the pattern of text you want to extract. For instance "<class "abstract">.
    then writing a rule for extracting abstract such as
    if (tag is abstract ) then extract abstract text
    apply the same concept for other tags
    Attached is the sample parser that was used to extract title and abstract from acm html files. Please modify to include keyword and other fields.
    good luck
    import java.io.BufferedReader;
    import java.io.FileReader;
    import java.io.IOException;
    import java.io.InputStream;
    import java.io.InputStreamReader;
    import java.util.ArrayList;
    import java.util.List;
    public class ACMHTMLParser
         private String m_filename;
         private URLLexicalAnalyzer lexical;
         List urls = new ArrayList();
         public ACMHTMLParser(String filename)
              super();
              m_filename = filename;
          * parses only title and abstract
         public void parse() throws Exception
              lexical = new URLLexicalAnalyzer(m_filename);
              String word = lexical.getNextWord();
              boolean isabstract = false;
              while (null != word)
                   if (isTag(word))
                        if (isTitle(word))
                             System.out.println("TITLE: " + lexical.getNextWord());
                        else if (isAbstract(word) && !isabstract)
                             parseAbstract();
                             isabstract = true;
                   word = lexical.getNextWord();
              lexical.close();
         public static void main(String[] args) throws Exception
              ACMHTMLParser parser = new ACMHTMLParser("./acm_html.html");
              parser.parse();
         public static boolean isTag(String word)
              return ( word.startsWith("<") && word.endsWith(">"));
         public static boolean isTitle(String word)
              return ( "<title>".equals(word));
         //please modify according to the html source
         public static boolean isAbstract(String word)
              return ( "<p class=\"abstract\">".equals(word));
         private void parseAbstract() throws Exception
              while (true)
                   String abs = lexical.getNextWord();
                   if (!isTag(abs))
                        System.out.println(abs);
                        break;
         class URLLexicalAnalyzer
           private BufferedReader m_reader;
           private boolean isTag;
           public URLLexicalAnalyzer(String filename)
              try
                m_reader = new BufferedReader(new FileReader(filename));
              catch (IOException io)
                System.out.println("ERROR, file not found " + filename);
                System.exit(1);
           public URLLexicalAnalyzer(InputStream in)
              m_reader = new BufferedReader(new InputStreamReader(in));
           public void close()
              try {
                if (null != m_reader) m_reader.close();
              catch (IOException ignored) {}
           public String getNextWord() throws IOException
              int c = m_reader.read();   
              if (-1 == c) return null; 
              if (Character.isWhitespace((char)c))
                return getNextWord();
              if ('<' == c || isTag)
                return scanTag(c);
              else
                   return scanValue(c);
           private String scanTag(final int c)
              throws IOException
              StringBuffer result = new StringBuffer();
              if ('<' != c) result.append('<');
              result.append((char)c);
              int ch = -1;
              while (true)
                ch = m_reader.read();
                if (-1 == ch) throw new IllegalArgumentException("un-terminate tag");
                if ('>' == ch)
                     isTag = false;
                     break;
                result.append((char)ch);
              result.append((char)ch);
              return result.toString();
           private String scanValue(final int c) throws IOException
                StringBuffer result = new StringBuffer();
                result.append((char)c);
                int ch = -1;
                while (true)
                   ch = m_reader.read();
                   if (-1 == ch) throw new IllegalArgumentException("un-terminate value");
                   if ('<' == ch)
                        isTag = true;
                        break;
                   result.append((char)ch);
                return result.toString();
    }

  • Getting filename from a string including filepath and filename

    How I can get a filename from a string which includes both
    filepath and filename? The filepath is not always the same. For
    example, the variable could include a "C:\temp\test.doc" or
    "C:\files\docfiles\test.doc" and I need to get the filename
    "test.doc" and save it to another variable. Thanks in
    advance.

    on getFilenameFromPath vPath
    oldDelim=the itemDelimiter
    the itemDelimiter=the last char of the moviePath
    iFilename=the last item of vPath
    the itemDelimiter=oldDelim
    return iFilename
    end
    Put that into a movie script. Then you can call the function
    any time
    to retrieve the last part of the path- like this:
    put getFilenameFromPath("C:\temp\test.doc")
    -- "test.doc"
    As an added bonus, it is cross-platform so it will work on a
    Mac as well
    as a PC.

  • Filename from field

    I have seen in past discussions about the difficluty and even impossibility of creating a SAVE AS filename from a field value in an Adobe form.  These discussions were posted back in 2006-2008.
    I am hoping that someone knows a relatively simple way to do this (if it's possible in Acrobat 10)  I am relatively new to Adobe and Javascripts.
    All I want to do is have a button that does a SAVE AS (I can do this), but pull the filename from the "NAME" field in the form and add the .pdf extension and place it in a particular directory on the server.
    Seems like this would be possible...  can anyone point me in the right direction?
    Thanks a million!!
    DMD    

    George,
    I think I should document exactly what is happening, so here goes…
    FROM ACROBAT X PRO - The form is working and saving via the mouse up JavaScript action coupled with the folder-level JS that contains;
    myTrustedSpecialTaskFunc   and  mySaveAs = app.trustPropagatorFunction
    In order to save it for READER users, I do a FILE, SAVE AS, READER EXTENDED PDF, ENABLE ADDITIONAL FEATURES.
    I copy the folder level JS over to the proper JS folder associated with READER
    I can open the file in READER and edit the form fields. 
    When I try to save the file using the Custom Save As button that works in ACROBAT, I get this error;
    NotAllowedError: Security settings prevent access to this property or method.
    Doc.saveAs:4:Field Save:Mouse Up
    NOTES:
    ·         I know that I am using the correct JavaScript folder for READER because I placed this JS code in the folder and it DOES display when I open READER-  app.alert("It works!");
    ·         I am saving the file in both instances to c:\temp\filename.pdf
    ·         When I distribute the form, I will be able to place the folder-level JS on the users machine.
    Per your last post, when I open the file that I have saved as above for READER in ACROBAT and go to file>properties>security I have the following displayed;
    Security: No Security
    Can be opened by: All versions of Acrobat
    Document Restrictions Summary
    Printing: Allowed
    Changing the document: Not allowed*
    Document assembly: Not allowed*
    Content copying: Allowed
    Content copying for accessibility: Allowed
    Page extraction: Allowed
    Commenting: Allowed
    Filling of form Fields: Allowed
    Signing: Allowed
    Creation of template pages: Not allowed*
    *This document restricts some Acrobat features in order to allow for extended features in Adobe Reader
    At this point, I am a a loss as to what is causing the error.  I hope this documentation helps you see where my problem is.
    Thanks,
    Dan

  • STEPS REQUIRED TO EXTRACT DATA FROM FLAT FILE TO BI 7.0

    HI ALL,
      I NEED THE STEPS TO EXTRACTED THE DATA FROM A FLAT FILE TO BI 7.0
    PLEASE PROVIDE ME THE STEPS RATHER THAN PROVIDEING ME THE COMPLETE LINK OF SAP HELP.
    I NEED THE STEPS ONLY.
    THANKS,
    GAUTAM

    BW 7.0
    Uploading of master data
    Log on to your SAP
    Transaction code RSA1—LEAD YOU TO MODELLING
    1.     Creation of Info Objects
    •     In left panel select info object
    •     Create info area
    •     Create info object catalog ( characteristics & Key figures ) by right clicking the created info area
    •     Create new characteristics and key figures under respective catalogs according to the project requirement
    •     Create required info objects and Activate.
    2.     Creation of Data Source
    •     In the left panel select data sources
    •     Create application component(AC)
    •     Right click  AC and create datasource
    •     Specify data source name, source system, and data type ( master data attributes, text, hierarchies)
    •     In general tab give short, medium, and long description.
    •     In extraction tab specify file path, header rows to be ignored, data format(csv) and data separator( , )
    •     In proposal tab load example data and verify it.
    •     In field tab you can you can give the technical name of info objects in the template and you not have to map during the transformation the server will automatically map accordingly. If you are not mapping in this field tab you have to manually map during the transformation in Info providers.
    •     Activate data source and read preview data under preview tab.
    •     Create info package by right clicking data source and in schedule tab click star to load data to PSA.( make sure to close the flat file during loading )
    3.     Creation of data targets
    •     In left panel select info provider
    •     Select created info area and right click to select Insert Characteristics as info provider
    •     Select required info object ( Ex : Employee ID)
    •     Under that info object select attributes
    •     Right click on attributes and select create transformation.
    •     In source of transformation , select object type( data  source) and specify its name and source system Note: Source system will be a temporary folder or package into which data is getting stored
    •     Activate created transformation
    •     Create Data transfer process (DTP) by right clicking the master data attributes
    •     In extraction tab specify extraction mode ( full)
    •     In update tab specify error handling ( request green)
    •     Activate DTP and in execute tab click execute button to load data in data targets.
    4.     Monitor
       Right Click data targets and select manage and in contents tab select contents to view the loaded data. Alternatively monitor icon can be used.
    BW 7.0
    Uploading of Transaction data
    Log on to your SAP
    Transaction code RSA1—LEAD YOU TO MODELLING
    5.     Creation of Info Objects
    •     In left panel select info object
    •     Create info area
    •     Create info object catalog ( characteristics & Key figures ) by right clicking the created info area
    •     Create new characteristics and key figures under respective catalogs according to the project requirement
    •     Create required info objects and Activate.
    6.     Creation of Data Source
    •     In the left panel select data sources
    •     Create application component(AC)
    •     Right click  AC and create datasource
    •     Specify data source name, source system, and data type ( Transaction data )
    •     In general tab give short, medium, and long description.
    •     In extraction tab specify file path, header rows to be ignored, data format(csv) and data separator( , )
    •     In proposal tab load example data and verify it.
    •     In field tab you can you can give the technical name of info objects in the template and you not have to map during the transformation the server will automatically map accordingly. If you are not mapping in this field tab you have to manually map during the transformation in Info providers.
    •     Activate data source and read preview data under preview tab.
    •     Create info package by right clicking data source and in schedule tab click star to load data to PSA.( make sure to close the flat file during loading )
    7.     Creation of data targets
    •     In left panel select info provider
    •     Select created info area and right click to create ODS( Data store object ) or Cube.
    •     Specify name fro the ODS or cube and click create
    •     From the template window select the required characteristics and key figures and drag and drop it into the DATA FIELD and KEY FIELDS
    •     Click Activate.
    •     Right click on ODS or Cube and select create transformation.
    •     In source of transformation , select object type( data  source) and specify its name and source system Note: Source system will be a temporary folder or package into which data is getting stored
    •     Activate created transformation
    •     Create Data transfer process (DTP) by right clicking the master data attributes
    •     In extraction tab specify extraction mode ( full)
    •     In update tab specify error handling ( request green)
    •     Activate DTP and in execute tab click execute button to load data in data targets.
    8.     Monitor
       Right Click data targets and select manage and in contents tab select contents to view the loaded data. There are two tables in ODS new table and active table to load data from new table to active table you have to activate after selecting the loaded data . Alternatively monitor icon can be used
    cheers
    sunil

  • Extract program to extract data from SAP into multiple worksheets of excel

    Hi , I am currently facing an issue.
    Extracting the data during data extraction, conversion into an excel and also into multiple worksheets withing a excel file.
    What is the function which can help me. Also how do you give refernce to multiple worksheets to be created withing a excel file (which is the destination)
    Any sample program extracting data from SAP tables into a excel with multiple worksheet will be of immense help
    Please respond. Appreciate it.
    Rgds
    Madhu

    Hi Madhu,
    Here is the program for creating the excel file and creating the multiple worksheets.
    *& Report  ZEXCEL_UPLOAD2
    REPORT  ZEXCEL_UPLOAD2.
    INCLUDE ole2incl.
    DATA: application TYPE ole2_object,
           workbook TYPE ole2_object,
           sheet TYPE ole2_object,
           cells TYPE ole2_object.
    CONSTANTS: row_max TYPE i VALUE 256.
    DATA index TYPE i.
    DATA: BEGIN OF itab1 OCCURS 0, first_name(10), END OF itab1.
    DATA: BEGIN OF itab2 OCCURS 0, last_name(10), END OF itab2.
    DATA: BEGIN OF itab3 OCCURS 0, formula(50), END OF itab3.
    *START-OF-SELECTION
    START-OF-SELECTION.
      APPEND: 'Peter' TO itab1, 'Ivanov' TO itab2,
                                  '=Sheet1!A1 & " " & Sheet2!A1' TO itab3,
                'John' TO itab1, 'Smith' TO itab2,
                                  '=Sheet1!A2 & " " & Sheet2!A2' TO itab3.
      CREATE OBJECT application 'excel.application'.
      SET PROPERTY OF application 'visible' = 0.
      CALL METHOD OF application 'Workbooks' = workbook.
      CALL METHOD OF workbook 'Add'.
    Create first Excel Sheet
      CALL METHOD OF application 'Worksheets' = sheet
                                   EXPORTING #1 = 1.
      CALL METHOD OF sheet 'Activate'.
      SET PROPERTY OF sheet 'Name' = 'Sheet1'.
      LOOP AT itab1.
        index = row_max * ( sy-tabix - 1 ) + 1. " 1 - column name
        CALL METHOD OF sheet 'Cells' = cells EXPORTING #1 = index.
        SET PROPERTY OF cells 'Value' = itab1-first_name.
      ENDLOOP.
    Create second Excel sheet
      CALL METHOD OF application 'Worksheets' = sheet
                                   EXPORTING #1 = 2.
      SET PROPERTY OF sheet 'Name' = 'Sheet2'.
      CALL METHOD OF sheet 'Activate'.
      LOOP AT itab2.
        index = row_max * ( sy-tabix - 1 ) + 1. " 1 - column name
        CALL METHOD OF sheet 'Cells' = cells EXPORTING #1 = index.
        SET PROPERTY OF cells 'Value' = itab2-last_name.
      ENDLOOP.
    Create third Excel sheet
      CALL METHOD OF application 'Worksheets' = sheet
                                   EXPORTING #1 = 3.
      SET PROPERTY OF sheet 'Name' = 'Sheet3'.
      CALL METHOD OF sheet 'Activate'.
      LOOP AT itab3.
        index = row_max * ( sy-tabix - 1 ) + 1. " 1 - column name
        CALL METHOD OF sheet 'Cells' = cells EXPORTING #1 = index.
        SET PROPERTY OF cells 'Formula' = itab3-formula.
        SET PROPERTY OF cells 'Value' = itab3-formula.
      ENDLOOP.
    Save excel speadsheet to particular filename
      CALL METHOD OF sheet 'SaveAs'
                      EXPORTING #1 = 'c:\temp\exceldoc1.xls'     "filename
                                #2 = 1.                          "fileFormat
    Closes excel window, data is lost if not saved
    SET PROPERTY OF application 'visible' = 0.
    **Quick guide to some of the OLE statements for OLE processing in this program as well as a few other ones.
    Save Excel speadsheet to particular filename
    CALL METHOD OF sheet 'SaveAs'
                    EXPORTING #1 = 'C:\Users\dprasad\Desktop\excel_sheet.xls'     "filename
                              #2 = 1.                          "fileFormat
    Save Excel document
    CALL METHOD OF sheet 'SAVE'.
    Quits out of Excel document
    CALL METHOD OF sheet 'QUIT'.
    Closes visible Excel window, data is lost if not saved
    SET PROPERTY OF application 'visible' = 0.

Maybe you are looking for

  • Why i can't open my hotmail with iphone but safari and laptop can open

    Why i can't open my hotmail with iphone but safari and laptop can open why???

  • Problem while calling smartform in webdynpro

    Hi Experts, I  am calling a smartform in webdynpro abap. It was working fine in development server. I have ported the same request to Quality Server, there it was not working.it is giving sy-subrc = 1 and it is displaying a blank screen I m following

  • Rsrt aggregate recommendations

    How can I use rsrt to get aggregate recommendations? I am running a query and it takes too long to run. I want to see if rsrt can give me any recommendations but I am not sure how.

  • Book icon not opening when clicked

    I have an odd problem here. In my Contents tab on the left side, I have eight Book icons that, when clicked, open to reveal the Help topics inside them- just like any normal RoboHelp project would work. However, the very last Book icon in the list do

  • Comment mettre "visionné" à mes fichiers ?

    Bonjour, je viens d'ajouter de nouveaux fichiers vidéos à ma bibliothèque que j'ai déjà visionné. Itunes marque ces fichiers comme non-visionnés, comment peut-on marquer ces fichiers comme visionnés ? (Je suis sur Mac) Merci.