Send Data To Multiple IPs With TCP/IP Sockets?

Nov 6, 2009

I have an array of IP addresses, and I want to send the same data to all of them. I could just send the loop code that sends data but I think there's a better way of doing this.

View 1 Replies


ADVERTISEMENT

Send And Receive Data Through Sockets?

Dec 3, 2008

I'm completely new to sockets etc.I'm trying to create an app that'll allow someone to send short information messages to several other people with the same app, using the internet and sockets(?)I've tried using code from online, but I'm getting no where.

View 4 Replies

Windows Service - Using Sockets To Send / Receive Data

Jul 27, 2009

I have written a windows service that uses sockets to send receive data, it works fine when the server has been running and all other services have started, but after a reboot it does not work. Now I know its probably dependant on another service and I know how to add dependencies, but how do I work out which services its dependent on?

View 1 Replies

Communications :: Socket Behaviour - Created A Client That Can Send And Receive Data Via TCP Sockets

Aug 26, 2010

I have created a Client that can send and receive data via TCP sockets. The objects stored on the serverside are the *exact* same object used for the client. They use the same send and receive protocols.

Now, when i send a string from the server to the client , it does precisely what it should do. However when I send a string to the server.... I do receive the string as an equal length of NULL characters. I run the server and client locally.

Basicly what can influence the behaviour between two completely identical objects performing the exact same task? I wonder if there is some socketflag issue if the TCPlistener.accept function returns a completely different setup then the one I R used to.

(if it is of any interest, the send protocol is asynchronious)

View 3 Replies

Sockets - Check That If Another Computer In The Network Send Some String Data To The Listener Computer?

Mar 19, 2012

i have a task to create a TCP Server (a program that is listening on its network card interfaces for incoming data stream).I have search on the internet and i found that i can use two methods : Socket or TCPListener class.I have created an example for Socket class, but i wondering how could i test it? I need to check that if another computer in the network send some string data to the listener computer , then this message should be displayed.Here is the example from microsoft that i am using for TCP Server using Socket:

Public Shared Sub Main()
' Data buffer for incoming data.
Dim data = nothingc[code]....

But it does not work because of the PORT setting.If in the TCP Server i have "Dim localEndPoint As New IPEndPoint(ipAddress, 0)" the client crashes, but if i change the port from any (0) to 11000 for example,the client works fine.Do you know why?

Later edit2:Maybe i should have started with this question:Which method is recommended for my scope?asynchronous or synchronous method ?

View 2 Replies

Send Email Using NET Sockets?

Feb 18, 2003

This code will allow you to send Emails using only .NET Sockets. This code was adapted from sample code on[code]...

View 7 Replies

Send Email VIA Sockets In VB?

Jun 16, 2009

So basically I would like to know what goes on behind smtpclient, webrequest and all those.

I would like to know if its possible to connect to an smtp server with sockets. Also, can anyone recommend a good OOAD(object oriented analysis and design) tutorial or book?

View 2 Replies

How To Send Bytes For String Over Sockets

Jan 16, 2009

first asking an question and then introducing but i kinda need some help in here.First of all im not new to VB, But i am to VB.NET and espessially socket programming.Now i need an way to send the lenght of the string being send in bytes before the string itself so <lenghtinbytes><string>.

ive tried so many things, and its possible because the client itself does it too...but just cant find an way.

[Code]...

View 13 Replies

Send / Receive Image Via Sockets

Feb 21, 2011

I want to send image from server to client via .net Sockets and assign it to a picturebox. but I got problem in receiving data, it's 'Server' side code:

[Code]...

View 7 Replies

Send Plain Text Via Sockets In .NET

Sep 9, 2011

I'm writing a replacement for an old library we use at the office to communicate with a rather clumsy and old custom-made C++ framework that takes requests via sockets in order to communicate with a bunch of other systems. The problem is that it will only take plain text messages containing a string which must be formatted in a very specific way.The problem I'm facing is that I haven't found so far a way of sending plain text through the socket. The Send method of the socket will only take byte arrays, and while the listening point receives the data, it gets there completely scrambled, and there's no way I can mess with that in order to convert the byte array back to plain text. I need to be able to send plain text, not byte arrays.[code]

View 1 Replies

Opening Multiple COM Ports And Send / Receive Data

Jun 8, 2011

I am trying to set up a program that allows you to open multiple COM ports and then select which COM port you send data down. The computer i am using has 18 COM ports. Also on the first code it shows the ports are open they just wont receive anything.

[Code]...

View 1 Replies

VS 2008 Multiple TCP Clients - Send The Data Twice To The Same Client

Mar 18, 2009

I have a large class that I built to act as a TCP server for one of my silverlight applications. When a user connects it stores the tcp client into a table for later communication. The problem is that when I send data, with more than one client connected, it loops through both open TCP Clients but some how sends the data twice to the same client.... the other tcp client never receives his data. This isn't a logic issue as I can step through the code and see that it is clearly taking each individual TCP client out of the table and sending it the data. They all use the same port... could that be the issue? And if so how do I make it so that it can connect on one port then transfer to another? I have tried using different computers for connecting but still the most recently connected client receives all of the packets of data.

View 6 Replies

Create Multiple Sockets As An Index?

May 10, 2011

I have a VB application where winsock is used. I want to convert it to VB.Net, so as I understand I should use System.net.sockets to do this.

But the problem is in the VB application multiple sockets are created by using the index feature of the winsock . example

Load Socket(isocket)

where isocket is an integer variable that is incremented each time, for a new connection request.

So how do I do the same, ie. open multiple sockets in vb.net?

View 1 Replies

How To Create Multiple Sockets As An Index

May 10, 2011

How to create multiple sockets as an index

View 3 Replies

C# - Can't Exit A Loop With Multiple Buffer Transfer Over TCP / Sockets .net

Oct 26, 2011

I'm transfering data over TCP/Sockets with the .Net (System.Net.Sockets) I am using this code on client side :

[Code]....

View 1 Replies

2005 - Discard The Contents Of A System.Net.Sockets.Socket Send Buffer Using TheSocket.IOControl(IOControlCode.Flush

Jun 10, 2012

I'm attempting to discard the contents of a System.Net.Sockets.Socket send buffer using theSocket.IOControl(IOControlCode.Flush, .... Does anybody know whether VB.NET supports this command? I've tried supplying 'Nothing' and 'Nothing' for both required parameters, also empty and populated byte arrays in combination with 'Nothing' for both required parameters, but I consistently get an 'Invalid argument' exception. I've tried a web search for an answer, but the only mention I've found was a question asked about 8 years ago, with still no answer.

View 1 Replies

Sockets Losing Or Mixing Up Data?

Oct 9, 2010

First let me start off by saying that I have dealt with Winsock for MANY years and am attempting to convert my project over from vb6 to VB.Net.This program was made to handle up to 70 connections at a time and constantly sending data from Server to clients and back.

There is one packet however, that reaches up to be around 177kb when sent. The sockets are set up to sent 1kb at a time.... (No other packet actually uses the whole kb). It seems that after the server sends this large packet... the client receives the data out of order. After debugging and monitoring I find that it normally happens between 3-4kb. While the first 3 are good and in order.My question is, is there a different system I should use instead of just Sockets (I have had similar problems with TCPClient) and/or can someone maybe link me to a sample project that would not have this error?

View 1 Replies

.net - Retrieving Data After Using System.Net.Sockets SendFile?

Jun 8, 2012

I'm coding a simple TCP client/server in VB.NET to transfer files of all sizes. I decided to use System.Net.Sockets's command SendFile to transfer the bytes through the socket.

On the receiving side, my code to retrieve the bytes works fairly well, but occasionally the transfer randomly stops. I figured out that by putting a small sleep delay between retrieving the next block of data makes the transfers 100% stable.My code to retrieve the data (until there is no data available) is simplified as this:

While newSocket.Available > 0
Threading.Thread.Sleep(100)
newSocket.ReceiveFrom(data, Remote)
End While

I really hate using that sleep delay and figure there must be a proper method/function to retrieve data from SendFile?

View 1 Replies

Determine If System.Net.Sockets.Socket Has Outgoing Data Not Read?

Sep 18, 2009

Is there a way to determine if a System.Net.Sockets.Socket has sent data that has not been received/read by a specified remote endpoint with a connectionless protocol?It never hurts to try.

View 1 Replies

Fail To Send Multiple Emails

Dec 1, 2009

I have encountered an error whenever i try to run my SendEmail method, the method will actually loop through a folder of files and attach the files to the mail. I am able to send email for "Records", but when the method reaches "Lists", it throws a "NullReferenceException" on the line which i have bold.[code]...

View 4 Replies

How To Send Email To Multiple Receipent

Feb 11, 2009

i'm working on a window that and i wan to send email using my window app. but have no idea on how to get it to work.

hope someone with knowledge of it could help mi out with this.

View 27 Replies

How To Send Multiple Words To Application

Aug 14, 2010

I'm trying to send some words to an application I'm running (no webpage). To do this I run my vb program and minimize it, so that the application I want to send the words to have focus.Now I've tried sendkeys, but it seems sendkeys only sends my first word and does nothing with the other words. The code below is called 4 times by the main form [code]but this throws in a overflowexception was unhandled error at the apiSendMessage(hWnd, WM_SETTEXT, 0, "Hello") line.I've tried several things but I can't figure it out how to send multiple words to the application without problems.

View 1 Replies

Send Emails To Multiple Address?

Jul 26, 2011

how can i retry sending failed email recipients. i am trying to make an application in vbnet where i can send emails to multiple address. some code snippet:

Dim SmtpServer As New SmtpClient()
SmtpServer.Credentials = New Net.NetworkCredential(xInformation(0), xInformation(1))
SmtpServer.Port = CInt(xInformation(2))

[code]...

question arises:

1.) if i have to send, for instance, email to 5 recipients, and only 3 emails have been successfully sent, how can i know the failed email addresses?

2.) where is the failed email address stored?

3.) what exceptions are needed to trapped this error?

View 1 Replies

Send Multiple Outlook Mails?

Jan 13, 2009

I have the folowing code for sending e-mails trough outlook-interop (outlook2000) with my winform application:

public class send_email
Dim oApp As New Outlook.Application
Dim oAppt As MailItem = oApp.CreateItem(OlItemType.olMailItem)

[Code].....

View 2 Replies

Send Multiple Drafts From Outlook 2003?

Mar 5, 2009

Outlook wont let me send multiple drafts at the same time. Is there an easy way to send multiple drafts at once in outlook? without having to open each one individually?

From what i've read, seen and tried; this is not possible from within outlook itself, and thus a programming solution would be required, probably some VB script

View 2 Replies

Making A Program Send Multiple Fields To An Email?

May 20, 2012

i am making a program send multiple fields to an email, however i am just testing it in a small file to get it to work, however i can't get it to send the email with say 4 text boxes ill post some of the code below and wil lbe greatful for any help.

[Code]...

View 6 Replies

Send Multiple Events With One .ics File Using Aspnetemail Class?

Aug 25, 2010

I have to send mutiple events with one .ics file using ASpnetMail Class in vb.net. and i went throgh the ASpnetMail documention but i didn't get any clue..

View 1 Replies

Send Multiple Events With Same Start Time And Duration?

May 30, 2012

When I setup the event using DDay.ical I can successfully send the events to a user's outlook. The problem arises when multiple events are setup at the same time. When this happens all emails are updates to the original task, not new tasks.

I tried adding a name to the event using the .Name property, which results in the event email being an unsupported calendar invite.

View 1 Replies

Send Multiple Faxes (files) To One Number In One Call?

Jan 27, 2010

Can I send multiple files as 1 fax? I currently can fax one file at a time. I was wonder can I send multiple files to the same fax number on one call? Without physicall trying to combine files. For example. If I wanted to send a word doc and a pdf to the same person can I do that without having to dial twice? I hope that makes sense. I don't know if you can because I see that FaxDocment.body is string and not a list of strings. I am using FaxServer and FaxDocument. I just Found FaxDocument.Bodies. Does anyone have an example on how to use this? I know that FaxDocument.Body is a file path. FaxDocument.Bodies is an object? I don't see an list of path or whatever.

View 1 Replies

Send Data From A Windows Form To An Aspx Page And Send Back A Response - Request.Form Vs Request.BinaryRead?

Mar 29, 2012

Im trying to send data from a Windows Form to an aspx page and send back a response. Im running around in circles trying to make this work. The data im trying to send is 4 strings. So fare I have this in my code, using the build-in webclient in visual studio 2010, in the windows form sending to the aspx

[Code]...

View 2 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved