myITforum.com Community Forum myITforum.com Community Forum

Home  Forums  Blogs  Live Support chat  Search Articles  Wiki  FAQ  Email Lists  Register  Login  My Profile  Inbox  Address Book  My Subscription  My Forums 

Photo Gallery  Member List  Search  Calendars  FAQ  Ticket List  Log Out

All Forums RSS Feed Subscription:


  


Remote Assist button on system details page?

 
View related threads: (in this forum | in all forums)

Logged in as: Guest
  Printable Version
All Forums >> [Management Products] >> Microsoft Systems Management Server >> SMS 2003 >> Remote Assist button on system details page? Page: [1]
Login
Message << Older Topic   Newer Topic >>
Remote Assist button on system details page? - 1/8/2007 12:02:33 PM   
cldpeak

 

Posts: 270
Score: 6
Joined: 7/11/2002
Status: offline
I think it was imagination now, perhaps I mistook Ron Crumbaker's WebRemote Console for it...

I've been looking for an article that detailed how to add a remote assist button to the SMS 2003 web report machine details page... does it exist?

Thanks!

Ray
Post #: 1
RE: Remote Assist button on system details page? - 1/8/2007 2:35:50 PM   
eschloss


Posts: 616
Score: 25
Joined: 9/7/2004
From: Cincinnati
Status: offline
Create a button to launch Remote Assistance

<input style="WIDTH: 180px" type="button" value="Remote Assistance" name="Btnl10" ID="Button8">

and add thus sub at the bottom

Sub Btnl10_OnClick
dim CompName
set wshshell = createobject("wscript.shell")
CompName = document.frmMain.txtValue.value
If len(Trim(CompName)) = 0 then
 MsgBox "Please type a Machine Name.",,"System Resources"
 WScript.Quit
End If
WshShell.Run "%windir%\pchealth\helpctr\binaries\helpctr.exe -FromStartHelp " & _
"-url hcp://CN=Microsoft%20Corporation,L=Redmond,S=Washington,C=US/Remote%20Assistance/Escalation/unsolicited/SMSUnsolicitedRCUI.htm " & _
"-ExtraArgument " & "NOVICECOMPUTER=" & CompName & """"
End Sub

(in reply to cldpeak)
Post #: 2
RE: Remote Assist button on system details page? - 1/8/2007 5:22:39 PM   
cldpeak

 

Posts: 270
Score: 6
Joined: 7/11/2002
Status: offline
Thanks!

Looks like it would work, except I discovered that I can't just simply add it to the mach details asp file, nor to the style sheets and have it appear.

I did some success where it was placed at the top, but was covered up with the "Computer Details" title...

What filename and where in the file did you have the best luck inserting the button tag?

(in reply to eschloss)
Post #: 3
RE: Remote Assist button on system details page? - 1/9/2007 7:09:08 PM   
cldpeak

 

Posts: 270
Score: 6
Joined: 7/11/2002
Status: offline
Okay,

Now I see that the example you posted is from Ron Crumbaker's web remote tools... - but it did get me on the right track!

In my case, to add this button to the Computer Details report in SMS 2003 Reporting, you will need to:
Edit Inetpub\WWWRoot\SMSReporting_XXX\ReportsNav.asp
Search for the string "</BUTTON>" (without quotes)
This should put you near the end of <DIV class=ComputerNameBox>, right after where the value button is defined.
Make some slight modifications to the example button line to match the style of the values button:
<input style="margin-left: 8px" class=ValuesButton type="button" value="Remote" name="Btnl10" ID="Button8">
Insert this line between </BUTTON> and </DIV>
It should look like this snippet taken from my ReportsNave.asp:
<DIV id=divComputerNameBlock style="display:<%
If sMachineDetails = "True" Then
 Response.Write "block"
Else
 Response.Write "none"
End If%>">
<DIV class=ComputerNameBox>
 <DIV style="margin-bottom: 5px">
  <LABEL class=SimpleTextSmall id=lblComputerPrompt for=MachineName>
   <%=Server.HTMLEncode(fMsg.FormatModuleString(sDll, IDS_RWPT_COMP_NAME))%><br>
   <%=Server.HTMLEncode(fMsg.FormatModuleString(sDll, IDS_RWPT_REDUCE_VALUES))%>
  </LABEL>
 </DIV>
 <INPUT id=MachineName name=MachineName type=text class=InputBox tabindex=0 value="<%
 If sMachineDetails = "True" Then
  Response.Write Server.HTMLEncode(sMachine)
 End If%>" LANGUAGE=javascript onkeypress="return MachineName_onkeypress()">
 <BUTTON id=btnBrowse style="margin-left: 8px" class=ValuesButton tabindex=0 LANGUAGE=javascript onclick="return btnBrowse_onclick()" disabled>
  <%=Server.HTMLEncode(fMsg.FormatModuleString(sDll, IDS_RWPT_STND_RPT_FLTR))%>
 </BUTTON>
               <input style="margin-left: 8px" class=ValuesButton type="button" value="Remote" name="Btnl10" ID="Button8"> 
</DIV>
</DIV>


Next, we must take the sample code and modify it a bit to read the value that was in the Computer Details text box.  It can also be placed near the very end of ReportsNav.asp right after </BODY> but before </Script> and </HTML>.  Finally, I added script language parameter, the end of ReportsNave.asp should end up looking like this:

<%End If%>
<INPUT type=hidden id=txtReportID name=txtReportID value="0" tabindex=-1>
<INPUT type=hidden id=txtVariableName name=txtVariableName value="" tabindex=-1>
<INPUT type=hidden id=txtPrompt name=txtPrompt value="" tabindex=-1>
</BODY>
<Script Language=vbscript>
Sub Btnl10_OnClick 
dim CompName
Dim wshshell 
set wshshell = createobject("wscript.shell") 
CompName = document.all("MachineName").value 
If len(Trim(CompName)) = 0 then 
MsgBox "Please type a Machine Name.",,"System Resources" 
WScript.Quit 
End If 
WshShell.Run "%windir%\pchealth\helpctr\binaries\helpctr.exe -FromStartHelp " & _ 
"-url hcp://CN=Microsoft%20Corporation,L=Redmond,S=Washington,C=US/Remote%20Assistance/Escalation/unsolicited/SMSUnsolicitedRCUI.htm " & _ 
"-ExtraArgument " & "NOVICECOMPUTER=" & CompName & """" 
End Sub 
</Script>
</HTML>


On the client side internet explorer 6 browser, At first, the button seemed to take no action when clicked.  However, in the lower left of IE a yellow script error icon, double click and show details, reveals an error "ActiveX component can't create object: 'wscript.shell'

This can also be solved by the IE browser menu bar: Tools | Internet Options | Security Tab | Local internet
Review "ActiveX controls and plug ins" some may be disabled, such as "Download unsigned ActiveX controls", "initialize and script..." etc... Enable these or add to trusted sites.

(in reply to cldpeak)
Post #: 4
RE: Remote Assist button on system details page? - 3/27/2008 4:45:53 PM   
sfrechette

 

Posts: 5
Score: 0
Joined: 3/27/2008
Status: offline
SMS2003, one primary site
http://www.myitforum.com/forums/m_148605/tm.htm

I did the steps to put a 'remote' button on the MachDetails.asp page and it works fine. For one person. On one PC. On my desktop PC I have the admin console installed and the page will work with my IE settings. When I allow scripts, etc. as recommended on any other PC, I get the script to run, but then I get the remote assistance popping up that says "cannot display the page". All PCs have the exact same group policies, etc. applied, so I'm definately at a loss here.

Any quick thoughts?

(in reply to cldpeak)
Post #: 5
RE: Remote Assist button on system details page? - 3/31/2008 3:32:52 AM   
Tom_Watson

 

Posts: 118
Score: 9
Joined: 9/13/2006
Status: offline
One thing to note is that the ASP edit is basically calling Help and Support Center with specific switches through that button :-

quote:

WshShell.Run "%windir%\pchealth\helpctr\binaries\helpctr.exe -FromStartHelp " & _
"-url hcp://CN=Microsoft%20Corporation,L=Redmond,S=Washington,C=US/Remote%20Assistance/Escalation/unsolicited/SMSUnsolicitedRCUI.htm " & _
"-ExtraArgument " & "NOVICECOMPUTER=" & CompName & """"


If these other PCs don’t have the admin console installed, they won’t have that “SMSUnsolicitedRCUI.htm” file in the correct folder.  Simply copy that file from your PC (or the server), to the other PCs.  The folder is “C:\WINDOWS\PCHealth\HelpCtr\Vendors\CN=Microsoft Corporation,L=Redmond,S=Washington,C=US\Remote Assistance\Escalation\Unsolicited”.

Regards,
Tom Watson

(in reply to sfrechette)
Post #: 6
RE: Remote Assist button on system details page? - 3/31/2008 7:50:35 AM   
skissinger


Posts: 2119
Score: 134
Joined: 9/13/2001
From: Sherry Kissinger
Status: offline
Untested (I use Ron's page), but try replacing the section with this.  Be careful of word wrap!  Also, there's a declared variable for the file source for the smsunsolicitedrcui.htm file; place that file on a server\share where the users of this page will have at least read rights to the file, and update that variable.

quote:

<%End If%>
<INPUT type=hidden id=txtReportID name=txtReportID value="0" tabindex=-1>
<INPUT type=hidden id=txtVariableName name=txtVariableName value="" tabindex=-1>
<INPUT type=hidden id=txtPrompt name=txtPrompt value="" tabindex=-1>
</BODY>
<Script Language=vbscript>
Sub Btnl10_OnClick
dim CompName
Dim wshshell
set wshshell = createobject("wscript.shell")
Set fso = CreateObject("Scripting.FileSystemObject")
strWindir = wshell.expandenvironmentstrings("%windir%")
strSMSUnsolicitedFileSource = "
\\<server>\<someShare>\smsunsolicitedrcui.htm"
StrSMSDir = strwindir & "\PCHEALTH\HELPCTR\Vendors\CN=Microsoft Corporation,L=Redmond,S=Washington,C=US\Remote Assistance\Escalation\Unsolicited"
strSMSFile = strSMSDir & "\smsunsolicitedrcui.htm"
CompName = document.all("MachineName").value
If len(Trim(CompName)) = 0 then
MsgBox "Please type a Machine Name.",,"System Resources"
WScript.Quit
End If
if fso.fileExists(strSMSFile) Then  
WShell.Run strWindir & "\pchealth\helpctr\binaries\helpctr.exe -FromStartHelp " & _
  "-url hcp://CN=Microsoft%20Corporation,L=Redmond,S=Washington,C=US/Remote%20Assistance/Escalation/unsolicited/SMSUnsolicitedRCUI.htm " & _
  "-ExtraArgument " & "NOVICECOMPUTER=" & CompName & """"
else
fso.copyFile strSMSUnsolicitedFileSource,strSMSFile
if fso.fileExists(strSMSFile) Then  
  WShell.Run strWindir & "\pchealth\helpctr\binaries\helpctr.exe -FromStartHelp " & _
  "-url hcp://CN=Microsoft%20Corporation,L=Redmond,S=Washington,C=US/Remote%20Assistance/Escalation/unsolicited/SMSUnsolicitedRCUI.htm " & _
  "-ExtraArgument " & "NOVICECOMPUTER=" & CompName & """"
else
wshell.run "hcp://CN=Microsoft%20Corporation,L=Redmond,S=Washington,C=US/Remote%20Assistance/Escalation/Unsolicited/unsolicitedrcui.htm"
end if
End if

End Sub
</Script>
</HTML>


< Message edited by skissinger -- 3/31/2008 7:51:12 AM >


_____________________________

mofmaster@smsexpert.com (version 2007) | http://www.smsexpert.com | http://www.sccmexpert.com
My Blog
Microsoft MVP - ConfigMgr

(in reply to Tom_Watson)
Post #: 7
RE: Remote Assist button on system details page? - 3/31/2008 8:09:16 AM   
Tom_Watson

 

Posts: 118
Score: 9
Joined: 9/13/2006
Status: offline
Cool edit.  Just thinking....

Would \\ServerName\SMS_XXX\bin\i386 work as the share (XXX being the site code)??

Regards,
Tom Watson

(in reply to skissinger)
Post #: 8
RE: Remote Assist button on system details page? - 3/31/2008 8:18:23 AM   
Tom_Watson

 

Posts: 118
Score: 9
Joined: 9/13/2006
Status: offline
Maybe not, unless the person calling is also an Administrator for the server.

Tom

(in reply to Tom_Watson)
Post #: 9
RE: Remote Assist button on system details page? - 3/31/2008 9:00:32 AM   
Tom_Watson

 

Posts: 118
Score: 9
Joined: 9/13/2006
Status: offline
Here's what worked on my server:-

quote:

<%End If%>
<INPUT type=hidden id=txtReportID name=txtReportID value="0" tabindex=-1>
<INPUT type=hidden id=txtVariableName name=txtVariableName value="" tabindex=-1>
<INPUT type=hidden id=txtPrompt name=txtPrompt value="" tabindex=-1>
</BODY>
<Script Language=vbscript>
Sub Btnl10_OnClick
dim CompName
Dim wshshell
set wshshell = createobject("wscript.shell")
Set fso = CreateObject("Scripting.FileSystemObject")
strWindir = wshshell.expandenvironmentstrings("%windir%")
strSMSUnsolicitedFileSource = "\\ServerName\SMS_XXX\bin\i386\smsunsolicitedrcui.htm"
StrSMSDir = strwindir & "\PCHEALTH\HELPCTR\Vendors\CN=Microsoft Corporation,L=Redmond,S=Washington,C=US\Remote Assistance\Escalation\Unsolicited"
strSMSFile = strSMSDir & "\smsunsolicitedrcui.htm"
CompName = document.all("MachineName").value
If len(Trim(CompName)) = 0 then
MsgBox "Please type a Machine Name.",,"System Resources"
WScript.Quit
End If
if fso.fileExists(strSMSFile) Then 
WshShell.Run "%windir%\pchealth\helpctr\binaries\helpctr.exe -FromStartHelp " & _
"-url hcp://CN=Microsoft%20Corporation,L=Redmond,S=Washington,C=US/Remote%20Assistance/Escalation/unsolicited/SMSUnsolicitedRCUI.htm " & _
"-ExtraArgument " & "NOVICECOMPUTER=" & CompName & """"
else
fso.copyFile strSMSUnsolicitedFileSource,strSMSFile
if fso.fileExists(strSMSFile) Then 
WshShell.Run "%windir%\pchealth\helpctr\binaries\helpctr.exe -FromStartHelp " & _
"-url hcp://CN=Microsoft%20Corporation,L=Redmond,S=Washington,C=US/Remote%20Assistance/Escalation/unsolicited/SMSUnsolicitedRCUI.htm " & _
"-ExtraArgument " & "NOVICECOMPUTER=" & CompName & """"
else
WshShell.Run "%windir%\pchealth\helpctr\binaries\helpctr.exe -FromStartHelp " & _
"-url hcp://CN=Microsoft%20Corporation,L=Redmond,S=Washington,C=US/Remote%20Assistance/Escalation/unsolicited/unsolicitedrcui.htm"
end if
End if
End Sub
</Script>
</HTML>


You could of course replace the \\ServerName\SMS_XXX (where XXX is the site code, and ServerName is - well you get the point), with a share of your choice.

Regards,
Tom Watson

< Message edited by Tom_Watson -- 4/1/2008 6:52:01 AM >

(in reply to Tom_Watson)
Post #: 10
Page:   [1]
All Forums >> [Management Products] >> Microsoft Systems Management Server >> SMS 2003 >> Remote Assist button on system details page? Page: [1]
Jump to:





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts



  
Forum Software © ASPPlayground.NET Advanced Edition 2.4.5 ANSI

0.234