Program/service That Is Using A Given Port?
Sep 30, 2009Is there way, using .Net, to see what program/service that is using a given port?
For instance, Vuze is using port 15510, but how can i find that with code?
Is there way, using .Net, to see what program/service that is using a given port?
For instance, Vuze is using port 15510, but how can i find that with code?
I am trying to create a windows service (visual basic 2005) that will listen for a UDbroadcast. If it detects the broadcast it then run an external program. I havesuccessfully created the server and client programs using basic forms. I used the code from this forum
View 1 RepliesMay i know how to fire an event using the serial port interrupt method in visual basic windows form? Currently, now i am using the polling method which is using the timer event to continuously poll the port every 1sec.
But now i would like to change to the interrupt method which will fire up the same event without using the timer event.
[Code]...
I'm experiencing a weird problem. I need to create a Windows service that listens to a port for data. The data is comma separated, so I need to split it up and just write a few of the separated values to a file. This is a brief summary of my code:-
Do While True
tcpClient = tcpListener.AcceptTcpClient()
networkStream = tcpClient.GetStream()
Dim bytes(tcpClient.ReceiveBufferSize) As Byte
[code]....
Now the above code works fine. But suppose I just want to write only (2) to file i.e 2 of the comma separated values, problems arise. This is what happens:-
If I include both lines (1) and (2), output file = lines (1) and (2)
If I include only line (1) and comment out (2), output file = line (1)
If I include only line (2) and comment out (1), output file = BLANK ???
I wanted to know what are the risks of opening up a socket server on a specified port? Right now I have it limited to only accept requests from 1 specific IP to that port and all the other ones get rejected (using the windows firewall), is there a way to implement an authentication or anything else so I can allow it to be accessed from any IP worldwide yet have it secured?
View 1 RepliesIm having problem with the Serial Port. When i run my program, "Access to the port 'COM1' is denied". What does that mean? Im not sure whats happening because theres no error in my code. Someone suggest me to use 'COM2'. Which is also the same result. I have a microcontroller, programmed and run it. And i need to capture the data onto my vb, which is on a multiline textbox. How to i do that?Just to double check my code?
[code]...
I'm confused , in the old days if I wanted to access a parallel or serial port I would simply set up the appropriate registers and read/write to I/O Registers. but USB is a whole different animal. Lets assume I plug device X into a usb port How do I find where the pc, or manufacturer has placed it? If it's a ddl then what is my fetch? if it's a virtual port where do I find the virtual irq and read/write port? What if it's a dongle, where do I find it's read registers? what if it's an external piano, where do I find it's sound out read regs etc.
View 4 Repliesi actually wanted to know how to program my USB port in Vb.net . I want the USB port of laptop to work as a serial port and for that i have an USB to Serial port converter ... But since laptop does not have any COM ports how do i know the to which USB port is my Adapter connected... ?
View 2 Repliesi have a Windows service that is hosting a WCF service through net.tcp and this is working great. I have also created a WCF service application. I am trying to add the net.tcp service reference to the service application. Then I add it to the GAC that goes ok but if I try to RegAsm the WCF service application to allow it to be called from Server.CreateObject I get the error:
Warning: Type library exporter encountered a type that derives from a
generic class and is not marked as
[ClassInterface(ClassInterfaceType.None)]. Class interfaces cannot be
exposed for such types. Consider marking the type with
[ClassInterface(ClassInterfaceType.None)] and exposing an explicit
interface as the default interface to COM using the
ComDefaultInterface attribute.
It does not work. I have tried to call it through a class library but this does not work either as the end point is not set correctly.
How do i access a port in Visual Basic?
View 3 RepliesI am looking to write a VB.NET windows app or service to do simple HTTP port forwarding. This is normally done within my router, but I have more forwards to do than the router can support (10) so I would like to do it programatically.
Quite simply, an HTTP request would come in on a port where the application/service is running, and it would automatically forward the conversation to another IP address and port. That way, my router could forward a range of ports to one machine (where the application/service would be running) and the application/service would dole the requests out to the various IP/Port combinations it was listening for.
Currently I'm doing a project on Torque test sensor. i already have a OUSB board which can get a Analog signal and convert into Digital send through the USB port. I am using VB.net and i can pass the commands into the board through the USB port. since i have the driver to and I know all the command to communicate with the board. I can send and get values through the CMD window. Also i can send the values through Shell command in VB.net. But I can't grab the incoming values through the usb port when I am uisng VB.net[code]...
View 3 RepliesI want to print the current port address of the usb stick which is connected to the computer ? By using Visual Basic 2010
View 1 RepliesI am using Scanpal2 to read data and as per its documentation as follows
View 8 RepliesI'm working on a project that involves sending information through a GSM module, this module is connected to the system through a USB port. the information to be sent is gathered from a database using VB, now I need to send the information from my VB program to the USB port for onward delivery to the GSM module.
View 2 RepliesI have an order entry system which was developed using vb.net it uses an ms access database.I think I might be able to use mono?I'll need an IDE if possible.
Can someone tell me what I'll to download and what problems I might face, also any suggestions.
I have very limited knowledge of any programming and am desperately trying to learn. I am attempting to use Visual Basic to create a simple program to operate our church's projector from the computer. I am able to control the projector using hyperterminal and accessing the serial port. I am wondering how I would code a button to send the correct signal to the correct port? I have a simple setup w/ my church logo in background with three buttons. There is an On, Off and Freeze button. I am simply needing to know how to program the buttons to access the serial ports. I hope I am being clear.
View 2 RepliesI have a VB.Net 2008 app that I have converted from VB6 which reads data from a weight scale connected to a serial port. I am able to read the received data and display it on the screen, but when I go to Stop the reading and attempt to close the serial port, the app hangs.
Private Delegate Sub ShowWeight(ByVal tWeight As String)
Private Sub comScale_DataReceived(ByVal sender As Object, ByVal e
As System.IO.Ports.SerialDataReceivedEventArgs) Handles
[Code]....
i want to know how can grip messages come by serial port and create data base to this message ,,,i mean to drop this message to . record to store it and i can use in my program
View 3 Repliesi have the following code which runs ok, but it hogs upto 95% of the CPU.program outline: a timer tick event = 1000ms scans through 30 readlines of data on the comport for a specific line of hex, and then extracts information from the next line and converts it to decimal for viewing on the screen.i've only included the main part of the code to try and keep it simple.
Public Class Form1
Private WithEvents serial As New IO.Ports.SerialPort
Public grab As String
Public cardIndex As Integer
[code]....
I'm trying to make a Client that will automatically run a .DLL that I have created and send information over port 80 to my Server program that will take that data and import it into a database for me. Problem is, I don't know where to start as I have never done this before. I want to do this in VB .NET as this is the programming language that I know. What are methods of doing this? Is there sample code out there for something like this? My google searches are failing me.
A better layout of what I'm trying to do:1. Client Runs .DLL, retrieving information from an Excel file.2. Client takes these properties with the data it contains and sends it to a program outside of the local network through port 80, my boss refuses to let me use any other port.3. Server accepts the data and builds its own properties to be imported into my Access Database.4. Repeat over, and over, and over, and over.
I plan for the server application to be a console application, and the client to be a windows form.
I want to write a program that can control port communication in a PC by blocking certain port based on the admins request and also monitor incoming and outgoing network traffic. Can i achieve this using vb.net winsock?
View 1 RepliesHow do you record sound from the normal microphone port onto your program?
View 9 RepliesI am supposed to make a software for data logging via serial port but the hardware is expected to be delayed and iam required to continue with the programming of the software. What i need is that by some mechanism i want to send data on serial port (COM port) and after delay of some mili seconds i want to detect that data. I actually want to do this because i want to create environment like my software i intercepting COM port and on receiving data it captures the data values on port and record them to database. I have done most the work, the only thing left which i want is as above how i will send data on COM port (this was to actually to be done by hardware) and detect it in my program (same program from which data was sent). Please guide from where should i start.
View 3 Repliesi have downloaded TCP program and try
[Code]...
what is the right IP or Port must i used? between client and server
I want to make a program that sends an AT^ command to a port The AT^ Command is
AT^CARDLOCK="TEXT IN TEXT BOX 1"
i'm working on a project that simply changes the wallpaper periodically...it works fine...I created two seperate projects...1) a forms application 2) console application........The forms application gets the data and settings from the user....the console application reads the data and settings from text files created in the forms application and does the job of changing the wall paper...i've got mine set to change every minute...I realy want to get this finished, but am stumped by a few things....
1) how can i get my console application to run as a windows service..have tried the SC Create command..no good.
2)how can i get it so the console program runs as an icon on the system tray near the clock.
3)When i want to publish to create the setup.exe...should i somehow merge the two projects together or publish each one seperatly and use some sort of batch installer.
I have a program which i want to invoke from windows service.
[Code]....
The same code works fine if i write in a console application, but from windows service it wont run, i see the psftp is being started in the task manager but it wont do anything.
I have a VB2008 application which can control a windows service i.e. start, stop, pause etc. This runs ok on a Windows XP machine but not on a Win 7 machine (message is - Service error cannot open <service name> service on computer '.') ( if I stop the UAC then it runs ok ). It seems to be a rights issue,
View 3 RepliesI have recently developed a serial port communication program to access my hardware firewall and its connected to the device via a converter usb to rs232head plugged to a rs232 to an ethernet cable. this ethernet cable then plugs into the device console port.
my program functions similar to that of TeraTerm. an opensource hyperterminal program written in C++ but i decided to do one for vb.net
Alright to cut the story short, i have successfully coded out the program to accept incomming data from the device but however, i'm also receiving ansi escape sequence along with it and i have no idea how i could implement codes to remove these. i have spend 3 weeks trying to look for vt100 emulation codes written in vb.net but i found none so far. most are written in c++. here's an image to illustrate the problem which im facing.
The image below is a screenshot taken when the i ran both the programs together. The bottom is tera term 3.1 and the top is my vb project which i made using msdn's example and improved on the codes. basically tera term was able to interpret those escape sequence and display accordingly to that of the vt100 terminal display. I have spent time reading on regular expressions using the inbuilt function regex in visual basic and tried parsing some strings but its not working. i guess its far more complex than i thought.