VMware Cloud Community
NeenaJim
Enthusiast
Enthusiast
Jump to solution

Passing a value

NeenaJim_0-1646926114998.png

 

Can someone please help me how to pass the value of $SRUserName in DCU.Access ? 

If I mentioned the value directly then it is accepting it. But through a variable ($SRUserName) it is not passing. 

Labels (1)
0 Kudos
1 Solution

Accepted Solutions
LucD
Leadership
Leadership
Jump to solution

In your 1st snippet you are using single quotes, which means there is no variable substitution.
Try using double quotes.

In your 2nd snippet you are passing an Array, while the parameter expects a String


Blog: lucd.info  Twitter: @LucD22  Co-author PowerCLI Reference

View solution in original post

0 Kudos
2 Replies
LucD
Leadership
Leadership
Jump to solution

In your 1st snippet you are using single quotes, which means there is no variable substitution.
Try using double quotes.

In your 2nd snippet you are passing an Array, while the parameter expects a String


Blog: lucd.info  Twitter: @LucD22  Co-author PowerCLI Reference

0 Kudos
NeenaJim
Enthusiast
Enthusiast
Jump to solution

Hello @LucD ,

Thank you very much. You are correct 100%. I missed "" 🙂

0 Kudos