Searching for VB Code to Link to Program

P

PM_24_7

HELP!!!

I am seeking help on linking to another program from a
message box "OK" button...

I have created a macro that is linked to a check off sheet
so that when the user clicks on a "no" response, a message
box pops up telling them what they need to do. I want to
link the "OK" button to the pathway that takes them to the
application that they need to go to... My code looks like
this...

Sub Formlink()
'make sure we want the report.
answer = Notify("Link Form To Task.")

'If user clicks OK, link to PowerChart.
If anser = vbOK Then
Application.Open_ "M:\WININTEL\DCPtools.exe"
End If
End Sub
'Standard message box.
Function Notify(msg)
'title.
msgboxTitle = "Directions:"
'buttons and icon.
btns = vbOKCancel
Notify = msgbox(CStr(msg), btns, msgboxTitle)
End Function

Sub Template()
'capture the app
UseTerminalApp
ImportStockFile
FormatStockData
FormatChart
PrintChart

End Sub

It doesn't work...I don't know how to link to an
application from a message box button...

Thanks in advance to anyone!!!

PM_24_7
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top