Get Computer Name

dazza5621's picture

Is there a Get Computer Name component that reads local variables? have searched around but can't find one. if not does anybody know a way to achieve this.

Thanks
Dazza

Steve Wayment's picture

Are you trying to get a

Are you trying to get a computer name based off of IP or User?  Or are you wanting to fetch specific Computer data tied to the host name provided by a variable?  I guess it depends on what you mean when you say you want the component to "read" a variable.  Many of the Computer components allow variables to pass data into the process.

Can you explain what you are trying to do in more detail?

reecardo's picture

You might want to explore the

You might want to explore the Diagnostics library (not imported by default). There's a component in there called GetComputerInfo that might be what you're looking for.

PeeGee's picture

Thanks reecardo. This works

Thanks reecardo.
This works fine, as long as I run in the debugger. However, once the workflow is published to the IIS, the component always returns the values of the Workflow Server and not of the user who is actually running it. I also tried to enforce authentication via the web.config and IIS settings, but it won't change that behaviour.

Do you have a hint, how I can force the component to get values from the computer of the user, who is actually running the workflow and not always from the server?

dazza5621's picture

Thanks

There is a component under Input/Ouput that is called "Pick Up Environmet Variables" I didn't see this before, I have configured this to read the COMPUTERNAME Variable, works a treat

Many Thanks for the pointers

Bondo's picture

IIS Change?

Hey Daz,

Did you have to make any changes on IIS to get this to work.  When I use the COMPUTERNAME variable and run the project I get the IIS Server name returned back to me.  Any help would be appreciated.

Thanks

claus66's picture

Get computer name with javascript

Hi

You cannot get the Computername with the built in components.

I've written an article on how to use javascript to get computername (and ns-computerguid):

http://www.symantec.com/connect/articles/how-get-computername-and-guid

Hope you can use it.