sweetblood has asked for the wisdom of the Perl Monks concerning the following question:
I have tried various forms of the string, but I still receive the following error message. I have a feeling that this is one of those really simple bugs that 2 eyes are just not enough to see. If anyone else sees something please let me know. Thanks!#!/usr/bin/perl -w use strict; my $un = 'steve gilbert'; my $jpeg = 'v:/employee photos/out/steve gilbert.jpg'; my $result = `c:\\windows\\system32\\windowspowershell\\v1.0\\powershe +ll.exe -command "Set-ADUser $un -Replace @{thumbnailPhoto=([Byte[]](G +et-Content $jpeg -Encoding Byte))}"`;
syntax error at C:\Users\steveg\adimg-test.pl line 5, near "Byte[" Execution of C:\Users\steveg\adimg-test.pl aborted due to compilation +errors.
Sweetblood
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Error compiling script running powershell command
by NetWallah (Canon) on Dec 29, 2017 at 05:53 UTC | |
|
Re: Error compiling script running powershell command
by Happy-the-monk (Canon) on Dec 28, 2017 at 23:27 UTC | |
|
Re: Error compiling script running powershell command
by Laurent_R (Canon) on Dec 28, 2017 at 23:47 UTC | |
|
Re: Error compiling script running powershell command
by huck (Prior) on Dec 28, 2017 at 23:25 UTC | |
|
Re: Error compiling script running powershell command
by dasgar (Priest) on Dec 29, 2017 at 01:33 UTC |