473,385 Members | 1,474 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Please Help: how to connect using specific IP address

Hi everyone I don't know if I am posting this to the right newsgroup but it
is the closest I found, in case you think you can advice me to another
newsgroup please feel free to
do so. I am so desperate to get my problem solved.

The issue is related to sockets and networking this is my problem

short version:
I need to connect to an application using a specific IP, i.e. the server I
will connect to will see that specific IP address
how can I do that in .NET any help please.
----------------------------------------

Detailed version:
I have to build two applications(GenericCustomers.exe and
PremiumCustomers.exe) they will run on the same server
both applications will connect to one server (MainBase) across the Internet
using the same port number 1323
we have two external IP addresses i.e.(Internet IP address) and pointing by
the router to the my server where my applications are running
I need GenericCustomers.exe when connecting the MainBase should use one
external IP address while PremiumCustomers.exe should connect using the
other external IP address.

The MainBase server recognizes applications by their external IP address
which have to be registered in it's database

I can not run each of them on a separate server neither I can use different
port number (otherwise it can be solved by the router)
I am using C# and visual Studio 2005

What I see is that the application when attempts to connect should
initialize the socket with the IP address that I want to start the
connection with
I can not see this as impossible (think of the router applications that do
all the NAT)
but I did not see anything that help in the socket class nor on the Connect
method..
----------------------------------------

guys anyone have encountered such need or can solve this .. please write
back
Aug 19 '07 #1
3 3285
If it were me, I'd write one set of base code, implement WCF, and expose the
"Service" as 2 seperate endpoints.

Search WCF and "endpoint" and you'll find stuff.

There is a book "Programming WCF Services" by Juval Lowry, that I'd
recommend.

"Abdulla Herzallah" <ah@herz.dkwrote in message
news:eR**************@TK2MSFTNGP04.phx.gbl...
Hi everyone I don't know if I am posting this to the right newsgroup but
it
is the closest I found, in case you think you can advice me to another
newsgroup please feel free to
do so. I am so desperate to get my problem solved.

The issue is related to sockets and networking this is my problem

short version:
I need to connect to an application using a specific IP, i.e. the server I
will connect to will see that specific IP address
how can I do that in .NET any help please.
----------------------------------------

Detailed version:
I have to build two applications(GenericCustomers.exe and
PremiumCustomers.exe) they will run on the same server
both applications will connect to one server (MainBase) across the
Internet
using the same port number 1323
we have two external IP addresses i.e.(Internet IP address) and pointing
by
the router to the my server where my applications are running
I need GenericCustomers.exe when connecting the MainBase should use one
external IP address while PremiumCustomers.exe should connect using the
other external IP address.

The MainBase server recognizes applications by their external IP address
which have to be registered in it's database

I can not run each of them on a separate server neither I can use
different
port number (otherwise it can be solved by the router)
I am using C# and visual Studio 2005

What I see is that the application when attempts to connect should
initialize the socket with the IP address that I want to start the
connection with
I can not see this as impossible (think of the router applications that do
all the NAT)
but I did not see anything that help in the socket class nor on the
Connect
method..
----------------------------------------

guys anyone have encountered such need or can solve this .. please write
back


Aug 19 '07 #2
You ever hear of cross posting to several NG(s) with the same post at one
time? It's rude to go to each individual NG and make the same post.

Aug 19 '07 #3
Thank you for your valuable input, my apologies, I was not aware of this,
and I was/still am in a desperate situation.

I will remember that next time.

"Mr. Arnold" <MR. Ar****@Arnold.comwrote in message
news:eT**************@TK2MSFTNGP03.phx.gbl...
You ever hear of cross posting to several NG(s) with the same post at one
time? It's rude to go to each individual NG and make the same post.

Aug 20 '07 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: 0k | last post by:
Hi everyone, I am trying to write a small app that sends multicast udp packets using a socket object. I have more than one NIC on my PC and the following code works OK only if I disable all the...
4
by: Skully Matjas | last post by:
I am using the following code (created by the wizard) to allow to bring my form to a particular entery. But when I edit the entery (ex: put new information into a blank cell), it puts that record...
9
by: AA | last post by:
This is making me crazy!! Please, if some body can help me. I'm testing a ver simple socket client. In my test I just open and close a connection (in a loop) to my local IIS server (port 80)...
15
by: DavidS | last post by:
Have Visual Studio.NET installed on MS 2000 Professional OS laptop. No issue ever with web development and SQL connections. Purchased new laptop with XP Professional SP2!!!!!!!! & Visual...
1
by: David Van D | last post by:
Hi there, A few weeks until I begin my journey towards a degree in Computer Science at Canterbury University in New Zealand, Anyway the course tutors are going to be teaching us JAVA wth bluej...
0
by: George L. Sexton | last post by:
MH Software, Inc. is pleased to announce the release of version 3.2.11 of its Connect Daily web calendar software. This is primarily a small feature release with a few bug fixes. Topics in this...
14
by: Marcus | last post by:
I have a function that simply returns TRUE if it can connect to a particular Sql Server 2005 express, or FALSE if it cannot. I am getting some strange error codes returned when the computer that...
5
by: ranishobha21 | last post by:
Dear all, i want to send some unix commands to remote unix machine in france through php.i am using socket communication in php, i have written a socket communication program so that it...
1
by: Abdulla Herzallah | last post by:
Hi everyone I don't know if I am posting this to the right newsgroup but it is the closest I found, in case you think you can advice me to another newsgroup please feel free to do so. I am so...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.