Topic: Best way to extend (System) %path% for own apps  (Read 9975 times)

Re: Best way to extend (System) %path% for own apps
« Reply #20 on: July 12, 2012, 09:26:57 AM »

Lancelot

  • Gena Baker
  • Grand Chef
  • *****
  • Date Registered: Sep 2010
  • Posts: 10350
I have a precise purpose in mind. :wink:
..
Thanks ChrisR for the tip of SetEnv/CodeProject: it turned out that it always does what I want without botching.
Sure  :thumbsup:
Keep in mind, adding lots of path to env variable slows down windows, that is the reason putting 3rd party tools (mostly cmd tools) ms not offers to system32 mostly prefered. printip.exe 14 KB

a reminder, printip gets information from an internet address, if (when) internet address down, printip will not work  :wink:

Great! Why doesn't Microsoft offer an equally good tool?
ms (even they add a lot in time) knows they can forget lots of tools, .... that is the reason they made wsh (Windows Script Host) and put all versions of windows
Well, wsh is not very good for various reasons.........
I advice you to learn AutoIT http://www.autoitscript.com/site/autoit/ , The Best Windows Script engine ever made , which you can create/put lots of tools, all yourself the way you like.
ps: Gena and Win7PESE made with the Great Help of AutoIT  :whistling:

 :cheers:

Re: Best way to extend (System) %path% for own apps
« Reply #21 on: July 16, 2012, 06:34:32 PM »

Mikka

  • Code Baker
  • Chef
  • ***
  • Location: Germany
  • Date Registered: May 2012
  • Posts: 256
Keep in mind, adding lots of path to env variable slows down windows
Yes, Lancelot, I'm aware of that and won't "overtax" it.

a reminder, printip gets information from an internet address, if (when) internet address down, printip will not work  :wink:
Well, I thought of that, too ...
As Reconnect.script is still beta, one big issue on my list is supplying a check for an established online connection, returning true or false.
Dunno if I could realise that as a batch script (any experts reading along?) or which commands/tools I need to involve...  :sad:

Well, wsh is not very good for various reasons.........
I advice you to learn AutoIT http://www.autoitscript.com/site/autoit/ , The Best Windows Script engine ever made , which you can create/put lots of tools, all yourself the way you like.
I did some wsh in the past, nothing serious... didn't like it too much.
Yeah, AutoIT... it's on my agenda, just heard so much praise about it. :cool:

Re: Best way to extend (System) %path% for own apps
« Reply #22 on: July 18, 2012, 08:19:59 AM »

Mikka

  • Code Baker
  • Chef
  • ***
  • Location: Germany
  • Date Registered: May 2012
  • Posts: 256
Dunno if I could realise that as a batch script (any experts reading along?) or which commands/tools I need to involve...
Maybe I've got it, anybody here to help me verifying this?

@Set NetState=0
For /f "tokens=8 delims== " %a In ('ping -n 1 -w 100 8.8.8.8 ^| Findstr /i "TTL"') Do If "%a"=="TTL" Set NetState=1
@Echo %NetState%


I use a localised Windows system (german), for which the 3rd line correctly returns 1 for a successful ping to google-public-dns-a.google.com, i.e. for a working online connection.

Re: Best way to extend (System) %path% for own apps
« Reply #23 on: July 18, 2012, 09:39:09 AM »

Galapo

  • Gena Baker
  • Grand Chef
  • *****
  • Location: Australia
  • Date Registered: Sep 2010
  • Posts: 2207
Yep, works for me under English host too.

Code: [Select]
@Set NetState=0
For /f "tokens=8 delims== " %%a In ('ping -n 1 -w 100 8.8.8.8 ^| Findstr /i "TTL"') Do If "%%a"=="TTL" Set NetState=1
@Echo %NetState%
pause

Regards,
Galapo.

Re: Best way to extend (System) %path% for own apps
« Reply #24 on: July 18, 2012, 11:16:07 AM »

Mikka

  • Code Baker
  • Chef
  • ***
  • Location: Germany
  • Date Registered: May 2012
  • Posts: 256
Thanks, Galapo. :thumbsup:
Although there's a minor flaw (not IP6-proof...), for the time being it's workable.

I'll update my script; if people here are interested in reconnecting their adsl routers, I might publish it.

 

Powered by EzPortal