Hi I was able to dig through some codes for executing processes in VBA...even though I don't get any error...is there anyway that you can help me troubleshoot the codes to get them working?
Sub Representation_Warning()
Dim Representation_Remark As Range
If Range("Representation_Remark").Text = "Beyond Allowable Expense" Then
'MESSAGE BOX
Select Case MsgBox("The Representation Expense is Beyond its allowed expense limit. Would you like to approve this expense?", vbExclamation + vbYesNo, "Representation Expense Warning !")
Case vbYes
Select Case MsgBox("Are you sure you would like to approve this Representation Expense", vbQuestion + vbYesNo, "Representation Expense Approval ?")
Case vbYes
vbaTm1ExecuteProcess "Apps", "APPROVE_representation", 4, Sheet2.Range("C2"), Sheet2.Range("C3"), Sheet2.Range("C4"), Sheet2.Range("C5")
MsgBox ("You have approved the Representation Expense Budget")
Case vbNo
End Select
Case vbNo
MsgBox ("Kindly have the Sales Personnel responsible to adjust the expense")
End Select
End If
End Sub
If you're having trouble running a process then it's not with this section of code, it's the "vbaTm1ExecuteProcess" function. You'll need to work your way through that function and get it to return the data that you need.
Alternatively there's some semi-supported code for running a TI process, including some error handling, here: http://forums.olapforums.com/viewtopic. ... 410#p15379 (I say semi supported because it's developed and used by people from the forum so a few people know what it does fairly well).
Martin
Please do not send technical questions via private message or email. Post them in the forum where you'll probably get a faster reply, and everyone can benefit from the answers. Jodi Ryan Family Lawyer