Simple File I/O

Ok, I know this is a newb question but I just cant figure out why my code wont read the file i specify on the command line. The muse of Java is not being kind to me.
When I run this program i get the exception "blah!". Any feedback would be wonderful. Thanks.
import java.io.*;
import java.lang.*;
import java.util.*;
public class Show {
public static void main(String[] argv)
          StringBuffer Filetx = null;
//Get the file name from the command input.
          try {
               String InputFile = argv[0];
               String OutputFile = argv[1];
               System.out.println(InputFile);
               System.out.println(OutputFile);
          catch (Exception e)
               System.out.println("Command line argument could not be read.");
               System.exit(0);
          //Read the input file
          try
               BufferedReader input = new BufferedReader(new FileReader(argv[0]));
               System.out.println(input);
          catch(FileNotFoundException e)
               System.out.println("Blah!");
               System.exit(0);
}

I have learn so far the type of error is very important. Copy the output of the compiler and post it.
You might find this example helpful it is slight different from what you are doing but the basics are there:
import java.util.StringTokenizer;
import java.util.Iterator;
import java.util.Map;
import java.util.TreeMap;
import java.util.List;
import java.util.LinkedList;
import java.io.IOException;
import java.io.BufferedReader;
import java.io.FileReader;
class Concordance
     * A main routine that:
     * 1. Reads a file containing strings (from args[0])
     * 2. Prints each string, and the lines on which it occurs
     * Skimpy error checks to avoid clogging up the code.
    public static void main( String [ ] args )
        try
            BufferedReader inFile = new BufferedReader( new FileReader( args[0] ) );
            Map wordMap = new TreeMap( );
            String oneLine;
                // Read the words; add them to wordMap
            for( int lineNum = 1; ( oneLine = inFile.readLine( ) ) != null; lineNum++ )
                StringTokenizer st = new StringTokenizer( oneLine );
                while( st.hasMoreTokens( ) )
                    String word = st.nextToken( );
                    List lines = (List) wordMap.get( word );
                    if( lines == null )
                        lines = new LinkedList( );
                        wordMap.put( word, lines );
                    lines.add( new Integer( lineNum ) );
                // Go through the word map
              Iterator itr = wordMap.entrySet( ).iterator( );
            while( itr.hasNext( ) )
                printEntry( (Map.Entry) itr.next( ) );
         catch( IOException e )
           { e.printStackTrace( ); }
    public static void printEntry( Map.Entry entry )
             // Print the word
         System.out.println( entry.getKey( ) + ":" );
             // Now print the line numbers
         Iterator itr = ( (List)(entry.getValue( )) ).iterator( );
         System.out.print( "\t" + itr.next( ) );
         while( itr.hasNext( ) )
             System.out.print( ", " + itr.next( ) );
         System.out.println( );
}I hope this helps and let muse of Java enlighted your path ;)

Similar Messages

  • Does simple file and folder sharing on an iMac work with OSX Server?

    Hi There
    I wonder if I should install OSX Server on an iMac wher several users work on the same files and folders.
    My question - before I do something I might regret:
    Does simple file and folder sharing on an iMac within several users really work with the help of OSX Server?
    All I want to be able to do:
    Admin creates a new folder1 and gives it read- and write access for user1 and user2.
    User1 creates a subfolder1 in folder1, and a document1 in subfolder1.
    User2 edits document1. Later Admin edits document1.
    All these simple editing of files and folders (and subfolders) within a main folder should be possible. This is not possible now.
    Is everything clear? I'm not a network specialist or something, I just want to give some co-workers access to some data on my computer without problems.

    So what you need are recursive permissions.
    I suggest you create a group and add user1 and user2 to that group. You can name that group whatever you want, but for now i will call it FSUsers
    Execute this in terminal. Replace FSUsers with your new group
    sudo chmod -R +a "FSUsers allow list,add_file,search,add_subdirectory,delete_child,readattr,writeattr,readextat tr,writeextattr,readsecurity,file_inherit,directory_inherit" /Users/Shared/*
    Replace /Users/Shared with the location of your shared folder. Make sure you keep the /* at the end (this allows all subfolders and files to get the same permissions.
    If you need to add people to the share just add them to the FSUsers group, the FSUsers group should should also be allowed in the sharing preferences.

  • Error in simple(File-XI-File)scenario

    Hi,
    Using this blog i was doing simple(File-XI-File)scenario.
    /people/venkat.donela/blog/2005/03/02/introduction-to-simplefile-xi-filescenario-and-complete-walk-through-for-starterspart1
    But i am getting the error
    Runtime error
    com.sap.aii.utilxi.misc.api.BaseRuntimeException thrown during application mapping com/sap/xi/tf/_MM_FILE_TO_FILE_CC_: Fatal Error: com.sap.engine.lib.xml.parser.
    What could be the problem ?
    Thanks.

    Hi,
      Check ur Mapping objects and do test it in the test tab of MM or IM before activating.Once it is done do activate it.
    Refer to below links as well:
        /people/srinivas.vanamala2/blog/2007/02/05/step-by-step-guide-xml-file-2-xml-file-scenario-part-i
        /people/srinivas.vanamala2/blog/2007/02/05/step-by-step-guide-xml-file-2-xml-file-scenario-part-ii
    Cheers,
    Prasanthi.

  • How to create a simple File structure for a large project?

    Hi to all,
    I've own and operated my own website design/development (a 1 woman office, plus many sub-contractors) over the period of 8 years. I started hand-coding HTML sites in 1997, before the creation DW (though I think the first ver was for Mac in '97). Over the recent years I've udated my skills to include CSS and enough Java/PHP to customize and/or troubleshoot current projects (learn as I go).
    The majority of my clients have been other 1-10 person entrepreneur companies. I've recently won a bid to redesign a government site which consist of 30 departments, including their main site.
    The purpose of this thread is to get some ideas on creating a file management/structure. Creating file management setup for smaller companies was a piece of cake, using a simple file mgmt structure within DW. Their current file structure is all over the place. I've read about a very good, simple file struture in a DW CS4 manual and wanted to get feedback on different methods that have worked, and have not worked, or your client:
    Here's my thinking:
    1. within the root dir place home.htm and perhaps a few .htm related only to home
        2. create the following folders off the root, "docs, imgs/global, CSS, FLA, Departments"
                - sub folders within docs for each dept
                - site wide css's placed into CSS
                - site wide FLAs into the FLA
                - sub-folders created within 'imgs' for each dept, including a 'global folder' for sitewide images and menu imgs (if needed)
    - OR -
    1. create same file structure for each dept folder, such as 'imgs/CSS/FLA/Docs'
    Open for suggestions....
    Ciao

    It is a problem I have thought over at length and still feel what I use could be better. You are doing it the right way around researching before you start, as moving files once things are underway can course real problems. One issue is the use of similar assets across site(s), and version control if you have multiple versions of the same asset.
    Can not say I have built a site(s) of that size but would recommend putting together a flow chart to help visualise the structure and find out better ways organising (works for me). Good luck, post back with your solution.

  • Simple file to file transfer.  Pls advice urgent

    Hi All,
    I have Simple file to file transfer.
    There are text files at source side that need to send at receiver side.
    Source text files name are different so I have used
    Adapter Specific Attributes for Sender and Receiver Adapetrs
    Question
    As these are text files and there is no mapping required what interface name should I give at Sender Aggrement and
    at Interface Determination.
    Pls describe steps
    Regards

    Rider,
    Its very simple scenario. For ur satisfaction I did the same, it's working perfectly. I don't know what mistake u did. Let me give the complete picture.
    Step1: Create new Scenario
    Step2: Create new Business Service, let say File_BusService
    Step3: In File_BusService add the outbound and Inbound Interface name and namespaces , like
    Outbound Interface: MyInterface
    Outbound Interfacenamespace: http://my-own-namespace.com
    Inbound Interface: MyInterface
    Inbound Interfacenamespace: http://my-own-namespace.com
    Step4: Create two communication Channels under File_BusService
    Step5: Receiver Determination.
    Sender:File_BusService
    Outbound Interface: MyInterface
    Outbound Interfacenamespace: http://my-own-namespace.com
    Configured Receivers
    File_BusService
    Step6: Interface Determination.
    Sender:File_BusService
    Outbound Interface: MyInterface
    Outbound Interfacenamespace: http://my-own-namespace.com
    Inbound Interface: MyInterface
    Step7: Receiver agreement
    Receiver Service: File_BusService
    Inbound Interface: MyInterface
    Receiver Comm.channel
    Step8: Sender Agreement.
    Sender:File_BusService
    Outbound Interface: MyInterface
    Outbound Interfacenamespace: http://my-own-namespace.com
    Sender Comm.channel.
    raj.

  • CPS Simple File Deployer corrupts XLSX and DOCX files when copying to server. Solutions?

    When Contribute Publishing Service Simple File Deployment copies XLSX and DOCX files from our staging server to the live production web server, it is corrupting them.  The resulting file on the live web server is a few bytes different in size.  I published a 9015-byte docx file to our staging server using Dreamweaver (or Contribute).  The resulting file on the staging server opens correctly and remains 9015 bytes.  Then, using CPS Simple File Deployer, I deployed the file from our staging server to our live web server.  The resulting file on the live web server is 9017 bytes, and it won't open.  Something similar happens with XLSX files.  It works fine with XLS, DOC, Html etc.  Well, there is an issue with dependent files unless I synchronize with Dreamweaver, but that's another story.
    Once File Deployer has corrupted the files, opening them brings a message, such as "Excel has found unreadable content in filename.xlsx. . . ".  With Word, it says "The Office Open XML file filename.docx cannot be opened because there are problems with the contents . . . The file is corrupt and cannot be opened."  Sometimes the docx files can be recovered, but that doesn't help. 
    When I take the same original docx file and put it on the web server with an FTP program, it remains 9015 bytes and opens successfully on the live web server.
    For several reasons, such as many users updating the website with Adobe Contribute and not let them use FTP directly to the live server, we need to keep the staging server and use File Deployer (or something) to deploy the changed files from the staging server to the live website.
    I read somewhere that the programming code the uploads files can have problems and fail to work properly with Office 2007 files.  I don't have access to CPS's core.ctc and deployfile.cfc files, and I don't have Cold Fusion. 
    Any suggestions?
    Dean

    Try: 
    Open My Computer.
    Open the Tools menu and choose Folder Options...
    Select the File Types tab.
    Select the extension (for example DOC, or XLS) of the file that is slow to open.
    In the Details section, click [Advanced], and another dialog box will open. 
    In the Actions section, click Open then click [Edit...], and another dialog box will open.
    http://windowssecrets.com/forums/showthread.php/149672-10-9-2012-Updates-and-very-slow-opening-of-Office-files
    KR

  • [SOLVED]Simple file transfer between different os'es

    Hi
    I'm searching for some kind of simple file transfer between different computers/os (mainly arch and windows) on local net, without I have to set up any samba/ftp server etc. It would be perfect if i could select a file I want to transfer and then be able to receive it on a different computer.
    So far I've tried giver but I most of the times they can't find each other.
    Any know how I could archive something like the a bow?
    Thanks
    Last edited by zann (2012-12-07 01:43:44)

    Try using simple file sharing through http server 'oneliner's.
    - Note your host IP (which I refer to by "ip.of.your.server"),
    - Go under your directory where you want to share files and fire a command line :
    Using python : python2 -m SimpleHTTPServer 8000
    And you can access your files on the network using http://ip.of.your.server:8000/
    Using php : php -S localhost:8080 -t webrootpath/
    Files under webrootpath/ will be accessible from http://ip.of.your.server:8888/
    Using mongoose : mongoose -r . -p 8888
    Files will be accessible from http://ip.of.your.server:8888/
    You may restrict access, ie.:  -l -0.0.0.0/0,+10.60.100.105
    And have access/error logging (à la apache) too : -a access_log.txt -e error_log.txt
    NB.: You may install python or php under windows but mongoose is the easiest thing when it comes to windows -> linux.
    Last edited by xpixelz (2012-12-04 15:01:40)

  • Simple file loader with cffile

    Hello;
    I'm trying to make a basic file loader for my web site. I've written the file upload, and it works. I'll attach that code. I was wondering if someone could help me over this small hurdle I need to get past... let me explain.
    I have an admin section in my web site. This file loader is to add new thumbnail images to a db record and show it on the front end. There is an option to either edit and existing record, or add a new record.
    When you get to the editor, I'm putting in a link for a pop up window that has this file loader in it. What I want to do it after you load this file, I need it to be able to close the window and add it to the editor section so the file name can be loaded into the database.
    Is this possible and kind of simple? I realize nothing is too simple doing this kind of programming, I'm just trying to find a decent solution that works. Maybe there is a tutorial out there for this kind of thing? Or maybe someone can help me with a couple lines of code so I can take it from there?
    This is my file loader:
    <cfset UploadFolder="c:\Inetpub\wwwroot\website\img\babies">
    <cfif IsDefined("Form.UploadFile") AND Form.UploadFile NEQ "">
    <cffile
         action="upload"
            filefield="UploadFile"
            destination="#UploadFolder#"
            nameconflict="overwrite"
            >
    File uploaded successfully!
        <br />
        Uploaded file: <cfoutput>#cffile.ClientFile#</cfoutput>
    <cfelse>
    Select a file first!       
    </cfif>
    <form name="UploadForm" method="post" enctype="multipart/form-data" action="">
    <input type="file" name="UploadFile">
        <input type="submit"  name="submit" value="Upload"/>
    </form>
    I can also post the db code for the page I'm loading it into if need be. I would have to refresh the page I believe to get the info from the pop up to the parent window that spawned it. I have a script for that:
    <a href="javascript:opener.top.location=('/test/edit-record.cfm');" onclick= "javascript:window.close();">close window</a>
    can anyone help me make this work properly? OR point me in a direction of a tutorial for a simple file loader of this type?
    thank you.

    I was wondering if Ajax would be a good solution. Can you tell me this
    ? I have a file loader I use all the time, but on this server, it's not working properly. Can you look at my code and possibly tell me why? I
    know this is a lot of code I'm pasting, but it is pretty strait forward. It doesn't thrown an error, it just doesn't load the file
    at all.
    I would rather use this, I have it all written:
    <!--- form submitted --->
    <!--- set file uploading vars --->
    <cfparam name="fileuploaded" type="boolean" default="false">
    <cfparam name="uploadedfile" default="">
    <cfset pathToFile = "c:\Inetpub\wwwroot\website\img\babies">
    <!--- --->
    <cfif len(trim(form.MYFile))>
    <!--- if a file has been selected --->
    <!--- try uploading new file --->
    <cftry>
    <cffile Action="upload" filefield="MYFile" accept="image/gif,
    image/jpg, image/jpeg, image/pjpeg"
    destination="#pathToFile#" nameconflict="MAKEUNIQUE">
    <cfset fileuploaded = true>
    <cfset uploadedfile = cffile.serverfile>
    <cfcatch type="any">
    <!--- if upload did not suceed, reset file uploading vars --->
    <cfset fileuploaded = false>
    <cfset uploadedfile = "">
    <!--- this can be further enhanced by setting some var to hold error
    message and return it to user --->
    </cfcatch>
    </cftry>
    </cfif>
    <cfif form.id gt 0><!--- we are updating an existing record --->
    <!--- if new file upload was successful and the feature has an image
    associated with it - delete old image --->
    <cfif fileuploaded is true AND len(trim(form.oldimage))>
    <cfif FileExists(pathToFile & form.oldimage)>
    <cffile action="delete" file="#pathToFile & form.oldimage#">
    </cfif>
    </cfif>
    <cfquery datasource="#APPLICATION.dataSource#">
    UPDATE baby_port
    SET
    baby_port.dob=<cfqueryparam cfsqltype="CF_SQL_DATE" value="#form.edit1#">,
    baby_port.Fname=<cfqueryparam cfsqltype="cf_sql_varchar" value="#form.Name#">,
    baby_port.Lname=<cfqueryparam cfsqltype="cf_sql_varchar" value="#form.Lname#">,
    <cfif fileuploaded is true>
    baby_port.MYFile=<cfqueryparam cfsqltype="cf_sql_varchar" value="#uploadedfile#">,
    </cfif>
    baby_port.Body=<cfqueryparam cfsqltype="cf_sql_longvarchar" value="#form.PDSeditor#">,
    baby_port.weight=<cfqueryparam cfsqltype="cf_sql_varchar" value="#form.weight#">,
    baby_port.TimeB=<cfqueryparam cfsqltype="CF_SQL_TIME" value="#form.tob#">
    WHERE ID = <cfqueryparam value="#form.ID#" cfsqlType="CF_SQL_INTEGER">
    </cfquery>
    <cfelse><!--- we are inserting a new record --->
    <cfquery datasource="#APPLICATION.dataSource#">
    INSERT INTO baby_port
    (dob, Fname, Lname, MYFile, Body, weight, TimeB)
    VALUES
    (<cfqueryparam cfsqltype="CF_SQL_DATE" value="#form.edit1#">,
    <cfqueryparam cfsqltype="cf_sql_varchar" value="#form.Name#">,
    <cfqueryparam cfsqltype="cf_sql_varchar" value="#form.Lname#">,
    <cfqueryparam cfsqltype="cf_sql_varchar" value="#uploadedfile#" null="#NOT fileuploaded#">,
    <cfqueryparam cfsqltype="cf_sql_longvarchar" value="#form.PDSeditor#">,
    <cfqueryparam cfsqltype="cf_sql_varchar" value="#form.weight#">,
    <cfqueryparam cfsqltype="CF_SQL_TIME" value="#form.tob#">)
    </cfquery>
    </cfif>
    this is the 2 fields on the form that is submitting the file:
    <input type="hidden" name="oldimage" value="#MYFile#">
    <input name="MYFile" type="file" id="MYFile">
    I can make more available if you need it, I didn't want to unload a ton of code on you.This is a stand alone server running coldfusion 8.1 standard if that makes a difference, it is not a shared environment. I have this code working on shared environments.

  • Encountering error in simple file 2 file scenario

    Hi,
    Working on a very simple file 2 file scenario , where input contains 1 header record identified with a key field and detail record conntains more than 1 records identified with key field. Used very specific FCC. But it was unable to generate the output file (a simple text file without any translation) giving errors as below -
    1. File Adapter Receiver Channel cc_target: Not initialized - cannot proceed: null
    2. MP: exception caught with cause com.sap.engine.interfaces.messaging.api.exception.MessagingException: Channel has not been correctly initialized and cannot process messages
    3. Adapter Framework caught exception: Channel has not been correctly initialized and cannot process messages
    4. Delivering the message to the application using connection File_http://sap.com/xi/XI/System failed, due to: com.sap.engine.interfaces.messaging.api.exception.MessagingException: Channel has not been correctly initialized and cannot process messages.
    Input File structure is like
    H1,XXXXX
    D1,YYYYYY
    D1,ZZZZZ
    D1,NNNN
    H1 and D1 are key identifiers of header and detail record
    Need same format output file, used FCCs (1) fieldSeperator (2) endSeparator (3)ignoreRecordsetname (4) fieldNames (5) keyfieldvalue.
    Can anyone pls suggest ?
    AC

    Hi ,
    Use FCC Like this.
    Doccument Name                        MT_Source( Your Source Message Type name)
    Doccument Namespace                   http://xxxxxx(Your Message type Name space)
    Recordset Structure                   Header,1,Detail,*
    Key Field Name                        field1
    Key Field Type                        String
    Header.fieldSeparator            ','
    Header.fieldNames                field1,field2
    Header.keyFieldValue             'H1'
    Header.endSeparator              'nl'
    Detail.fieldSeparator            ','
    Detail.fieldNames                field1,field2
    Detail.keyFieldValue             'D1'
    Detail.ignoreRecordsetname        true
    Detail.endSeparator              'nl'
    Let me know if you are getting any problem.
    Thanks.

  • Problem in Simple file to file scenario

    Hello,
    I am new to SAP PI 7.3. I am doing a simple file to file scenario. The source file contains key,name,id,gender,role & location field. I have done a simple mapping to create the same file in the target side. I have done all the configuration in ESR & ID.
    But the problem is that in the target file ( Destination File ) i am getting only key field and the other fields are missing.
    Note: In communication channel monitoring, the communication channel is functioning properly and in message monitor also, the status is 'delivered'.
    The source payload also contains all the fields correctly. In message mapping (in ESR) also, the target payload is also generating correctly. But in the destination file I am getting the key field only and the rest fields are missing.
    Can you please suggest me what to do and where is the problem?
    Thanks & Regards,
    Moumita

    Hello,
    Do u have any MT name above Record node? If yes, then u have to change ur structre little bit. Check my reply in the thread pasted below.
    problems with MessageTransformBean SimpleXML2Plain
    BTW, if i am not wrong Iñaki has also suggested the same.
    Thanks
    Amit Srivastava

  • Simple (File-XI-File)scenario

    Hi,
    I am going through Venkat Donela's simpe (File-XI-File)scenario Part1 and part2.
    /people/venkat.donela/blog/2005/03/02/introduction-to-simplefile-xi-filescenario-and-complete-walk-through-for-starterspart1
    https://www.sdn.sap.com/irj/sdn/weblogs?blog=/pub/wlg/1345. [original link is broken] [original link is broken] [original link is broken] [original link is broken] [original link is broken]
    But my XI did not pick up the input file. I use SXMB_MONI and look at the message monitoring. It says "No message has been selected'. I don't see "adapter monitoring" option on my "Runtime WorkBench".
    Is there anybody could tell me how I can monitor the scenario execution? I checked the every step states in Venkat Donela's sample.
    Any comments and advice will be highly appreciated.
    Meiying

    Hi,
    The best way to check if your file is being picked is to set the "Processing Mode to Delete"....So then you will know if your file is actually being picked...
    Also go to Message Monitoring of RWB and check for the status. Because if you have content conversion problems then it will show there in MDT(Message Display Tool under Message Monitoring).
    And if you are using NFS connection for Sender File Adapter, try to check for the checkBox "ReadOnly Files".
    Pls go through the explanation of a simmilar scenario that i have explained below and compare it with what you have done..
    Please go thru the following links and clear all your doubts.
    Communication channel:
    <a href="http://help.sap.com/saphelp_nw04/helpdata/en/65/b11c409ce22402e10000000a1550b0/frameset.htm">Assigning Communication Channels</a>
    <a href="http://help.sap.com/saphelp_nw04/helpdata/en/2b/d5653fd1d3b81ae10000000a114084/content.htm">Communication Channel</a>
    <a href="http://help.sap.com/saphelp_nw04/helpdata/en/e3/94007075cae04f930cc4c034e411e1/content.htm">Configuring the Sender File/FTP Adapter</a>
    <a href="http://help.sap.com/saphelp_nw04/helpdata/en/bc/bb79d6061007419a081e58cbeaaf28/content.htm">Configuring the Receiver File/FTP Adapter</a>
    Receiver agreement:
    <a href="http://help.sap.com/saphelp_nw04/helpdata/en/56/02e63f48e58f15e10000000a155106/frameset.htm">Receiver Agreement</a>
    <a href="http://help.sap.com/saphelp_nw04/helpdata/en/c1/5194426b44c56ae10000000a155106/frameset.htm">Creating a Receiver Agreement</a>
    Sender agreement:
    <a href="http://help.sap.com/saphelp_nw04/helpdata/en/db/73e03fc2269615e10000000a155106/frameset.htm">Sender Agreement</a>
    <a href="http://help.sap.com/saphelp_nw04/helpdata/en/22/522041cfb7f423e10000000a155106/frameset.htm">Creating a Sender Agreement</a>
    For detailed info, I would suggest that you go through these weblogs:
    <a href="/people/venkat.donela/blog/2005/03/02/introduction-to-simplefile-xi-filescenario-and-complete-walk-through-for-starterspart1">Introduction to simple(File-XI-File)scenario for Starters</a>
    <a href="/people/venkat.donela/blog/2005/03/03/introduction-to-simple-file-xi-filescenario-and-complete-walk-through-for-starterspart2">Introduction to simple (File-XI-File)scenario for starters part2</a>
    I hope it helps.
    Regards,
    Abhy
    Message was edited by: Abhy Thomas

  • Help with simple file to file BPM scenario

    Hi Gurus,
    I am doing simple file to file BPM scenario.
    I am getting an error in SXI_CACHE with status code 99.
    I activated the business process then status code changed to 2.
    When i tried to activate the process again i am getting prompted to enter access key details.
    Is there any other way to get rid of the error i.e., to get the status code to zero with giving access key details.Sample access key details are also greatly appreciated.

    Hi Bhavesh,
    I tried doing that but of no use.
    I registered at https://websmp230.sap-ag.de/sap(bD1lbiZjPTAwMQ==)/bc/bsp/spn/minisap/minisap.htm
    and got a mail with details.I was actually looking for access key details in the mail from sap.The details in the mail contains License key but not access key .Are the both access key and license key same?

  • Restricted access Simple File Deployment

    Hello,
    I have installed CPS on tomcat on a Windows testing box. I've
    configured it and Contribute to use a stagging server.
    Everything is working great. However, on the web page for the
    Simple File Deployment service (
    http://<server:<port>/.../customservices/filedeployer/>
    for testing purposes I'm not using SSL - is that required?) anyone
    can access this page. Well I want to limit that to only a few.
    Right now I'm using the File-bases authentication model.
    Reading the contribute publishing services manual I read:
    "When you extend this service, consider adding the following
    functionality:
    • Authentication and permissions
    You can add authentication functionality to limit access to
    the service.
    Tip: Macromedia strongly recommends that you add
    authentication. To do so, you can simply
    copy the settings file and save it as a separate service in a
    subfolder for each website, or you can
    write you own security interface to handle multiple
    websites."
    I'm confushed by this. 1) what settings file? I have two
    types of settings.xml files (one for determing live and staging
    servers and another that has info for webservers, approvals and
    etc.) but they dont have any authenticaion info for CPS server.
    2) what folders on what server is the above statement
    refering to?
    Thank you very much.

    I believe you need ColdFusion for Simple File Deployment and
    the other options you mention - VERY expensive. For publishing, use
    RoboCopy - it's free.

  • Cache Error in simple file to file scenario

    Hi,
    I installed a new xi with SP9 yesterday, and created a simple file to file scenario, but I face the error as follows while checking the SXMB_MONI,
    Error Category : XICACHE
    Error ID : UPDATE
    - <SAP:Error xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="">
      <SAP:Category>XIServer</SAP:Category>
      <SAP:Code area="XICACHE">UPDATE</SAP:Code>
      <SAP:P1 />
      <SAP:P2 />
      <SAP:P3 />
      <SAP:P4 />
      <SAP:AdditionalText>HTTP status code401 Unauthorized</SAP:AdditionalText>
      <SAP:ApplicationFaultMessage namespace="" />
      <SAP:Stack>An error occurred when refreshing the XI runtime cache</SAP:Stack>
      <SAP:Retry>M</SAP:Retry>
      </SAP:Error>
    What can be the problem?
    Regards,
    Nick

    Thanks Chandra,
    But this did not solve my problem.
    I am getting this error message:
    <?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
    - <!--  Call Adapter
      -->
    - <SAP:Error xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="">
      <SAP:Category>XIServer</SAP:Category>
      <SAP:Code area="INTERNAL">AE_DETAILS_GET_ERROR</SAP:Code>
      <SAP:P1>af.arb.dl380a-wm\arbdb</SAP:P1>
      <SAP:P2 />
      <SAP:P3 />
      <SAP:P4 />
      <SAP:AdditionalText>2: Unable to find URL for Adapter Engine af.arb.dl380a-wm</SAP:AdditionalText>
      <SAP:ApplicationFaultMessage namespace="" />
      <SAP:Stack>Error when reading the access data (URL, user, password) for the Adapter Engine af.arb.dl380a-wm\arbdb</SAP:Stack>
      <SAP:Retry>M</SAP:Retry>
      </SAP:Error>
    <Trace level="1" type="B" name="PLSRV_CALL_ADAPTER" />
    - <!--  ************************************
      -->
      <Trace level="1" type="Timestamp">2005-12-28T04:00:48Z CET Start of pipeline service processing PLSRVID= PLSRV_CALL_ADAPTER</Trace>
      <Trace level="1" type="B" name="CL_XMS_MAIN-CALL_PLSRV" />
    - <!--  ************************************
      -->
      <Trace level="3" type="T">Calling pipeline service: PLSRV_CALL_ADAPTER</Trace>
      <Trace level="3" type="T">Reading Pipeline-Service specification...</Trace>
      <Trace level="3" type="T" />
      <Trace level="3" type="T">Pipeline service specification (table SXMSPLSRV)</Trace>
      <Trace level="3" type="T">PLSRVID = PLSRV_CALL_ADAPTER</Trace>
      <Trace level="3" type="T">PLSRVTYPE = =SWITCH=</Trace>
      <Trace level="3" type="T">ADRESSMOD = SD</Trace>
      <Trace level="3" type="T">P_CLASS =</Trace>
      <Trace level="3" type="T">P_IFNAME =</Trace>
      <Trace level="3" type="T">P_METHOD =</Trace>
      <Trace level="3" type="T">FL_LOG =</Trace>
      <Trace level="3" type="T">FL_DUMMY = 0</Trace>
      <Trace level="3" type="T" />
      <Trace level="3" type="T">Unknown channel type: File</Trace>
      <Trace level="3" type="T" />
      <Trace level="3" type="T">Pipeline service specification (table SXMSPLSRV)</Trace>
      <Trace level="3" type="T">PLSRVID = PLSRV_CALL_ADAPTER</Trace>
      <Trace level="3" type="T">PLSRVTYPE = AENGINE</Trace>
      <Trace level="3" type="T">ADRESSMOD = SD</Trace>
      <Trace level="3" type="T">P_CLASS = CL_XMS_PLSRV_IE_ADAPTER</Trace>
      <Trace level="3" type="T">P_IFNAME = IF_XMS_PLSRV</Trace>
      <Trace level="3" type="T">P_METHOD = ENTER_PLSRV</Trace>
      <Trace level="3" type="T">FL_LOG =</Trace>
      <Trace level="3" type="T">FL_DUMMY = 0</Trace>
      <Trace level="3" type="T" />
      <Trace level="1" type="B" name="CL_XMS_MAIN-CALL_PLSRV_LOCAL" />
    It seems my adapter engine has some problem, how can I solve it?
    Regards,
    Nick

  • Simple File Sharing in Windows XP

    The simple file sharing that is automatically turned on in XP is
    causing some problems with programs we run. An administrator can turn
    it off, but as soon as any user logs onto the machine, the setting in
    re-enabled. It would seem that the novell client or more likely Group
    Policies set through the Workstation manager is turning it back on but
    we cannot find where to change the setting. What can we do to turn
    simple file sharing off and have it stay off for all users.
    Thanks
    Matthew McNicholas
    PEDCO E & A Services Inc.

    It looks like we had that setting correct the whole time except the
    Security Setting check box was not checked. We're getting close! For
    administrators it works great, simple file sharing is turned off when
    they logon. However, the power users are still not able to change this
    setting I think because of security access (when they logon the setting
    never changes but the same change was made in thier policy package as
    the admin package).
    I thought maybe I could add the power users to another group to grant
    them access to change that setting, but I don't want to give them
    access they don't need. I saw that in C1 you can create custom groups
    though dynamic local users. I went to add privileges to a custom
    group, but there are no descriptions of what each privilege actually
    gives the user. I could not find an explaination on novell's website
    or in the help file. This may not work at all but right now I'm in a
    trial and error situation. If anyone knows what privilege to add or
    where to find descriptions of them, please let me know.
    Or if you happen to know another reason why administrators might work
    and power users don't, please let me know that also.
    Thanks
    Matthew McNicholas
    PEDCo E & A Services
    Rolf Lidvall wrote:
    > > One of the web pages you refered to says the
    > > following..."ForceGuest is enabled by default, but can be disabled
    > > on Windows XP Professional by disabling the local security policy
    > > Network Access: Force Network Logons using Local Accounts to
    > > Authenticate as Guest". I cannot find this setting in the mmc.
    > > Does anyone know how to add it or where to find it?
    >
    > Matthew, great, I should read my own tips ;-)
    >
    > I did not know about this setting, I was wrong, it IS
    > a Group Policy setting. I am at home now and have only
    > a Swedish WinXP, so it might not be the exact English:
    > Edit a WS Group Policy in C1, check Security Settings, go to:
    > Computer Configuration -> Security Settings -> Local Policies
    > -> Security Options ->
    > Network Access: Sharing and Security Model for Local Accounts
    > (or something similar to that)
    > Duuble-Click on that and now you will get a Drop-Down-List
    > with the setting.
    >
    > Does that work?
    >
    > Regards
    > Rolf Lidvall
    > Swedish Radio (Ltd)

  • Simple File Item

    Hi,
    I am new to portal development, and i need to add some links in a page , so that clicking the link download a file, i used a simple file item, but i need to know how to prevent the user from downloading if he is a public user and hasn'y yet logged in.
    i want to display a message " you have to login in first" or redirect him to the login page

    You can use Enable item level security,
    Page properties >> Access tab >> check the box 'Enable Item Level Security'.
    Then, Edit file item >> Access tab >> grant the required access.
    Thanks,
    Krishna

Maybe you are looking for