If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Data Access, Manipulation & Batch Languages > ASP > need help ..regarding vbs scripting

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 12-12-07, 03:22
subbeh subbeh is offline
Registered User
 
Join Date: Dec 2007
Posts: 1
need help ..regarding vbs scripting

i would like to know that whether is it possible to auto generate the pc number using vbs script ..
Just like example ..my current pc name : subbeh
and i want it to auto generate it like
ComputerName : subbeh1
ComputerName : subbeh2
and so on .. please help
Reply With Quote
  #2 (permalink)  
Old 12-12-07, 03:53
Marvels Marvels is offline
Registered User
 
Join Date: Jul 2003
Location: Amsterdam, Nederland
Posts: 449
Re

Hi

i'm sertain that you cant get user pc name
Security reson, but you can get his IP/adres
System.Web.HttpContext.Current.Request.UserHostAdd ress

For the server's MachineName you can do.
System.Environment.MachineName.ToString()

If the pc's are on your network, then you can do a reverse dns lookup on the
request IP/address.
and then add a number to get what you want.

GrZ
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On