Solved

API function to find MAC address in powerbuilder

Posted on 2003-12-08
9
2,385 Views
Last Modified: 2013-12-26
API function to find MAC address in powerbuilder
0
Comment
Question by:sathya_sk
9 Comments
 

Author Comment

by:sathya_sk
Comment Utility
API function to find MAC address in powerbuilder
0
 
LVL 8

Expert Comment

by:gajender_99
Comment Utility
what do you mean by mac address
0
 
LVL 2

Expert Comment

by:mdhampton
Comment Utility
Do you want to enumerate all MAC Id's available on the system, or a mac ID for a specific IP , or a mac ID for a specific adapter?
0
IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 
LVL 5

Expert Comment

by:berXpert
Comment Utility
I don't know if there is an API but let me show you what I did to find MAC address for an IP.

I have a GetMAC.BAT file where I send a PING to IP address I want to check, next I use ARP command to get MAC address, result is saved to a file that is opened in PB for processing.

You can check what I said in a DOS screen:


1. Make Ping so your computer will ask for IP to router or other computers

C:\PING 132.1.1.2
Haciendo ping a 132.1.1.2 con 32 bytes de datos:

Respuesta desde 132.1.1.2: bytes=32 tiempo<1m TTL=128
Respuesta desde 132.1.1.2: bytes=32 tiempo<1m TTL=128
Respuesta desde 132.1.1.2: bytes=32 tiempo<1m TTL=128
Respuesta desde 132.1.1.2: bytes=32 tiempo<1m TTL=128

Estadísticas de ping para 132.1.1.2:
    Paquetes: enviados = 4, recibidos = 4, perdidos = 0
    (0% perdidos),
Tiempos aproximados de ida y vuelta en milisegundos:
    Mínimo = 0ms, Máximo = 0ms, Media = 0ms


2. Ask for Phisycal address in ARP table

c:\ARP -a 132.1.1.2

Interfaz: 132.1.2.111 --- 0x10003
  Dirección IP          Dirección física      Tipo
  132.1.1.2             00-10-5a-e3-e4-f1     dinámico


[To Save into a file]

c:\ARP -a 132.1.1.2  > c:\MyFile.Txt



Now in PB open MyFile.txt and process it to find the address you are looking for.

132.1.1.1   =   00-10-5a-e3-e4-f1

Regards,

BerX
0
 
LVL 33

Accepted Solution

by:
sajuks earned 100 total points
Comment Utility
0
 

Author Comment

by:sathya_sk
Comment Utility
How to find Network id in powerbuilder5.0 ?
0
 
LVL 33

Expert Comment

by:sajuks
Comment Utility
Check http://www.funcky.com/ .
Got lots of features which you can use.

0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Update (December 2011): Since this article was published, the things have changed for good for Android native developers. The Sequoyah Project (http://www.eclipse.org/sequoyah/) automates most of the tasks discussed in this article. You can even fin…
Jaspersoft Studio is a plugin for Eclipse that lets you create reports from a datasource.  In this article, we'll go over creating a report from a default template and setting up a datasource that connects to your database.
This tutorial covers a step-by-step guide to install VisualVM launcher in eclipse.
The viewer will learn how to use NetBeans IDE 8.0 for Windows to connect to a MySQL database. Open Services Panel: Create a new connection using New Connection Wizard: Create a test database called eetutorial: Create a new test tabel called ee…

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

9 Experts available now in Live!

Get 1:1 Help Now