Search found 14688 matches

by jvierra
Tue Jan 19, 2021 11:36 am
Forum: PowerShell
Topic: ListView items set forecolor
Replies: 4
Views: 1278

Re: ListView items set forecolor

If I remember correctly you will have to create ne3w2 color objects and font objects so the objects are references and not static objects. The API ignores these if they are of the wrong type. $c = [system.drawing.color]::FromKnownColor('Black') Here is another way to add colored items: $items=@( [PS...
by jvierra
Tue Jan 19, 2021 8:10 am
Forum: PowerShell GUIs
Topic: Simple GUI
Replies: 1
Views: 178

Re: Simple GUI

Sorry but there is not enough information to answer your question.

Suggestion: To do repeated actions in a form use a timer tick.
by jvierra
Tue Jan 19, 2021 8:08 am
Forum: VBScript
Topic: Download files from FTP
Replies: 2
Views: 460

Re: Download files from FTP

It is possible however, I recommend using PowerShell as VBScript is no longer a useful language on modern systems.
by jvierra
Mon Jan 18, 2021 7:02 am
Forum: PowerShell
Topic: Disable/Enable AD user account from CSV
Replies: 1
Views: 884

Re: Disable/Enable AD user account from CSV

"-contains" only works for collections. Use "-match" or "-eq".

Here is a good place to start to learn basic PowerShell and programming: https://www.sapien.com/books_training/W ... werShell-4
by jvierra
Sat Jan 16, 2021 11:23 am
Forum: PowerShell GUIs
Topic: persitence cheked checklistbox
Replies: 3
Views: 174

Re: persitence cheked checklistbox

No. You will have to recheck them.
by jvierra
Fri Jan 15, 2021 8:31 pm
Forum: PowerShell
Topic: INI file
Replies: 10
Views: 2353

Re: INI file

Easiest way is:

Code: Select all

$section = @'
	item1=text1
    item2=text2
    item3=text2
'@

$section | Out-File file.ini -Append 
All else will be taken care of automatically
by jvierra
Fri Jan 15, 2021 8:26 pm
Forum: PowerShell
Topic: INI file
Replies: 10
Views: 2353

Re: INI file

You can't break an ini file by adding a section.
by jvierra
Fri Jan 15, 2021 3:05 pm
Forum: PowerShell
Topic: INI file
Replies: 10
Views: 2353

Re: INI file

To add a section just create the text and add it to the file at the end.
by jvierra
Fri Jan 15, 2021 11:27 am
Forum: PowerShell
Topic: INI file
Replies: 10
Views: 2353

Re: INI file

by jvierra
Wed Jan 13, 2021 2:18 pm
Forum: PowerShell
Topic: INI file
Replies: 10
Views: 2353

Re: INI file

You can download INI file managers from PowerShellGet. Three are a few. Pick the one that suits your needs.