actually sir,
i am working with automation and i need to send any e-mail or message on any mobile, on some critical event failure. what my software can do is integration with Vb-script.
can u help me on this code .
what i written is this:-
Code:
Sub OnMouseUp(x As Long, y As Long, flags As Long)
Dim objOutlookMsg As Object
Const olFolderContacts = 10
  sDistName = "ipms" 'set the distribution list name here
  
  Set objOutlook = CreateObject("Outlook.Application")
  Set objNamespace = objOutlook.GetNamespace("MAPI")
   Set objOutlookMsg = objOutlook.CreateItem(0)
  Set colContacts = objNamespace.GetDefaultFolder(olFolderContacts).Items
  intCount = colContacts.Count
	   For i = 1 To intCount
      If TypeName(colContacts.Item(i)) = "DistListItem" Then
          Set objDistList = colContacts.Item(i)
          sEmails = ""
          If objDistList.DLName = sDistName Then
              For j = 1 To objDistList.MemberCount
                  sEmails = sEmails & ";" & objDistList.GetMember(j).Address
              Next
  	  with objOutlookMsg.To="vipin.gupta@incat.com"
              
              			  with objOutlookMsg.send

			          End If
      End If
  Next

End Sub
so can u

Last edited by shabbir; 20Aug2007 at 13:51.. Reason: Code block