Freelance Project Requests Software Development in C# WPF Asp.Net Core Vba Excel Word SQL-Server EF Linq, UWP Net

Code 450:



For the user of the code: objEmail.Session.Accounts(sEmail_From)


Error: 450

Description : "Incorrect number of arguments or invalid assignment to a property" : String : modEmail.Send_Email_to_Address


Solution: 1) enter either with Acounts.Item(Email_From) or two parameters, namely the email and display name


'< outlook >

'*Ohne Verweis

'*Outlook versionsunabhaengig, Late Binding

Dim app_Outlook As Object

Set app_Outlook = CreateObject("Outlook.Application")

    Dim objEmail As Object

Set objEmail = app_Outlook.CreateItem(0)


'    '*Mit Verweis

'    '* bei Verwendung von Outlook mit Verweis Early Binding

'    Dim app_Outlook As Outlook.Application

'    Set app_Outlook = New Outlook.Application

'    Dim objEmail As MailItem

'    Set objEmail = app_Outlook.CreateItem(olMailItem)


   '</ outlook >


    '< Sender >

    Dim sEmail_From As String

sEmail_From = ActiveWorkbook.Names("varEmail_From").RefersToRange.Value2


Dim sName_From As String

sName_From = ActiveWorkbook.Names("varName_From").RefersToRange.Value2


'objEmail.SentOnBehalfOfName = sEmail_From

If Not sEmail_From Like "" Then

objEmail.SendUsingAccount = objEmail.Session.Accounts(sEmail_From)

End If

'</ Sender >



The error occurs in the application



Contact for Jobs, Project Requests: