The mkdir() function in java returning false. Why?

I am trying to create the folder archive under the following directory structure:
E:/preweb/CATest/DL/Zipra Internal/EventCompletion/html/archive/
using the boolean mkdir() function in java.
Though the folder archive does not exist under html folder, still the function is returning false.
Canm someone let me know why?

And you have checked that by using
File file =// E:/preweb/CATest/DL/Zipra Internal/EventCompletion/html/archive/
Sys.out.println( file.getParentFile().exists() );

Similar Messages

  • How to delete multiple songs from iPhone 5S without losing form iTunes? The unchek function has not worked. Why?

    How to delete multiple songs from iPhone 5S without losing form iTunes? The unchek function has not worked. Why?

    Sorry I had to reply through your profile Gail from Maine, my PC has java issues. In any event, when I delete them directly from my device everything is perfect and cool. However, in the rare instance I want to add new music that I actually buy in stores (I know, quite the unique and old-fashioned idea...but hey Im an audiophile) once I upload the tunes, everytime I sync my library it re-adds everything that I spent hours deleting. In a perfect world, I thought I could maintain a massive iTunes Library, and add or delete (remove) songs from my iPhone to save both memory or keep my iPhone selections more current/apt to my musical "tastes" at that time. I know about the whole playlist thing, but thought there might be an easier way. ie - checking/un-checking the little box next to the song name, and then doing a sync. Again, everytime I do this however, whether everything is checked or un-checked it adds the entire library! So frustrating. Any suggestions. Thank you graiously in advance for your help.

  • The InitCVIRTE function is not listed in the NIDAQ function reference online help? Why? and where can I find a description of this function?

    the InitCVIRTE function is not listed in the NIDAQ function reference online help? Why? and what does she do?and where can I find a description of this function? Can i use this function with visualc++ 6.0?

    The InitCVIRTE function is in the CVI run time engine (cvirte.dll)..not part of NI-DAQ.
    Applications written or using CVI may call this function..
    How are you running into this ?
    From the CVI help...
    This function performs initialization of the CVI Run-Time Engine. It is needed only in executables or DLLs that are linked using an external compiler. Otherwise, it is harmless.
    It should be called in your main, WinMain, or DllMain, function. The parameter values you should pass depend on which of these three functions you are calling InitCVIRTE from. The following examples show how to use InitCVIRTE in each case.
    If you are using main, your code should be as follows.
    int main (int argc, char *argv[])
    if (InitCVIRTE (0, argv, 0) == 0)
    return -1; /* out of memory */
    /* your other code */
    return 0;
    If you are using WinMain, your code should be as follows.
    int __stdcall WinMain (HINSTANCE hInstance,
    HINSTANCE hPrevInstance,
    LPSTR lpszCmdLine,
    int nCmdShow)
    if (InitCVIRTE (hInstance, 0, 0) == 0)
    return -1; /* out of memory */
    /* your other code */
    return 0;
    If you are creating a DLL, you must call InitCVIRTE and CloseCVIRTE in your DllMain function, as in the following.
    int __stdcall DllMain (void *hinstDLL, int fdwReason,
    void *lpvReserved)
    if (fdwReason == DLL_PROCESS_ATTACH)
    if (InitCVIRTE (hinstDLL, 0, 0) == 0)
    return 0; /* out of memory */
    /* your other ATTACH code */
    else if (fdwReason == DLL_PROCESS_DETACH)
    /* your other DETACH code */
    CloseCVIRTE ();
    return 1;
    NOTE: The prototype for InitCVIRTE is in cvirte.h, not
    utility.h.
    NOTE: In CVI 4.0.1, this function was expanded from one to
    three parameters. Executables and DLLs that were
    created using the one-parameter version of the function
    will continue to work properly.
    /*-------------------- Prototype ---------------------*/
    int InitCVIRTE (void *HInstance, char *Argv[], void *Reserved);
    Nandan Dharwadker
    Staff Software Engineer
    Measurement Studio Hardware Team

  • How to call the DLL functions through Java

    Hello,
    I have already got a VC++ generated DLL. It has serveral functionalities. I need to call those functions from my Java Application. Now i know that it can be possible only through writing Java JNI Interfaces.
    Everywhere i only see they give an example where in they tell to create an DLL. Now how do i will call if an DLL is ready and exists.
    If anyone can give an example then it will be very helpful to me. Please mail me at [email protected] .
    Thank you
    vvpatro

    You can't call functions in an arbitary DLL form Java. You need to use JNI to produce a 'wrapper' DLL that maps Java methods to the methods in the target DLL. The purpose of the wrapper is to allow type conversion between Java types and C/C++ types. The complexity of this task depends largely on the types used in th target DLL. If the targer DLL uses only primitive types such as char, byte, int, long, string, the translation is simple and the wrapper DLL will be 'thin'. If however, the target DLL passes arrays and objects, or employs callbacks, these more work to do, and the wrapper will be correspondingly 'thicker'.
    Hope this helps.

  • I am using QuickTime 7 Pro and want to loop my video.  The Loop function is grayed out.  Why?  How can I loop my video?

    I am using Quicktime 7 Pro on a Max Mini to play my video on a gallery monitor.  Under View, the Loop option is grayed.  Why?  I need to play the video in a continuous loop all day.  Thank you.

    Loop appears to be "broken" in QuickTime Player Pro and 10.7.4.
    It's been fixed in 10.8 and also works in QuickTime 10, 10.1 and 10.2.
    Use 10.1 on your machine if you need to loop your playback.

  • The vibration function doesn't work anymore, why?

    My iPhone won't vibrate anymore and I can't figure out why! It just stopped vibrating one day and I can't seem to figure out what went wrong. Anyone have any ideas how I can get it to work again or is it just fried? Do I need to take it in to get serviced or do I just need to get it replaced?
    HELP PLEASE!!!

    Hey SoCalSkippy,
    So when you toggle the ringer/silent switch(shows a red dot when silent) on the left side of the iPhone it does not vibrate?
    Try resetting or restoring the iPhone.
    http://docs.info.apple.com/article.html?artnum=305743
    http://docs.info.apple.com/article.html?artnum=305744
    If it still does not vibrate after a restore it may need hardware repair. You can contact AppleCare or Make a reservation to speak with a Mac Genius.
    http://www.apple.com/retail/
    U.S. iPhone technical support: 1-800-MY-IPHONE (1-800-694-7466)
    http://www.apple.com/support/contact/
    Jason

  • Where do I find the multi-function devise to return to factory settings for scanning?

    Need help in reverting to Multi Function Setting Devise to restore to Factory Settings to restore scanning function to my HP Photosmart printer.  How do I do this? Or, is there another way to get scanning function from Image Capture?

    Thank you edmester, you always show your resourcefulness and your willingness to help. You are a very valuable contributor

  • File.exists() returns false even when the file exists

    hi,
    the exists() function of java.io.File function returns false even when the file exists on the file system. why is this? i checked the path of the file which gives me the correct path, but exists returns false. can anyone help?

    post some of the code you�re using - then maybe I can help you out
    //Anders

  • BufferedReader.ready() keeps returning false using JSSE 1.0.2/jdk 1.2.2

    I'm running into difficulties reading a response data stream from a server via HTTPS. The SSL sets up fine (I can see both the client side and server side certificate chains, and the two sides can handshake and agree on a cipher (SSL_RSA_WITH_RC4_128_SHA in this case)). I get no errors getting the output or input streams from the socket, and the GET request seems to work (no errors reported by the PrintWriter), but in.ready() returns false, and the while loop exits immediately. But I know there is data available (I can paste the printed url into Netscape and get data back). Since this should not be all that complex once the SSL session is established, I'm probably missing something silly, Can someone tell me what it is please?
    Thanks
    Doug
    // code excerpt
    // just finished printing the cipher suite, cert chains, etc
    try{
    out = new PrintWriter(
    new BufferedWriter(
    new outputStreamWriter(socket.getOutputStream() )));
    } catch(Exception e) {
    System.out.println("Error getting input and output streams from socket ");
    System.out.println(e.getMessage());
    e.printStackTrace();
    throw(e);
    try{   // time to submit the request and get the data
    // build the URL to get
    // tried constructing it here and nailing it up at declaration time - no difference
    // path = "https://" + dlp.host + ":" + Integer.toString(dlp.port) + "/" +
    // dlp.basePath + "?StartDate=" + longDateFmtURL.format(dlp.startDate) +
    // "&EndDate=" + longDateFmtURL.format(dlp.endDate);
    System.out.println("Sending request for URL" );
    System.out.println(path);
    out.println("GET " + path );
    out.println();
    out.flush();
    * Make sure there were no errors
    if (out.checkError()){
    System.out.println("Error sending request to server");
    throw(new IOException("Error sending request to server")
    try{
         in = new BufferedReader(
              new InputStreamReader(
              socket.getInputStream() ));
    } catch(Exception e) {
    System.out.println("Error getting input stream from socket ");
    System.out.println(e.getMessage());
    e.printStackTrace();
    //System.exit(3);
    throw(e);
    if (!in.ready()) {   //  in.ready() keeps returning false
    System.out.println("Error - socket input stream not ready for reading");
    while ((inputLine = in.readLine()) != null) {
    // loop over and process lines if it was ever not null
    }

    Never mind.
    The problem seems to be related to the development/debugging enviroment (Oracle JDeveloper 3.2.3), When I run things outside of that eviroment using the "plain" runtime, it works as expected (back to System.out.println() for debugging). That said, I usually find it to be a nice development/debugging enviroment for Java.

  • ServletAuthentication.weak() makes isUserInRole() always return false

    I have a problem with SSO and authentification. If I authenticate with the weak()
    method(have tried alle of them) authentication works fine and it seem to be single
    signed-on, but
    if we call the isUserInRole() method it always return false.
    If I try to "call" pages from the client the declerativ security-constraints also
    works fine preventing the user from accessing the pages. It is only when we use
    the forward() method that we also use isUserInRole() to check if the user is permitted
    to be forwarded(). WLS 6.1 sp2 tells us that the user is never in Role, no matter
    what, if we use the weak() method to authenticate.
    If I switch to using a j_sec_check form to authenticate the isUserInRole() works
    fine. I can't use j_sec_check as a permanent solution though, because I need to
    do a lot of pre- and post- processing in the login/authenication process.
    Have any of you figured out a solution to this problem? Shouldn't isUserInRole()
    work the same way regardless of if you logged in using SA.weak() or a j_security_check
    form?

    Hi ,
    If I switch to using a j_sec_check form to authenticate the isUserInRole()works
    fine. I can't use j_sec_check as a permanent solution though, because Ineed to
    do a lot of pre- and post- processing in the login/authenication process.You can use the j_security_check and still do the pre and post processing as
    you want.
    You have to following code,
    package examples.servlets;
    import java.io.PrintStream;
    import javax.servlet.ServletRequest;
    import javax.servlet.ServletResponse;
    import weblogic.servlet.security.AuthFilter;
    public class AuthFilterImpl extends AuthFilter
    public AuthFilterImpl()
    System.out.println("New AuthFilterImpl has been created.");
    public void doPreAuth(ServletRequest servletrequest, ServletResponse
    servletresponse)
    System.out.println("AuthFilterImpl.doPreAuth has been called.");
    System.out.println("Password is " +
    servletrequest.getParameter("j_password"));
    public boolean doSuccessAuth(ServletRequest servletrequest,
    ServletResponse servletresponse)
    System.out.println("AuthFilterImpl.doSuccessAuth has been called.");
    return true;
    public void doFailAuth(ServletRequest servletrequest, ServletResponse
    servletresponse)
    System.out.println("AuthFilterImpl.doFailAuth has been called.");
    In your weblogic.xml have this entry,
    <weblogic-web-app>
    <auth-filter>
    examples.servlets.AuthFilterImpl
    </auth-filter>
    </weblogic-web-app>
    I am not sure about problem with SA.weak().
    -utpal
    "Morten" <[email protected]> wrote in message
    news:[email protected]...
    >
    I have a problem with SSO and authentification. If I authenticate with theweak()
    method(have tried alle of them) authentication works fine and it seem tobe single
    signed-on, but
    if we call the isUserInRole() method it always return false.
    If I try to "call" pages from the client the declerativsecurity-constraints also
    works fine preventing the user from accessing the pages. It is only whenwe use
    the forward() method that we also use isUserInRole() to check if the useris permitted
    to be forwarded(). WLS 6.1 sp2 tells us that the user is never in Role, nomatter
    what, if we use the weak() method to authenticate.
    If I switch to using a j_sec_check form to authenticate the isUserInRole()works
    fine. I can't use j_sec_check as a permanent solution though, because Ineed to
    do a lot of pre- and post- processing in the login/authenication process.
    Have any of you figured out a solution to this problem? Shouldn'tisUserInRole()
    work the same way regardless of if you logged in using SA.weak() or aj_security_check
    form?

  • Unsigned int - problem translating c++ function to java

    OK so here's the deal:
    I'm writing a client for a internet comunicator in java (J2ME to be precise). Unfortunately i have specs for this comunicator's protocol for c++ programing. The first problem I ran to is: I have to calculate a hash for a password so it doesn't go plain text on the network. The function in c++ that does this is:
    int getPasswordHash(char *password, int seed){
        unsigned int x=0, y=0, z=0;
        char *pwd = password;
        y = seed;
        for (x = 0; *password; password++) {
         x = (x & 0xffffff00) | *password;
         y ^= x;
         y += x;
         x <<= 8;
         y ^= x;
         x <<= 8;
         y -= x;
         x <<= 8;
         y ^= x;
         z = y & 0x1f;
         y = (y << z) | (y >> (32 - z));
        cout << "Hash for \"" << pwd << "\" with seed \"" << seed << "\": " << y << "\n";
        return y;
    }My translation to java goes:
    public int getPasswordHash(String password, int seed){
        long x = 0, y = 0, z = 0;
        int tmp = 0;
        String pwd = password;
        y = seed;
        for (x = 0; x < password.length(); x++){
            tmp = (int)x;
            x = x | password.charAt(tmp);
            y ^= x;
            y = uintadd(y, x);
            x <<= 8;
            y ^= x;
            x <<= 8;
            y = uintsubst(y, x);
            x <<= 8;
            y ^= x;
            z = y & 0x1f;
            y = (y << z) | (y >> (32 - z));
            x = tmp;
        System.out.println("Hash for \""+ pwd + "\" with seed \"" + seed + "\": " + y);
        return (int)y;
    public long uintadd (long x, long y){
        long xL = x & 0xffffffffL;
        long yL = y & 0xffffffffL;
        long sumL = xL + yL;
        long sum = (sumL & 0xffffffffL);
        return sum;
    public long uintsubst (long x, long y){
        long xL = x & 0xffffffffL;
        long yL = y & 0xffffffffL;
        long sumL = xL - yL;
        long sum = (sumL & 0xffffffffL);
        return sum;
    }So I use the uintadd and uintsubst to add and substract values that should be unsigned int. Every operation works exactly like in c++ (I've checked) until this point:y = (y << z) | (y >> (32 - z));and to be exact (y << z) This doesn't turn out like in c++ so the whole function doesn't return the right vaule. I know it's because doing a bit operation on a unsigned int in c++ is different in than in java because unsigned variables have totally different bit values than signed ones. The question is: how to work this out. I managed to do aritmetic operations working but I have no idea how to deal with this. Any help would be great.

    I'm by no means the expert with this, but I'm going
    to guess that this would work...
    y = ((y << z) & 0xffffffffL) | (y >> (32 - z));
    thus... to zero out the right shifted 1's before the
    orWOW WOW WOW it totaly works thanks alot bsampieri !!

  • DataLine isRunning() always returns false for mp3 files

    Running JDK 1.5.0-b64 on Win 2K and XP. Using the sun mp3 plug-in. Everything works except the DataLine.isRunning() method always returns false.
    For other file types (e.g. WAV) isRunning() returns true/false values as you might expect.
    Anybody else have this experience? It seems like a bug to me.
    Thank you.

    Running JDK 1.5.0-b64 on Win 2K and XP. Using the sun mp3 plug-in. Everything works except the DataLine.isRunning() method always returns false.
    For other file types (e.g. WAV) isRunning() returns true/false values as you might expect.
    Anybody else have this experience? It seems like a bug to me.
    Thank you.

  • Functionality of Java Gui Through Portal

    I'm running an EP 6.0 SP2 implementation (patch 5) on an AIX environments.
    Our JRE/Javagui deployment is working properly and it is loading the gui onto the end users machines once they hit a transactional iView.
    My question is around the actual functionality of Java Gui.
    I have been asked by several of our functional teams about a difference in funcctionality that apppears to exist.  This difference is as follows.
    In Windows Gui when you make a selection and select 'enter' the fields following the selection update based on the selection criterea.  In Java Gui it appears that the user has to 1) make the selection, 2) click their cursor into the box where the selection appears and then hit enter to update the selection criterea.
    Would someone please confirm that this is the way the Java Gui was meant to operate and if not suggest a way to eliminate the extra click in the operation.
    Thanks
    James

    Hi James,
    Sorry that I can't tell you how to get around this but wanted to let you know that there are differences in the Java Gui and the SAPGui in general.  Since the Java Gui is a web based implementation and the SAPGui is a client application installed on the desktop, you will get these differences.
    Not sure about Java Gui, but there are certain transactions you can't run at all from the WebGui for Microsoft browsers.  So, you are more than likely stuck with what you have!
    Hope this helps,
    Andrew

  • In a javascript function invoked from an onsubmit handler, if the function returns false, the form is still submitted. If I find an error in a form, how do I cancel the submit?

    HTML form has: action="/TTFFRP/addlicense.rex" method="get" onsubmit="validate_data();"
    validate_data is defined in tags:
    function validate_data()
    alert('in validate routine');
    if (document.getElementById('custname').value == '')
    alert('Customer name must not be blank; put in name of organization licensing File RePackager');
    return false;
    }

    Try posting at the Web Development / Standards Evangelism forum at MozillaZine. The helpers over there are more knowledgeable about web page development issues with Firefox.
    [http://forums.mozillazine.org/viewforum.php?f=25]
    You'll need to register and login to be able to post in that forum.

  • (New to C# here) What is the best way to return false in a function if it cannot be executed successfully?

    In Javascript or PHP you can have a function that could return, for example, a string in case of success and false in case of failure.
    I've noticed (in the few days I've been learning C#) that you need to define a type of value that the function will return, so you need to return that type of value but in case of failure you can't return false.
    What is the best way to achieve this behavior and is there an example I can see?
    Thank you in advance,
    Juan

    Juan, be aware that returning null won't work with value types, such as an int, which can't be null. You'd have to use a nullable value type. A nullable int would be declared with a "?", such as:
    int? someOtherFunction(int param)
    if(something goes great)
    return param * 42;
    return null;
    And you have to use it like this:
    int? result = someOtherFunction(666);
    if (result != null) // you can also use result.HasValue
    // it worked, do something with the result
    // if you're doing math with the result, no problem
    int x = result * 2;
    // but if you're assigning it to another an int, you need to use this syntax
    int y = result.Value;
    Before nullable value types came along, for a method that returned an int, I'd use a value of something that wouldn't normally be returned by that method to indicate failure, such as a -1.
    ~~Bonnie DeWitt [C# MVP]
    That's something very very important to keep in mind. Can save you from a lot of headaches!
    So if you have an int function and it might return NULL, if you are doing Math with the return value you can use it directly, but if you're assigning it to another variable you have to use .Value?
    Thanks

Maybe you are looking for