Search Results

Search found 10374 results on 415 pages for 'close'.

Page 19/415 | < Previous Page | 15 16 17 18 19 20 21 22 23 24 25 26  | Next Page >

  • How can I forcibly close a TcpListener

    - by Nissim
    I have a service which communicates through tcpListener. Problem is when the user restarts the service - an "Address already in use" exception is thrown, and the service cannot be started for a couple of minutes or so. Is there's any way of telling the system to terminate the old connection so I can open a new one? (I can't just use random ports because there is no way for the service to notify the clients what is the port, so we must depend on a predefined port)

    Read the article

  • Hold the command prompt until user close it from close button.

    - by Kasun
    Hi, I going to get the command prompt from my C# application to compile some C++ files. Code is like this. private void button1_Click(object sender, EventArgs e) { string filePath = @"C:\Program Files\Microsoft Visual Studio 9.0\VC\bin\cl.exe"; System.Diagnostics.Process.Start(filePath); } But After i click the button it suddenly comes and disappear. Even its opening two command prompts. I need to Hold it and only one command prompt should appear. Can some one provide me the necessary codes. Thank you.

    Read the article

  • Force close Android application Phone.apk in landscape mode

    - by user1277086
    Standard Android application Phone.apk with an outgoing call on the tenth of a second can use the landscape screen mode, but if you make a modification of graphic resources, in landscape mode the phone is closed with an error, Eclipse shows it - E / AndroidRuntime (2888): java.lang.RuntimeException: Unable to start activity ComponentInfo {com.android.phone / com.android.phone.InCallScreen}: java.lang.ClassCastException: android.view.AbsSavedState $ 1. I tried to set the AndroidManifest.xml setting [android: screenOrientation = "portrait"] of the article "Force an android activity to always use landscape mode" - the application falls. What can I try to do more? I tried to add a variable to a string android:screenOrientation="portrait" in decompiled Phone.apk on the and

    Read the article

  • Close all HTML unclosed IMG tags

    - by George Johnston
    Is it possible to do a regex replace on all IMG tags that are unclosed? If so, how would I identify: <img src="..." alt="..."> ...as a potential canidate to be replaced? = <img src="..." alt="..."/> Update: We have hundreds of pages, and thousands of image tags, all must of which must be closed. I'm not stuck on RegEx -- any other method, aside from manually updating all IMG tags, would suffice.

    Read the article

  • how do i close a frame yet open a new frame?(revisited)

    - by altvali
    I'm new at Java and I'm trying to do what the title says, my application has page A, a jpanel with some controls and a specific button, and when the user clicks the button i want page A to disappear and page B to appear (page B has controls that depend on the choices that are made by the user on page A). This has been asked before but there was no satisfactory answer. In the ActionListener implementation, namely public void ActionPerformed(ActionEvent e) from my jpanelForPageA class i can comfortably write this.setVisible(false), but how can i set page B to a visible state?

    Read the article

  • jquery, position 'close icon' div in the top right of a large image

    - by Blankman
    My webpage has a large image (a map). I want to position, at the top right of the image, a small icon that is for closing the map. How can I figure out the position and place the image appropriately? The image has a fixed width of 900 x 600. I have jquery on the page if that helps. I tried using $("#map").position and I have the top and left, but not sure how to position to the top right.

    Read the article

  • Android & Google Maps - close info window with back button

    - by m4ch3t3
    I have an activity that holds a fragment with Google Map view in it. App adds several dozens of markers to the MapView, using MarkerManager and ClusterRenderer to form clusters. The problem is that when I have marker's InfoWindow opened and I press hardware Back button, it closes the app. Instead of that, I would like to have the InfoWindow closed. Is there any straightforward way to achieve this?

    Read the article

  • Clear Absolute Cache on Application close Ipad app

    - by geeth
    I am saving Images in NSCachesDirectory in a App. At the end of app execution i would like to clear all temporary cache. Is there a way to force clear all cache on application exit. I do realise the local folder keeps cache for 3 days..but my requirement is to force clear the Cache. Thx

    Read the article

  • Close button closes application behind the actual one. What is the problem?

    - by user34878
    Occasionally when I hit the close button ('x' on the left) instead of closing the application I am looking at, it closes another application. A very common example situation: I am using Firefox, and then I open the Trash directory (because Unity sux and make me click the trash icon in the auto-hide menu every time). Then I click in the close button and the trash do not go away, but Firefox does. How can I work around this problem?

    Read the article

  • Get div and the correct close tag preg

    - by Barkermn01
    hi all, Now preg has always been a tool to me that i like but i cant figure out for the life if me if what i want to do is possible let and how to do it is going over my head What i want is preg_match to be able to return me a div's innerHTML the problem is the div im tring to read has more divs in it and my preg keeps closing on the first tag it find Here is my Actual code $scrape_address = "http://isohunt.com/torrent_details/133831593/98e034bd6382e0f4ecaa9fe2b5eac01614edc3c6?tab=summary"; $ch = curl_init($scrape_address); curl_setopt ($ch, CURLOPT_RETURNTRANSFER, '1'); curl_setopt($ch, CURLOPT_HEADER, 0); curl_setopt($ch, CURLOPT_ENCODING, ""); $data = curl_exec($ch); preg_match('% <div id="torrent_details">(.*)</div> %six', $data, $match); print_r($match); This has been updated for TomcatExodus's help Live at :: http://megatorrentz.com/beta/details.php?hash=98e034bd6382e0f4ecaa9fe2b5eac01614edc3c6

    Read the article

  • Close child form if already open

    - by j-t-s
    Hi All How can I go about closing a Child form if it's already open? And if it isn't already open, then open it? Thank you I already have this code, which doesn't work, obviously: Form ibx = new inbox(); if(ibx.Visible) ibx.Dispose(); else ibx.Show(); All that the above does is creates a new form whether or not it's already open.

    Read the article

  • Why do I need to close fds when reading and writing to the pipe?

    - by valentimsousa
    However, what if one of my processes needs to continuously write to the pipe while the other pipe needs to read? This example seems to work only for one write and one read. I need multi read and write void executarComandoURJTAG(int newSock) { int input[2], output[2], estado, d; pid_t pid; char buffer[256]; char linha[1024]; pipe(input); pipe(output); pid = fork(); if (pid == 0) {// child close(0); close(1); close(2); dup2(input[0], 0); dup2(output[1], 1); dup2(output[1], 2); close(input[1]); close(output[0]); execlp("jtag", "jtag", NULL); } else { // parent close(input[0]); close(output[1]); do { read(newSock, linha, 1024); /* Escreve o buffer no pipe */ write(input[1], linha, strlen(linha)); close(input[1]); while ((d = read(output[0], buffer, 255))) { //buffer[d] = '\0'; write(newSock, buffer, strlen(buffer)); puts(buffer); } write(newSock, "END", 4); } while (strcmp(linha, "quit") != 0); } }

    Read the article

  • How can I stop my application?

    - by Roman
    I have the main thread from which I start a window using invokeLater. I run my application from command line. So, when application is running I see the window and my command line is "blocked" by the application. I can stop the application either by closing the window (as a result the command line is unblocked) or by typing Ctrl-C in the command line (as a result the window disappear). I wanted to be able to stop the application by clicking on a button in the window of the application. I used setVisible(false) for that. But in this way I can achieve the goal only partially. My window really disappear but the command line is still blocked. So, the software is still running. Well, I assume it's because some other threads are still running. But how can I easily close all these threads (like I do by closing the window of the application manually).

    Read the article

  • C#/.NET: Closing another process outside the main window

    - by eibhrum
    Hi, I just wanna ask your opinion/suggestion on how to 'terminate' a running application/process is C# Right now, I do have the following codes: Process myProcess; private void btnOpen_Click(object sender, RoutedEventArgs e) { DirectoryInfo di = new DirectoryInfo(System.Environment.GetFolderPath(Environment.SpecialFolder.Programs)); myProcess = Process.Start(di + @"\Wosk\Wosk.appref-ms"); // opening a file coming for Startup Menu } private void btnClose_Click(object sender, RoutedEventArgs e) { myProcess.Kill(); // not working - Cannot process request because the process has exited } I also tried myProcess.Close(); but nothing's happening.

    Read the article

  • disable javascript popup on refreshing page

    - by vatismarty
    Hi all, I have written code like this to throw a pop up when my website is closed. But this throws the pop up even if i refresh my page. Please help me to throw popup only when i close the browser of that website. (disable popup on refreshing page) <body onunload="javascript: exitpop()"> <script type="text/javascript"> function exitpop() { my_window= window.open ("","mywindow1","status=1,width=600,height=400"); my_window.document.write('<h1>My Team</h1><p>Thank you</p><p>If you accidentally closed website click <a href="http://www.google.com">here</a> to go back to our website</p>'); }.

    Read the article

  • javascript popup on refreshing page

    - by vatismarty
    I have written code like this to throw a pop up when my website is closed. But this throws the pop up even if i refresh my page. Please help me to throw popup only when i close the browser of that website. <body onunload="javascript: exitpop()"> <script type="text/javascript"> function exitpop() { my_window= window.open ("","mywindow1","status=1,width=600,height=400"); my_window.document.write('<h1>My Team</h1><p>Thank you</p><p>If you accidentally closed website click <a href="http://www.google.com">here</a> to go back to our website</p>'); }.

    Read the article

  • How to emulate pressing the Close button from a script?

    - by Karthik
    I wanted Thunderbird to stay in the Background to notify me of incoming mails. After a bit of searching, I found this post. How to keep Thunderbird and Pidgin running on background? The solution is to install an addon so that when we close Thunderbird it just stays in the background. Now, to have thunderbird running at Start up we can just add it to Startup Applications. But, when I open my system, Thunderbird also gets opened and I have to manually press the close button everytime to make Thunderbird go into the background. The solution given in the above post for this problem is to select Minimize on start. But doing so affects the way in which Thunderbird works when invoked from the Messaging menu. So I deselected this option. But, if there is a way to emulate pressing the Close button from a script, I can just add that script to Startup Applications So is there a way to achieve this? Note : If there is a simpler way to solve my original problem of keeping Thunderbird in background please post that also. Many thanks.

    Read the article

  • Closing Windows Forms on a Touchscreen

    - by drharris
    Our clients have fat fingers, and so do we. We take touchscreen netbooks apart to insert them into our custom hardware, and I write a software interface that shows up on the touchscreen. The problem is that it has about a 3/4" bezel over the screen, which means hitting that little red "X" becomes a challenge, especially considering reduced capacitive ability on the edges and corners. Is there a way to make this standard close button larger? Of course in the application I can always make really nice 80x80 buttons that are perfectly usable, but there seems to be no way to override the default frame of the form. We have tried enabling Large Fonts and all the built-in accessibility features, but nothing seems to make it large enough to hit successfully. Simply adding a toolbar button is also not much of an option. We prefer to utilize the standard look and feel of a normal Windows application. Alternatively, should we be looking at making some sort of "kiosk mode" where we simply go fullscreen and do nothing involving the taskbar or title bar? How difficult is this to accomplish, if so?

    Read the article

  • What can cause a spontaneous EPIPE error without either end calling close() or crashing?

    - by Hongli
    I have an application that consists of two processes (let's call them A and B), connected to each other through Unix domain sockets. Most of the time it works fine, but some users report the following behavior: A sends a request to B. This works. A now starts reading the reply from B. B sends a reply to A. The corresponding write() call returns an EPIPE error, and as a result B close() the socket. However, A did not close() the socket, nor did it crash. A's read() call returns 0, indicating end-of-file. A thinks that B prematurely closed the connection. Users have also reported variations of this behavior, e.g.: A sends a request to B. This works partially, but before the entire request is sent A's write() call returns EPIPE, and as a result A close() the socket. However B did not close() the socket, nor did it crash. B reads a partial request and then suddenly gets an EOF. The problem is I cannot reproduce this behavior locally at all. I've tried OS X and Linux. The users are on a variety of systems, mostly OS X and Linux. Things that I've already tried and considered: Double close() bugs (close() is called twice on the same file descriptor): probably not as that would result in EBADF errors, but I haven't seen them. Increasing the maximum file descriptor limit. One user reported that this worked for him, the rest reported that it did not. What else can possibly cause behavior like this? I know for certain that neither A nor B close() the socket prematurely, and I know for certain that neither of them have crashed because both A and B were able to report the error. It is as if the kernel suddenly decided to pull the plug from the socket for some reason.

    Read the article

  • bluetooth BluetoothSocket.connect() thread. how to close this thread

    - by Hia
    I am trying to make an android app that makes connection with bluetooth device. It works fine but when I call BluetoothSocket.connect() and it is not able to connect to devise its blocking. The thread and does not throw any exception. So when I try to close application while connect() is running its not responding. How can I cancel it? Used BluetoothSocket.close() in ... but still its not working for me. protected void simpleComm(Integer port) { // The documents tell us to cancel the discovery process. try { Method m = mmDevice.getClass().getMethod("createRfcommSocket", new Class[] { int.class }); mmSocket = (BluetoothSocket) m.invoke(mmDevice, port); mmSocket.connect(); // <== blocks untill is not connected Log.d(TAG, " connection success==="); }catch(Exception e){ if (!abort) { connectionFailed(); // Close the socket try { mmSocket.close(); // Start the service over to restart listening mode BluetoothService.this.start(); } catch (IOException e2) { Log.e(TAG,"unable to close() socket during connection failure", e2); } } return; } } public void cancel() { try { abort = true; mmSocket.close(); } catch (IOException e) { Log.e(TAG, "close() of connect socket failed", e); } }

    Read the article

< Previous Page | 15 16 17 18 19 20 21 22 23 24 25 26  | Next Page >