connect

Tuning socket connect call timeout

Is there any way in a Win32 environment to "tune" the timeout on a socket connect() call? Specifically, I would like to increase the timeout length. The sockets in use are non-blocking. Thanks! ...

I can't connect KAction to slot on KMainWindow

I have a KMainWindow: //file.h class MainWindow: public KMainWindow { public: MainWindow(QWidget *parent = 0); ... ... ... private slots: void removeClick(); //file.cpp MainWindow::MainWindow(QWidget *parent) : KMainWindow(parent) {} void MainWindow::removeClick() { std::cout << "Remove" << std::endl; } I can c...

System.Net's Webclient in C# won't connect to server.

Is there something I need to do to get System.Net working with Microsoft Visual C# 2008 Express Edition? I can't seem to get any web type controls or classes to work at all.. the below WebClient example always throws the exception "Unable to connect to the remote server".. and consequently I can't get the WebBrowser control to load a pag...

How do I set the time out of a socket.connect() call?

I have an app that connects to a host that might be down. If the host is down I don't want to wait for the 30 or so seconds it takes to time out. I'm using blocking sockets at the moment. I've been looking at socket.poll() and socket.select() but I'd rather just have a time setting on the socket. I don't mind if it's a setting I have to...

Ftp connection problem

I have an application implemented with BackgroundWorker that periodically connects to ftp (for download and upload) using LumiSoft library. It works just fine but after a while (let's say 2 - 3 hours) the thread (backgroundworker) blocks under the Connect method (witch doesn't throw any exception). Here is the part of code that fails: ...

Having Issues Connecting to Microsoft SQL Server Express (2008) from PHP

As the title says, I'm having issues connecting to MSSQL from a PHP Script. The setup:- PHP is running on an Apache Linux Server. Microsoft SQL Server 2008 is on an XP Machine. I've got Remote Connections turned on in the MSSQL Server. The database bggs does exist. The database is running (I can see a green arrow). I have no firewall ...

How is an error reported from async socket connect?

I'm connecting a socket asynchronously (O_NONBLOCK + connect). POSIX standard specifies that after socket has been connected is should signal the event by making the file descriptor for the socket ready for writing. It doesn't seem to say anything about failures during async connect. When testing it on Linux, it seems that sometimes I'm...

Remote mysql connection

Hi, I'd been making a web on localhost and when I tried to move it on host it shows me lots of errors. Seems like it can't connect to my local database. Here's the code: $host = "myip"; $user = "root"; $pass = ""; $db = "mydatabase"; mysql_connect($host, $user, $pass); mysql_select_db($db); $on = mysql_fetch_row(mysql_query("SELECT COU...

connect tables with ODBC

to connect multiple tables in oracle with ODBC do we need to create different DSN for different tables ...

Why can't I connect to my sql database? I get the error message: "Can't connect to local MySQL server through socket"

I just moved my site to a new web host, and after changing the database-login file, it still can't connect. I get the following error: Warning: mysql_query() [function.mysql-query]: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2) in /usr/www/users/simpleof/index.php on line 91 I changed the password and tried a...

C# How do I stop a tcpClient.Connect() process when i'm ready for the program to end? It just sits there for like 10 seconds!

This is one of my first issues. Whenever I exit out the program, tcpClient.Connect() takes forever to close. I've tried a ton of things, and none of them seem to work. Take a look at the CreateConnection() thread, if the client isn't connected yet... and I close the program, it takes forever to close. If it IS connected, it closes immed...

i hav php5.2.9 +mysql5.1+apache2.2.6 installed on win xp .iam not able get php connect with mysql .

i have php5.2.9 +mysql5.1+apache2.2.6 installed on win xp. I'm not able get php connect with mysql. here is the code.` <? php $link=mysql_connect('localhost','root','godismine'); if(!$link) echo "fail"; else echo "success"; mysql_close(); ?> i don't think there is any error in code. phpinfo is showing mysql support so it can...

Non-blocking connect() with WinSocks

According to MSDN you have to create a non-blocking socket like this: unsigned nonblocking = 1; ioctlsocket(s, FIONBIO, and use it in the write-fdset for select() after that. To check if the connection was successful, you have to see if the socket is writeable. However, the MSDN-article does not describe how to check for errors. How ...

jQuery/Javascript - How to fire an event when a button's value is changed?

I am working on a plugin for jQuery that will essentially style certain elements. Like jqTransform I could just replace the element but I chose to position the real element off screen and make a new element thats styled. This allows triggering the actual events of the real element. Also, if an onclick handler or onchange handler for a te...

How to view/change socket connection timeout on Linux?

When creating a Socket in Java: new Socket(host, port); The Socket constructor will try to connect to host:port before returning. On Windows, this fails almost immediately for unreachable hosts but for Linux it can take up to 5 minutes for the Socket to timeout. I'm aware that if I have control over creating the Sockets, I can do: ...

Automatically connect to a DB in a swing application

Hello, I m working on a single user swing application that access an hsqldb database. How can i Automatically run the DB server when a user run the application.? for example, after i finish development i will put the application into an exe file. If the exe file is distributed to multiple users. How can the DB server run and the DB b...

[IB] How to connect "File's Owner" with a button in a Toolbar?

Good morning, I just got creazy with connecting the "File' Owner" to a Button in my Toolbar. How do I do that? I only can grab the Toolbar but not the buttons inside. Anyone knows how to solve that :)? Thanks in advance! ...

How to deal with ECONNREFUSED for connect?

We have a process hanging, and the truss shows it also tries to connect but failed with error ECONNREFUSED. The man page says the following, but why it got rejected again and again? ECONNREFUSED The attempt to connect was force- fully rejected. The calling program shoul...

Alternatives to CONNECT adapter to interface with NHIN network?

I'm researching alternatives to the federally backed CONNECT adapter for building a custom adapter to connect to the Nationwide Health Information Network (NHIN). Is CONNECT the only available solution, or are there other solutions as well? ...

compact-framework cannot establish connection to network error

Trying to use pocket pc emulator (vs 2008) to connect to web service on my latop. No matter what I try I can't connect. I am using my laptop's IP address in the url. It works great from the url on my laptop, I just can't get the emulator to hit it and I keep getting the " cannot establish connection to network" exception. I have googled...