borderAndreaVB free resources for Visual Basic developersborder

AndreaVB Visual Basic and VB.NET source code resources - Copyright © 1999-2008 Andrea Tincani
:: Get your IP address and your computer name using the Microsoft Winsock Control

Author  

WaLDoxWhO

Language  

VB6

Operating Systems  

Windows 95, 98 and NT
Usage

'this is for gettin your IP address and your computer name using the winsock control.
'when you first load the winsock control its named
'winsock1 so i'll use that name for this example. i'll also be using a
'text box called Text1 to place the IP address.


form_load()
' This will put your IP address in the Text1 text box.
Text1.text = Winsock1.LocalIp

'now for gettin your Computers Name.

form_load()
' This will put your computers name in the Text1 text box.
Text1.text = Winsock1.LocalHostName


'I hope this helps someone, these are very simple codes.
'one liners as i like to call them.. anyways, enjoy
'-WaLDoxWhO

:: Navigation

Home

Beginners Corner

Previous Tip

Next Tip

:: Search this site
Google
:: Related Topics
icon 10-10-2006 Re: get the computername or IP Address by LFC8
icon 10-10-2006 get the computername or IP Address by humberto
icon 07-04-2006 get IP address of printer by mcorben
icon 28-03-2006 Re: remote database by steve_w
icon 17-03-2006 Re: Anything wrong with my code? by Goran
Partners: Il portale per lui e lei | Download Actual Software | Free Software Download
borderAndreaVB free resources for Visual Basic developersborder

borderAndreaVB Visual Basic and VB.NET source code resources - Copyright © 1999-2008 Andrea Tincaniborder