Fixlet Newbie How To Question

(imported topic written by boostaz191)

I have system property defined as physical location and I would like to ask the end user for this piece of information but I dont know if its possible for a fixlet to have that type of interaction with the end user.

The only solution I could think of would be to have a fixlet run a VBS file that gathered the data into a txt file and then have the fixlet read the data from there…

The last part of this problem is how then do I write the gathered information to the systems property previously defined?

(imported comment written by boostaz191)

PS. Here is the VBS I may have to use…

Dim RetValue(2)

Dim location

RetValue(1) = InputBox(“Please enter the buidling # where your computer is located”,“Location”)

Select Case RetValue(1)

Case 2

RetValue(2) = InputBox(“Are you located on floor 1 or 2?”,“Location”)

Case 15

RetValue(2) = InputBox(“In which bay are you located?” & vbCrLf & “A,B,C,D,F,G,H,I,J,K,L,M,N,O,P,Q,-5,-8”,“LOCATION”)

End Select

Location = "Bldg " & RetValue(1) & “-” & UCase(RetValue(2))

(imported comment written by jessewk)

bosstaz1,

Looks like you are on the right path. A VB script is an excellent way to accomplish simple tasks that require end user input. Just be careful to make sure the action will complete in a reasonable amount of time. You should either set a time out in your VB script, or launch the script with ‘run’ instead of ‘wait’ so that the client won’t wait for the proccess to complete before moving on to other tasks.

I would suggest that you store the final result in the registry instead of a text file. It’s a little faster to access and should be universally available in an identical location across Windows OSes. It will make your relevance simplier and also it is less likely that a user will delete/change the values manually.

-Jesse

(imported comment written by boostaz191)

Excellent! Thanks for the help

(imported comment written by SystemAdmin)

Either way (text file or registry), you can make the relevance for your action include a check to see if that value exists or not. Then set the action to reapply if it becomes relevant again and make it a policy action so it’s always running and can pick up on new machines or if the value gets wiped out for some reason.

Jim