Jump to content

zipster1967

Members
  • Posts

    3
  • Joined

  • Last visited

Reputation

0 Neutral

About zipster1967

Personal Information

  • Occupation
    Network Technician
  • Location
    Ellsworth
  1. I have scripts that get a playlist and one that retrieves the filenames both with and without the extension from the playlist file. now I just need to use the filenames without extension to populate a checkedlistbox in a windows from. This is my 2 scripts $Path = 'C:\Users\Trent\Music\Playlists' Get-ChildItem $Path -Filter "*.m3u" | Where-Object { $_.Attributes -ne "Directory"} $PlaylistName = 'C:\Users\Trent\Music\Playlists\3LW.m3u' Get-Content $PlaylistName | ? { $_ -and (Test-Path $_) }| Get-Childitem | Select Name I just do not understand how to use my script in a checkedlistbox control. Please help me understand how to accomplish this.
  2. I have a script I found doing a search to lookup a folder in a powershell form but I cannot get it to access the folders I want and I am not sure what I am doing wrong. $newShell = new-object -com shell.application $objFolder = $newShell.NameSpace("MyMusic") $namedfolder = $newShell.BrowseForFolder(0,"Select Song files destination folder:",0,5) write-host $namedfolder.self.path No matter what I put in the .NameSpace"(MyMusic") portion the dialog opens to my Documents folder. What am I not understanding about this function/script?
  3. I would like my script to have certain settings that can be changed by the user if they want or left as is from the last time they changed them. (i.e. setting a default folder that is looked to every time a certain type of file is opened. Say user 1 has there word documents in C;\Users\Documents\Word\ while user 2 keeps their word documents on a USB drive F:\word Documents Is there a way to have my script open for user 1 to thier word document folder and user 2 open to their usb drive word documents folder? I was thinking about storing those variables in a text file that is different for every user but I am unsure how to import variables from a text file on script startup. Any suggestions on this? Also is there any good tutorials on scripting for powershell that help a newbie learn how to write scripts and gives different examples on using powershell comands in scripts? or maybe a compendium of powershell commands syntax for scripts?
×
×
  • Create New...