Archive

Posts Tagged ‘Energie’

Die Sidebar und CreateObject(“WScript.Shell”)

Juli 6th, 2009 1 comment

It is to excite :motzen:

For a long time it annoys me that I cannot work from the Vista Sidebar by VBScript with CreateObject(“WScript.Shell”). Seems as if Microsoft would have prevented that, thus for harming software it is more difficulty to do bad things.

There are a few cheats to go around this, but if I want to get the output of a command prompt by using VBScript, then only the detour helps to temporarly write the result into a file.

However, such a thing I do not want!

Fortunately ‘s there still Javascript and the new ActiveXObject(“WScript.Shell”) with which I always marvelously could help me so far.

Well, so far in Vista. Now I have this function in my beta of margu-NotebookInfo2 2.1.0 for the moment to work over with the powerplans. I make that – because I still didn’t found no better way on script basis – to query and also change hose available powerplans by the command line.

There I was surprised why this module of my Gadget won’t function under Windows7 RC and had to state that not only the VBScript function of the CreateObject, but now also the counterpart in Javascript, which works at least in Vista, is deactivated.

And now I stand there and seek desperately in the net already for a solution with which I can live.

Thus it dows not surprise that I still stand on beta4 of my gadget, because finally my gadget shall work with Windows7 too.

Es ist zum Aus-der-Haut-fahren :motzen:

Schon lange wurmt mich, daß man aus der Vista Sidebar heraus nicht per VBScript mit CreateObject(“WScript.Shell”) arbeiten kann. Scheint als hätte Microsoft das unterbunden, damit es für Schadsoftware schwieriger ist böse Dinge anzustellen.

Es gibt zwar ein paar Tricks um das zu umgehen, aber wenn ich möchte, daß das VBScript mir z.B. die Ausgabe von einer Kommandozeile zurückgibt, dann hilft nur der Umweg über eine Datei in die man das Ergebnis temporär schreibt.

Sowas will ich aber nicht!

Zum Glück gibts ja da noch JavaScript und das new ActiveXObject(“WScript.Shell”) womit ich mir bisher immer wunderbar helfen konnte.

Tja, soweit in Vista. Nun habe ich diese Funktion im Moment in meiner Beta von margu-NotebookInfo2 2.1.0 um mit den Energiesparplänen zu arbeiten. Das mache ich – weil ich noch keinen besseren Weg auf Scriptbasis gefunden habe – um über die Kommandozeile die vorhanden Energiesparpläne abzufragen und auch zu wechseln.

Da wunderte ich mich, warum dieses Modul meines Gadgets nicht unter Windows7 RC funktioniert und mußte feststellen, daß dort nicht nur die VBScript Funktion des CreateObject deaktiviert ist, sondern jetzt auch das JavaScript Pendant, welches zumindest in Vista funktioniert.

Und nun stehe ich da und suche schon verzweifelt im Netz nach einer Lösung mit der ich leben kann.

Also nicht wundern, warum ich vorerst auf der Beta4 stehen bleibe, denn schließlich soll mein Gadget auch unter Windows7 funktionieren.


new: margu-NotebookInfo2 V2.1.0 beta1

Juni 25th, 2009 No comments

margu-NotebookInfo2 Version 2.1.0 beta1

margu-NotebookInfo2 2.1.0 beta1

margu-NotebookInfo2 2.1.0 beta1

Für die nächste Version meines Gadgets habe ich ein neues Modul vorgesehen, womit man auf dem Gadget angezeigt bekommt welcher Energiesparplan aktuell genutzt wird und welche Pläne in Windows zur Verfügung stehen. Zusätzlich kann einfach per Klick zwischen den Erergiesparplänen umgeschaltet werden.

Unterstützt werden insgesamt 6 Pläne, wobei die ersten 3 schon von den Standardplänen von Windows vorbelegt sind. Wenn man in den Energiesparoptionen von Windows weitere eigene Pläne anlegt, werden diese dann ebenfalls im Gadget angezeigt. Allerdings sind nicht mehr al 6 Energiesparpläne möglich. Sollten mehr vorhanden sein, dann werden alle vom 7. an ignoriert. Ebenso sind die Buttons ohne Funktion, wenn kein entsprechender Plan verfügbar ist.

Weiterhin soll in der nächsten Version die Möglichkeit vorhanden sein zwischen verschiedenen Themes zu wählen. Allerdings bin ich da noch schwer mit zugange und in dieser Beta sind die Funktionen noch nicht vorhanden.

Wer das neue Modul schonmal testen möchte, kann die Beta1 mit dem unten angegebenen Link herunterladen.

Viel Spaß beim Testen wünsche ich und würde mich sehr über Rückmeldungen freuen.

For the next Version of my gadget I’ve planned to include a module which gives the ability to see which Powerplan is currently active and which powerplans are available in Windows. Additionally one can easily switch between the plans.

Altogether 6 plans are supported, whereby the first 3 are already reserved for the Windows standard plans. If you create your own powerplans in Windows they will be shown on the gadget either. But there are only 3 own plans usable. From 4th own plan on all others will be ignored. Either the buttons are unused if no matching plan is available.

Beyond this, the next version of this gadget should give you the possibility to switch between several themes. But this is still heavy on work and the function isn’t included in this Beta yet.

Who want to test this Beta1 can download it with the link below.

I wish you much fun with testing this beta and will be happy about comments from you.