Forums before death by AOL, social media and spammers... "We can't have nice things"
|    alt.os.windows-xp    |    One of my personal favourites!    |    146,966 messages    |
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
|    Message 146,108 of 146,966    |
|    JJ to All    |
|    Problem: VBS script to display a connect    |
|    02 Jul 12 05:52:15    |
   
   XPost: alt.windows-xp, microsoft.public.windowsxp.help_and_support   
   From: jaejunks_at@_googlemail_dot._com   
      
   See VBS script below. It'll show both status and properties dialogs for   
   the first connected/enabled network connection (does nothing if none   
   found). The verb to show the status dialog is already correct, which is   
   Stat&us (character case won't matter). So what am I missing? I'm using   
   Windows XP, BTW. But I think it may work in Vista/Win7 also.   
      
   dim a,b,c   
   set a=createobject("shell.application")   
   set b=a.namespace(0).parsename("::{7007ACC7-3202-11D1-AAD2-   
   00805FC1270E}").getfolder   
   for i=0 to (b.items.count-1)   
    set c=b.items.item(i)   
    for j=0 to (c.verbs.count-1)   
    'only process connected/enabled   
    if (lcase(c.verbs.item(j)) = "disc&onnect") or (lcase(c.verbs.item   
   (j)) = "disa&ble") then   
    'open status and properties dialogs   
    c.invokeverb("Stat&us") 'this doesn't work   
    c.invokeverb("P&roperties") 'this one works   
    msgbox "Press OK to close all and exit"   
    wscript.quit   
    end if   
    next   
   next   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   
|
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
(c) 1994, bbs@darkrealms.ca