Content Type
Profiles
Forums
Events
Everything posted by bphlpt
-
WPI 8.6 and beyond bug\bugfix thread
bphlpt replied to Kelsenellenelvian's topic in Windows Post-Install Wizard (WPI)
That's very appropriate. Cheers and Regards -
WPI 8.6 and beyond bug\bugfix thread
bphlpt replied to Kelsenellenelvian's topic in Windows Post-Install Wizard (WPI)
LOL I guess you didn't like my shortened version for some reason? Cheers and Regards -
So, Cabarc beats Expand, and Cabarc beats MakeCab, so Cabarc seems like the overall winner! Cheers and Regards
-
From what you show above, I don't see any situation where using Expand is faster than Cabarc. I wonder if there are any speed improvements over here when using the versions that include an "-r" option, vs using a FOR loop, when that capability is required. Cheers and Regards
-
Agreed. It should be 100% his decision, no one else's. And he does not need to explain his reason for including whoever he chooses to include. Shame on us for even bringing it up. In a way, that is his personal space that has nothing at all to do with the function or speed of the app, and he can put whatever he wants there for whatever reason he chooses. He can thank his mom or his girlfriend's pet ferret or his dog or his third grade teacher or the Easter Bunny or Santa Claus and none of us should care. Cheers and Regards
-
Well, if they came up with something that Tihiy wouldn't of come up with on his own, that Tihiy then appropriated for use in SiB everyone's benefit, then the Thanks seems fair. Hey, pirates and p0rn have usually been way faster to adopt and adapt new technology than the general public. Cheers and Regards
-
Which would explain why: Thanks for finding that jaclaz! I had searched for hours. You truly are "The Finder"! I don't know what optimization was done, if any (since the code size is exactly the same though the md5 sig is different), but the command syntax and the recursive ability is the same. Does this one work on stock Win2K? If so, I guess we have a new "winner" (speed and size for md5 only that works in stock Win2K+)? If not, I also wonder what commands it/they use different than FCIV, since FCIV does work with stock Win2K, and why the different commands were chosen? Could it just be a matter of how it was compiled, and if so, if we could find the source it might could be re-compiled in such a way to work with stock Win2K? [i know, I'm asking a bunch of hypothetical questions no one probably knows the answer to. I'm just thinking out loud.] EDIT: I also noticed that the same source you used also posted a different version of md5sum (28160 bytes) with supposedly "better precision" here -- http://d-h.st/JR6 -- but I don't have any idea what "better precision" can possibly mean. Cheers and Regards
-
While Glenn9999's solution indeed seems the winner both on speed, (very close on size), and versatility since it works on systems with stock Win2K+, just out of curiosity I wonder how the solution I've been using (the 2Kb one that does not work on stock Win2K systems attached here) compares in speed on your system with the same files, jaclaz? (and it does do folders of files recursively as well which is sometimes handy) Cheers and Regards
-
WPI 8.6 and beyond bug\bugfix thread
bphlpt replied to Kelsenellenelvian's topic in Windows Post-Install Wizard (WPI)
For an admittedly extremely small code reduction, you can change: var minutes=Math.floor(elapsedSecs/60); elapsedSecs=elapsedSecs - (minutes*60); var seconds=elapsedSecs; to: var minutes=Math.floor(elapsedSecs/60); var seconds=elapsedSecs - (minutes*60); You can also eliminate: var txt=""; and change: txt=((hours < 10) ? "0" : "") + hours; to: var txt=((hours < 10) ? "0" : "") + hours; You also should be able to eliminate: var timerID=null and change: timerID=setTimeout("ins_iTimer()",1000); // Update display to: var timerID=setTimeout("ins_iTimer()",1000); // Update display And you can save a line and eliminate a variable by changing: var nowSecs=(now.getHours()*60*60) + (now.getMinutes()*60) + now.getSeconds(); var elapsedSecs=nowSecs - ins_startSecs; to: var elapsedSecs=((now.getHours()*60*60) + (now.getMinutes()*60) + now.getSeconds()) - ins_startSecs; If you don't mind long code lines, you could even eliminate another variable by changing: txt=((hours < 10) ? "0" : "") + hours; txt += ((minutes < 10) ? ":0" : ":") + minutes; txt += ((seconds < 10) ? ":0" : ":") + seconds; document.getElementById("TimerDisplay").innerHTML=txt; to: document.getElementById("TimerDisplay").innerHTML=((hours < 10) ? "0" : "") + hours + ((minutes < 10) ? ":0" : ":") + minutes + ((seconds < 10) ? ":0" : ":") + seconds; So the new code would be: function ins_iTimer() { position="timers.js"; whatfunc="ins_iTimer()"; var now=new Date(); var elapsedSecs=((now.getHours()*60*60) + (now.getMinutes()*60) + now.getSeconds()) - ins_startSecs; var hours=Math.floor(elapsedSecs/3600); elapsedSecs=elapsedSecs - (hours*3600); var minutes=Math.floor(elapsedSecs/60); var seconds=elapsedSecs - (minutes*60); document.getElementById("TimerDisplay").innerHTML=((hours < 10) ? "0" : "") + hours + ((minutes < 10) ? ":0" : ":") + minutes + ((seconds < 10) ? ":0" : ":") + seconds; var timerID=setTimeout("ins_iTimer()",1000); // Update display } Only a total of 2 variables and 7 lines of code eliminated, plus 2 blank lines, and you'll never notice any size or speed change but still... Note: I have not tested this, I just analyzed the code, but I'm not aware of any potential problems. Cheers and Regards -
Thanks Glenn9999. In the interest of smallest possible app size for those that only need md5, would you mind making a version with only md5 supported? I would also love to see the source if you don't mind sharing. If tomasz86 or someone could then confirm if it works in a stock Win2K+ environment that would be appreciated. Cheers and Regards
-
It could also be an option set via preferences. But if we are talking about an "XP folder sorting feature", then it seems it should default to the order that XP uses. Of course this is another example why, for those that preferred the XP method of doing things, I've always liked the idea of the combination of StartIsBack plus ClassicShell so you have the options available to set it exactly how you want it. Cheers and Regards
-
Which means it should be able to be remade to work in Win 2K, doesn't it? Not by me of course, but maybe by someone that knows about such things? Would be most ideal if it would work Win2K+ as I know of at least one other project that would be useful for. Sorry I still can't find a link where it originally came from, (at least 4 or 5 years ago). Cheers and Regards
-
OK Here's my copy. It's just the md5sum.exe zipped up. MD5 of md5sum.zip - 4f71896309906be74fcc7141a042951e It's a very simplified app. To get the MD5 for the zipped file I just used the command: md5sum md5sum.zip>temp.txt The contents of temp.txt was then: 4f71896309906be74fcc7141a042951e *md5sum.zip The only option it has is a recursive option: [-r] Help is just md5sum /? which gives: Usage: md5sum [-r] filenames You'll have to try it to see if it works in Win2K. I know it works for XP+ I'll keep looking for a link on the web. Cheers and Regards md5sum.zip
-
I know it's another external file, though it is small (only 49,152 bytes), but have you tried using md5sum.exe (Freeware) available here and here, and probably other places, too? [Open up a command window and type md5sum --help for command syntax info] I also have another very small version of this, only about 2kb, but I can't find a link for it right now. I'd be glad to share it if you like, but I think I remember that it has a problem running on Win2K so didn't think it would be your first choice. Let me know if you want to check it out. Cheers and Regards
-
Well, sure, if you want to "cheat" and do it the easy way. LOL Thanks for the reminder. Cheers and Regards
-
Unless you have disabled/removed it, Win 7, including Win 7 x64, has the ability to utilize the 8.3 version of the file name or path as well. You just have to figure out what it is. Cheers and Regards
-
How to get around the 2047 characters CMD string limitation
bphlpt replied to tomasz86's topic in Windows 2000/2003/NT4
I came up with both of those about 2 and a half years ago. For Date, you are correct that the core of the code is essentially a reformatting of Rob's SortDate Version 3.10, which is why he is given specific credit, with the only change really being in the added output of the individual components in addition to the combined date string. (I never really saw the advantage of Rob's Version 4 of SortDate.) Time did not come from any version of Rob's SortTime code at all. (The core code for it came from ss64.com as credited, including the comment about the guy with green ink. LOL) I guess really the shortest solution to get both date and time is Rob's SortDate Version 5. Cheers and Regards -
How to get around the 2047 characters CMD string limitation
bphlpt replied to tomasz86's topic in Windows 2000/2003/NT4
AFAIK, here is a way to get the current date and time using batch/CMD script that will return a consistently formatted string in any version of Windows from WinXP through Win8 and 2012, (I believe it should also work in Win2K but I would appreciate someone validating that), where the OS is either 32-bit or 64-bit, in any language, in any locale, even if the date/time separators have been modified by the user. Date: Time: Cheers and Regards -
objShell.Run issues...
bphlpt replied to Falcor's topic in Programming (C++, Delphi, VB/VBS, CMD/batch, etc.)
I guess this will show how both GSM and I can get the same result with different methods: Same arrangement as last time. My revised "second rated code" : <!DOCTYPE html> <html> <head> <script language="javascript"> function myFunction() { var Act = new ActiveXObject("WScript.Shell"); var proc_archP = Act.ExpandEnvironmentStrings("%PROCESSOR_ARCHITECTURE%"); var proc_arch6432P = Act.ExpandEnvironmentStrings("%PROCESSOR_ARCHITEW6432%"); var SEnv = Act.Environment("System"); var proc_archS = SEnv("PROCESSOR_ARCHITECTURE"); var proc_arch6432S = SEnv("PROCESSOR_ARCHITEW6432"); alert("Process\nPROCESSOR_ARCHITECTURE=["+proc_archP+"]\nPROCESSOR_ARCHITEW6432=["+proc_arch6432P+"]\n\nSystem\nPROCESSOR_ARCHITECTURE=["+proc_archS+"]\nPROCESSOR_ARCHITEW6432=["+proc_arch6432S+"]"); } </script> </head> <body> <input type="button" onclick="myFunction()" value="Show bitness"> </body> </html> Note that now I get the values of %PROCESSOR_ARCHITECTURE% and %PROCESSOR_ARCHITEW6432% at both the process and the system level. 32-bit IE9 is still on the bottom left and 64-bit IE9 is still on the bottom right. So to get the OS bitness you can use the same logic that I have advocated all along, testing the values of both %PROCESSOR_ARCHITECTURE% and %PROCESSOR_ARCHITEW6432%, using either the process or the system level variables will give the same result, or you can just check the value of only the SYSTEM %PROCESSOR_ARCHITECTURE%, if you are smart enough to know that you can do that. AFAIK, you can't do the latter via CMD batch script. Geej, I don't think the code you posted in post #37 is "wrong". I think it will work correctly, it's just that since you were testing the SYSTEM level variables, you really didn't need to test them both. Testing only %PROCESSOR_ARCHITECTURE% should give the same result. Cheers and Regards -
More seriously, with the free Office 2013, Surface Pros are starting to come closer to the Surface RT sales model. Other than that, a $20 discount on the OS, even if passed entirely along to the buyer, isn't going to make a whole lot of difference. But the free Office 2013 wouldn't apply to Surface Pros unless they had displays smaller than 10.8-inch, according to what you posted above, unless there is another discount somewhere. I thought they were bigger than that. Cheers and Regards
-
It's probably cheaper for them to let someone else do the development work, get the bugs out, take all the hassle from users as they fine tune it, then just buy the company. Of course if their market share continues to deteriorate too far in the meantime I don't know how much good it will do them. Cheers and Regards
-
How to get the cause of high CPU usage by DPC / Interrupt
bphlpt replied to MagicAndre1981's topic in Windows Tips 'n' Tweaks
Getting temps that high, I would probably also try taking the back of the laptop completely off and see if you might have some major dust bunnies keeping the fan from doing its job. Cheers and Regards -
objShell.Run issues...
bphlpt replied to Falcor's topic in Programming (C++, Delphi, VB/VBS, CMD/batch, etc.)
I think I realize now that GSM and I have been talking about slightly different things. He is the scripting master after all, as my poor attempts show with my "second rated code", while I come more from a CMD batch scripting background. It seems that he is able to take advantage of abilities via VBScript or Jscript that I did not realize you could do. I did not realize that you could get the value of an Environment Variable at the SYSTEM level, no matter what process you currently were in, if I understand things correctly. This is a completely foreign concept of course to a CMD batch script programmer who only has access to one %PROCESSOR_ARCHITECTURE% variable, for example, the one for the process that he is in. Even after reading his referenced links I still had to reread them a couple of times, stare at his code for a while, and work it through. I'm still learning and I guess that was the new thing I was meant to learn today. So while I stand by the detection logic I posted in post #10, or Yzöwl's post #18, or Geej's post #37 as the safest logic to use for any script language, (CMD batch, VBScript, or JScript), that is able to run from any process on any Windows OS, (at least XP+), and accurately determine the OS bitness, I also agree that if you are indeed able to to read the Environment Variables at the SYSTEM level, then %PROCESSOR_ARCHITECTURE% alone seems to be just as accurate to determine OS bitness. In this regard GSM was right and I was wrong. I humbly ask his forgiveness for doubting him and I hope we are still friends with no hard feelings. Cheers and Regards -
StartIsBack will provide it if/when it makes Modern apps belong to taskbar (like ModernMix does). I assume you mean this? That does look like neat! Cheers and Regards
-
Add Right click .wim Windows 7 or Windows 8/8.1
bphlpt replied to maxXPsoft's topic in Unattended Windows 7/Server 2008R2
The purpose of the "\n" is to split the text into two lines. The "\n" means "new line" and doesn't actually show as "\" or "n" but causes a carriage return, or line feed. See http://en.wikipedia.org/wiki/Newline: The same sequence is used in JavaScript, PHP, and other programming languages. Cheers and Regards