I am writing a Macro where I want to take input(IP Address) from a
specified excel sheet,then through some command I will get some output
in Telnet session then I Need to store it as a LOG.
Please suggest me...............
Thanks,
Smruti
"Smruti" <smruti...@gmail.com> wrote in message
news:86df7e3d-72d9-4298...@l22g2000pre.googlegroups.com...
Are you writing this as an excel macro? If so, the language is VBA, whereas
this newsgroup is for VBScript.
If not VBA, but VBScript, then I would suggest that you write a script that
opens a spreadsheet, extracts an IP address from whichever cell it might be
located in. Once your script has the IP address, it would then either create
a telnet session or connect to an existing one, issue some unspecified
command to the telnet host (or so I would assume), capturing the output to
store in either a log file or the event log, whichever you need.
Which parts of the above are you having difficulty with?
/Al
I am writing Excel macro...........Please suggest if you have any
ideas in VBA...........
"Smruti" <smruti...@gmail.com> wrote in message
news:ca469377-8fdb-4cc5...@k18g2000vbq.googlegroups.com...
Sorry, no. As I have said this group is for vbscript, not vba. There are
similarities, for sure, and perhaps some of the others that frequent this
group may have suggestions for you. Have you looked for an excel-specific or
vbs-specific newsgroup? For example alt.comp.lang.vba or
microsoft.public.office.developer.vba?
/Al
The important part of this is the Telnet client. The one that comes
with Windows does not support scripting. Therefore, the starting
point of your quest is to locate a third party Telnet client that does
support scripting. Then you can either use VBAs Shell() method or the
Wscript.Shell object's Run method to launch the telnet client with its
script.
I just did a quick groups.google search an it seems that one utility
you could consider is called NetCat (nc.exe) found at www.securityfocus.com/tools.
It is not actually a telnet client, but rather it can be used to open
the telnet port 23 from the command line. As a command line utility
it accepts redirected input and allows its responses to be redirected
to an output file. Some examples are found in these threads:
http://groups.google.com/group/microsoft.public.scripting.vbscript/browse_frm/thread/d08eabc0e5c1785c/7a3ce3607e6f99ba
Others can be searched with this query: "script telnet
group:microsoft.public.scripting.*" sorted by date to keep from
finding out of date information.
______________________________
Tom Lavedas