find mac address of my own computer by excell macro

I am using excell 2002. I want to find mac address of my own computer by 
excell macro. 
0
Utf
3/12/2010 5:09:03 PM
excel.programming 6508 articles. 2 followers. Follow

1 Replies
1872 Views

Similar Articles

[PageSpeed] 54

Give something like this a try.

'----------------------------------
Sub GetMAC()

Dim strLine As String
Dim bEther As Boolean

bEther = False
Set wsh = CreateObject("WScript.Shell")
Set wshExec = wsh.Exec("ipconfig /all")
Set objStdOut = wshExec.StdOut

Do Until objStdOut.AtEndOfStream
    strLine = objStdOut.ReadLine
    If InStr(strLine, "Ethernet") > 0 Then
        bEther = True
    End If

    If InStr(strLine, "Physical Address") > 0 And bEther Then
        strLine = Right(strLine, 17)
        Exit Do
    End If
Loop

MsgBox strLine

Set wshExec = Nothing
Set wsh = Nothing
End Sub

'----------------------------------

Steve Yandl


"INQUISITIVE DISCIPLE" <INQUISITIVE DISCIPLE@discussions.microsoft.com> 
wrote in message news:639C3D14-44AB-4CBF-9CFA-578B182F98E4@microsoft.com...
> I am using excell 2002. I want to find mac address of my own computer by
> excell macro. 

0
Steve
3/12/2010 8:44:33 PM
Reply:

Similar Artilces:

I need to compare 3 numbers and find the one in the middle
I have three numbers in a single row and would like to identify the middle number enter that number in another cell. Example: 1st # 2nd # 3rd # result 628 678 720 678 655 625 700 655 748 720 725 725 is there a function in excel that can do this? Thanks, Eddie Try =LARGE(A1:C1,2) VBA Noo -- VBA Noo ----------------------------------------------------------------------- VBA Noob's Profile: http://www.excelforum.com/member.php?action=getinfo&userid=3383 View this thread: http://www.excelforum.com/showthread.php?threadid=56811 fasteddie wrote.....

Renaming Exchange 2003 Server computer name
Is there a way to rename an Exchange 2003 server computer name without having to reinstall? Thanks for your help jericom@gmail.com (Jerico Max) wrote in news:bdd87ac0.0409221151.125dfb99 @posting.google.com: > Is there a way to rename an Exchange 2003 server computer name without > having to reinstall? This can get ugly. Proceed with caution. I'd recommend building a new server and moving mailboxes to it. You could use temporary hardware and rebuild your current server with your required name. Regards, -- Arlo Clizer Exchange MVP FAQ: http://www.exchangefaq.org Archives: htt...

Find Duplicate names and delate
Dear experts, I have a small doubt could you clarify that??? That is I find duplicate name but I want to delete one name only, if I filter DUPLICATE….. both names are showing… 1. Select the range of data including the header. You need to have headers for these columns 2. From menu Data>Filter>Advanced Filter>Copy to another location 3. In 'copy to' specify the target cell and check 'Unique records only' 4. Click OK will give you the unique list -- Jacob "Find Duplicate names and delate" wrote: > Dear experts, > I have a small ...

Existing word documents made on PC
Version: 2008 Operating System: Mac OS X 10.5 (Leopard) Processor: Intel I have a number of documents made on a PC that include images - scanned, from the internet, etc. They look fine when opened by Word for PC, but when the same file is opened by me using Office 08 for Mac, some (not all) of the pictures appear absolutely minute, in the top left of the image box. The image box is still there, so the text alignment is not affected, but the rest of the text box is blank. I have even had a colleague open the file on her PC to show me the image is fine, then email me the same image - with the s...

Updating GAL from Excel?
Hello all, Can anyone recommend a tool for updating a global address list from an excel spreadsheet? Im not sure if such a thing exists but this would be a major convenience. I have an excel spreadsheet with my entire corporations address information and the execs would like to rely on the GAL for finding contact information. This would take me hours to do manually and having a tool or a script that can import or update fields would make the labor much simplier. I appreciate your responses. Keith. On Fri, 7 Oct 2005 08:41:03 -0700, "Keith" <Keith@discussions.microso...

Find a Value the first Time It Occurs
I have a row of values that shows the total cumulative number of sales of items by month. Occasionally, there may be no sales in a month for an item so the cumulative value would stay the same for more than one month. I want to select a number in the row the first time it occurs and not select it if it repeats. What are you wanting to do with the info? To return position (column number) of number 1234 within row 2: =MATCH(1234,2:2,0) A formula that signals it's the first occurence: =COUNTIF($A2:A2,A2)=1 This could be used in a helper row, or as a conditional format f...

Finding a Median
I'm trying to write a query that will return a median for various values taken from a previous query. I've seen some suggestions in my searching, but I haven't been able to get them working. They are also all from before 2003 and refer to Access 97 and 2000. Has any functionality been added to 2003 for this? Or is there a non- code-based way to do it? I've seen it suggested to write a code to open the query, sort it, find the total number of records, divide it in half, then seek out the middle record using that value. I'm still very green when it comes to code, though...

Excel won't open spreadsheet #2
Thank you. The first option worked. opty -- opty ----------------------------------------------------------------------- optyk's Profile: http://www.excelforum.com/member.php?action=getinfo&userid=1533 View this thread: http://www.excelforum.com/showthread.php?threadid=26959 ...

Email addresses not showing up correctly.
I have a client running Windows Small Business Server 2003. We just started noticing some wierd actions when users are recieving emails. When some users recieve emails their email address shows up like the following. cc: MS Outlook::/O=Domain/OU=FIRST ADMINISTRATIVE GROUP/CN=RECIPIENTS/CN=FKING It Doesnt appear to be happening all the time just with a few users. And it doesnt appear to be causing any issues but any assistance with this would be great. -- Thank you, ...

I don't know but I may need a macro?
I don't know but I may need a macro? This is a golf league There are the regular players and the substitute players On worksheet1, I enter scores for individual players and the substitute players. On worksheet2, the scores are transfered from worksheet1, and further calculations are made. Under perfect conditions, if no substitute players are playing, all the scores I entered on worksheet1, transfer to worksheet2, and all is right with the world, my work is done, all I have to do is print. However, If a regular player is "MIA", that transfers to worksheet2 a "MIA",...

Will Excel 2004 run on SnowLeopard OS X 10.6?
Operating System: Mac OS X 10.6 (Snow Leopard) Processor: Intel I'm a SW developer who uses a lot of VBA for Excel programing, for automaation and macros. Besides that, my customers use the spreadsheets I develop in Office for PC's. I know Office 2008 has no VBA for Excel, but I really need it. Can I install Office 2004 in my computer and will it run under Snow Leopard, so that I can keep on using VBA with Excel? Yes -- But do a fresh install. Don't try to 'migrate' Office from an earlier version of the OS if you're upgrading to 10.6 & you will have to use t...

Find/Replace in RichEdit 2.0
I'm using Windows ME and I've switched from RichEdit 1.0 to 2.0 for my CRichEditDoc/View application so that I can use the ITextDocument interface and can do things such as suspend/resume the Redo buffer. Problem is, now the Find/Replace dialogs don't seem to do anything. If I revert back to RichEdit 1.0 they do! What's going on? BUMP! adriangibbons@yahoo.co.uk (Adrian Gibbons) wrote in message news:<34a2acd5.0404130713.123dbaab@posting.google.com>... > I'm using Windows ME and I've switched from RichEdit 1.0 to 2.0 for my > CRichEditDoc/View application...

Export multiple Excel sheets to a single text file
I want to export (SaveAs) multiple worksheets to a single text file. probably csv. By Microsoft's design I can't do that with a straight Save As from the menu. So I thought maybe I could create a macro that would save each sheet one at a time. Unfortunately this doesn't seem to work because Workbook.SaveAs doesn't seem to have an append capability. Worse case is I save each sheet to a separate file and manually append them. Short of that, any programmatic suggestions? Hello, Here are two lots of code one will put alll the sheest into sererate .txt on t...

address book #73
hi, i am looking for a way to copy the office address book for my personal use from the exchange server of some kind. when o open up the properties tab at wofk to see if i can right click and save, it would let me, as a matter of fact it is not even an option. any tips. im pretty sure that the administrator is the one who maintains the address book and the employees can only view it and send email using it, but i dont think one can save it. any tips. http://www.slipstick.com/exs/portagal.asp --=20 Milly Staples [MVP - Outlook] Post all replies to the group to keep the discussion intact. Af...

Linking data from .CSV to Excel
Hello! I'm completely stuck. I have an excel spreadsheet that uses data fro a .CSV file. This data (all numbers) is linked to a sheet in th workbook. The problem is this: in order for the data to be updated, it is necessary to open up th .csv file whilst the workbook is open. This is a terrible hassle. have tried making a macro that opens the .csv file and then closes i again, but that doesn't appear to update the linked data fields. Th Edit/Links/...update links function won't work, since Excel say "External Copy: file format is not valid". Does anyone have any...

Update Customer email address using SQL statement
Recently we changed from Yahoo Groups to managing our own email list. Our list went from 1400 addresses to around 3600. Of those, about 400 turned out to be hard bounces. I would rather not have to update 400 records, one at a time. Can anyone help me write a SQL statement that would update these records from a file, list, or table containing the bad addresses. What I need to do is blank the email address and put a statement in the Company field (e.g. Need to Update Email). If there is another (better) way to do this, I am totally open to suggestions. Thanks in advance! Bud Izen Keiz...

OK, a really tricky one now for Excel gurus!
A perfect response before, this time a little trickier! I have two data sources: Data A) a column of approx. 3000 cells featuring the 'Post Code' only from a database of addresses. Data B) The Australian postcode database as found and downloaded from the below link: http://www1.auspost.com.au/postcodes/index.asp?sub=2 What I want to happen is each postcode from source 'A' to match up with the corresponding post code from source 'B' (this is in column A). Once it matches, the 'Delivery Office' (column E) is to appear in column B of Data Source Sheet A......

Changing Computers
I downloaded Money 2003 from the MS site and now want to install it on my new computer. How do I do that? Thanks! Normally you just need to double click the .exe or .msi file -- Glyn Simpson, Microsoft MVP - Money Check http://support.microsoft.com/default.aspx?scid=fh;EN-GB;mny for UK tips and fixes for MS Money. To send Microsoft your wishes or suggestions, use http://register.microsoft.com/mswish/suggestion.asp or email mnyukwsh@microsoft.com especially if it's a UK specific wish. I do not respond to any unsolicited email regarding Money "Aaric" <anonymous@discussi...

Find (but not find)
My program takes a name from sheet3 goes to sheet1 to Find the name. If it cannot find name, how do you do an If/End to Exit Do while or find out if name has been founf? I have "On Error Resume Next" in program. Thanks again for all your help Gordon As ALWAYS, post your code for comments & suggestions. -- Don Guillett Microsoft MVP Excel SalesAid Software dguillett1@austin.rr.com "Gordon" <gwelch1938@yahoo.com> wrote in message news:1184612089.486737.144020@n60g2000hse.googlegroups.com... > My program takes a name from sheet3 goes to sheet1 to Find the na...

problem with copy/paste macro
I want my macro to take me to Tools>Letters and Mailings>Envolopes and Labels...>Labels Paste the selected text in Address section continue to Options>Details and select the Number Down field. so far i have this: Sub Macro1() Selection.Copy SendKeys "%L%A" Selection.Paste SendKeys "%O%D%D" Dialogs(wdDialogToolsEnvelopesAndLabels).Show End Sub If you do it with mouse, it pastes the selected test in Addres section automatically. When running SendKeys "%L%O%D" Dialogs(wdDialogToolsEnvelopesAndLabels).Show it doesn't put the selec...

Program trying to access e-mail addresses
Everytime I open up my email fresh (for the first time), I get a warning that "A program is trying to access e- mail addresses you have stored in Outlook. Do you want to allow this?" I select no numerous times (the message keeps popping up) and then Outlook locks up. I can then "End Task" Outlook, restart it and use it, however it then is unstable and I have trouble shutting down my computer. I have been unable to track down what program or service is trying to access my e-mail addresses. I have Norton Antivirus/Internet Security 2004. It is updated and unabl...

Find value in a column and insert rows above
The set up looks like this: ColU ColV ColW ColX Y N N N Y N N N N Y N N N N Y N N N Y N N N Y N N N Y N N N Y Y Columns will always be U through X and will always be sorted in this order. I need to find the first Y in each column and insert 2 rows above that row. On the blank row above the first Y, I need to highlight in yellow and put title in the first cell, such as New, Old, Existing, Deleted. Any help would be greatly appreciated. Thanks for your time, Dee If desired, send your file to my address below. I will only look if: 1. You send a copy of this ...

address books #2
I have been successful in networking 2 "XP professional" computers that are using Office 2000 Premium. I can see my emails on both but can only access the address books on the original one. Can I link the address books from the original computer to the 2nd one like I did the personal folders? Please tell me how but be exact as I am not a techie person but can follow directions. Thanks. ...

access or excel template for pricing comparison between companies.
looking for a template to compare 4 co's pricing based on a select criteria. Can be either excel or access. Would like a sheet that prints out for the customer showing the results. -- coop Hello Coop, I would like to offer to build the Access database you need. I provide fee-based help for Access, Excel and Word applications. My fee to help you would be very modest. If you would like to work together, email me at my address below. Steve santus@penn.com "coop" <coop@discussions.microsoft.com> wrote in message news:CFBACF9B-FC4E-472E-97F9-9B2A9...

Office 2008 components deleted from mac library. How to get them b
I'm using a Macbook running Leopard. I recently attempted to delete my browsing history on my Macbook (I went to Finder, clicked on Search For in the sidebar, clicked All Documents, and dragged them all to the trash). Obviously my intention was only to delete the history but in fact I ended up deleting every document I ever opened on the computer. There was no option to undo, or to restore the files (approximately 9000) to their original location, so I had to just drag them out of the trash to the desktop and manually sort them back to their original location. That worked for mos...