Jump to content
Software FX Community

marco.shaw

Members
  • Posts

    249
  • Joined

  • Last visited

Posts posted by marco.shaw

  1. The only way I could see this being done is to send a direct stop/kill to the PowerGadgets process.  Then you would call your other PGF files to open up your new dashboard.

    Not an elegant solution, and I'm concerned killing processes (any process, not just PowerGadgets) could lead to unpredictable results in the longer term.

    I this something you're going to be looking at doing at very short intervals?

  2. Please open the PowerGadgets Creator, go to Help, then About PowerGadgets.  Please check the version you are currently running, and compare that against the version you had running on XP (if you can).

    This feature is known as scriptblocks.  Not all parameters accept scriptblocks and I believe that support for it improved with later releases as more and more parameters provided support for it.

  3. I did try a very basic test, and I do agree that it appears that if you call out-chart from a PowerShell script versus what things end up looking like when use the creator wizard can be a bit different.

    I may try to come back to think about this at another time (as my free spare time is pretty much zero these days), but it might require getting PG devs involved to confirm the different behavior.

    Either Juan from SoftwareFX may chime in or you may also want to contact support AT powergadgets.com also.

  4. OK, I think I know what's going on..  The .PGF file is just a text file, look at my test when I open it with Notepad:

    ...

      <GadgetVersion>1</GadgetVersion>   <RefreshInterval>10000</RefreshInterval>   <RefreshEnabled>True</RefreshEnabled>   <Data>PowerGadgets.Commands.PowershellSource</Data>   <Data.PrevCommands>& 'c:\users\administrator\desktop\creator.ps1'</Data.PrevCommands>

    ...

    You mentioned you're pasting the PowerShell code into the script window, but I think you should be referencing a PowerShell script as I do above.

    That script just has this as contents:

    gps powershell|select processname,cpu

     

  5. Is it possible to have a sound file played when the data changes? For example when a counter is increased we want to hear once sound and then when the counter decreases we would like to hear another sound.

    Thanks,
    Ted

     

    Actually, how are you using PowerGadgets?  Are you using a .ps1 PowerrShell script and passing that to one of the out-* cmdlets using a refresh value?

    Yes, I do think you can set up such a audio alarm using a trick like I do HERE with global variables.

  6. foreach ($i in 0..$NUMITEMS) {

    add-member -inputobject $aItem -membertype NoteProperty -Name $entry.Key -value $entry.Count  # or $entry.Value

     

    I've just left 2 lines of interest...  I'm not sure where you get $NUMITEMS.  Would that be this instead:

    foreach($i in 0..$names.count)

    That may still leave you with an offset of 1.

    For your add-member command, I believe you should have:

    ...-name $entry.keys -value $entry.values

×
×
  • Create New...