Tuesday, 23 June 2009

Cisco AP - getting AP transmit power using SNMP

Someone asked me this question and I thought, well simple. Just ask the box.

Then finding the right part of the tree was somewhat harder.

Did find this, which is a bit handy...

http://tools.cisco.com/Support/SNMP/public.jsp

Then I found the most useful tree entries for me to be:
1.3.6.1.4.1.14179.2.6.3.42
and
1.3.6.1.4.1.9.9.272.1.1.2.14.1.6

that's it. I used SNMPGET on a solaris platform to get the info - this isn't necessarily the built in one, I seem to remember downloading it as a standalone binary some time ago but the tree is the key bit for this post.

Cisco deliberately annoying customers

This really made me giggle:




and a screenshot because they are bound to change it......


Wednesday, 17 June 2009

Create a temporary file (automatic name/path generation) in VB.net

Love this one:

myfilename = System.IO.Path.GetTempFileNameSystem.IO.Path.GetTempFileName()

Brilliant.

Spawning an executable from VB.net (using file type association)

Right, this one took longer than it should.

Wanted to:
  • Open webpage using default browser (not necessarily IE)
  • Open a CSV file using Excel

So it should be simple. filename stores "c:\mycsv.csv" or http://www.nowhere.com)

Option 1: Shell(filename)
Didn't work. End of.

Option 2: ShellExecute(0, vbNullString, filename, vbNullString, vbNullString, vbNormalFocus)
Works great on Vista, no good on XP. Didn't do anything.

Option 3: System.Diagnostics.Process.Start(filename)
Works fine on both. Brilliant. Job done.