User Profile
itsmesri
Brass Contributor
Joined 7 years ago
User Widgets
Recent Discussions
How to add user(s) to distribution list group in Office 365 using C#?
I am creating one distribution list for Unsubscriber and dynamically wants to add external user(s) to that group so in the future no email goes to those users. How to do with programming c#? Please help me out with sample code.7.1KViews0likes3CommentsRe: Families gathering expenses calculation in Excel?
Riny_van_Eekelen this is not telling me payment for games whom to pay to whom. If A need to B - $10 and A need pay to C - $10. Sometimes B to A - $15 and C-A - $8 like this. in food also B and C need to pay A - split equal because A paid for food.820Views0likes1CommentFamilies gathering expenses calculation in Excel?
We have 3 families gathers every weekend and play cards and food sharing. So it is difficult to calculate every weekend expenses. Example A, B and C are family. 1st week A spent food = x amount. A, B and C has share equally 1st week (games) A , B need to pay to C = x amount 2nd week B spent food = x amount. A, B and C has share equally 2nd week (games) A need pay to B = x amount. C need to pay to A = y amount 3rd week C spent food = x amount. A, B and C has share equally 3rd week (games) C need pay to B = x amount. B need to pay to A = y amount like this .. anything can happen so just need to maintain expenses every week and settle month end with total whom to whom. I don't know how to do in Excel. If possible share excel template to me.Solved865Views0likes3CommentsRe: How to add Shared mailbox as new account in Office 365/Outlook2019?
PeterRising I am getting Shared Mailboxes along with My mailbox in outlook. But the issue is I cannot create signatures for Shared Mailbox. I am looking when I compose a new email from the shared mailbox signature automatically populate.2.2KViews0likes4CommentsHow to add Shared mailbox as new account in Office 365/Outlook2019?
I have shared mailbox "info@xxx.com" for "mainaccount@xxx.com". But when I am trying to add "info" account from account settings. It is opening web interface login. If I give "mainaccount" password it is not working. How to add a shared mailbox like a regular box. I need separate signature for shared mailbox.2.3KViews0likes6CommentsHow to remove shared mailbox from main mailbox?
I have "info@xxx.com" and I have all permissions on it. After adding to my account to outlook "info" also coming with it. I want to remove here and add from "Account Settings". I already removed from Advance tab and Close account directly from the folder. Both didn't work. Any other solutions not come along with Main account?7.5KViews0likes6CommentsCan Teams channel Office 365 group works as a distribution list?
My requirement is send email to all teams channel members to outlook (Not teams). In admin portal it says "Office 365" group for Teams channel and also it has Primary email address too. But when I am sending email to that email address no one getting email. I know we have "Get Email Address" from Channel (which weird email address) but that address will send to Teams not to outlook. I am looking Office 365 group should work like distribution list by using Primary email address for channel? Is that possible to send13KViews1like4CommentsEAC rule for blocking only outgoing emails
I have written rule to block emails if he/she in the group. It is working fine. But we want to stop email going out from our domain. But incoming should be all clear no stopping them with this rule. How to modify this rule to check only out going email not incoming emails.648Views0likes0CommentsRe: Why my Office 365 email going to junk or spam in Gmail?
Ricardo Viana We never had Gsuite. We used to have our own in-house opensource exchange and than moved to O365. I am attaching header her. Original Message Message IDCreated at:From:To:Subject:SPF:DKIM:DMARC: <em25bacbbf-f876-4066-9cf5-ef1699f2f5ef@sxxxxxx> Tue, Nov 5, 2019 at 9:26 AM (Delivered after 3 seconds) <xxxx@intensifytech.com> "xxxxx@gmail.com" <xxxxx@gmail.com> test email PASS with IP 40.107.139.70 Learn more 'PASS' with domain intensifytech.com Learn more 'PASS' Learn more Delivered-To: xxxxx@gmail.com Received: by 2002:a1c:c916:0:0:0:0:0 with SMTP id f22csp849867wmb; Tue, 5 Nov 2019 07:26:45 -0800 (PST) X-Google-Smtp-Source: APXvYqxmpepdg5GdekjgdEemKz2SkrpeGlHMkPwxWzF9T68i1n50nK+LY2QxbSLg0bIc/+Pqmuir X-Received: by 2002:a62:5258:: with SMTP id g85mr37112919pfb.180.1572967605133; Tue, 05 Nov 2019 07:26:45 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1572967605; cv=pass; d=google.com; s=arc-20160816; b=H1IxnPISDFoKFP8xORu6P8XlNOHs5zv7AdLvhCPw6s1zZsvaUxFo4fihgIgyOiaqWF LszySIhr3pfJKi5SYkQoxqaHW62hCbnUHkxlRvd62tzFca7VaJ9M6kPU00izU2Yj2921 CRwQ4kIqRUYdhQDVjlhLL3yP2SiyY/Z2bTFTRM8X7r9H8zFRIVMtiNT7MuMXkxrvlwiH 4Yngk63viLs3NYuIePdpaQsEm7UJvPX8P6HEqAdrGDTcl0cjD4ExzYUmra0D3jK/gu1j j2JcxynHwTKGd/hk+UwudJ/XZiB4cd+k6ju3Dgb6ZOIRVlY70lncEuNlMNGgXABqy30K SBkg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=mime-version:content-language:accept-language:reply-to:message-id :date:thread-index:thread-topic:subject:to:from:dkim-signature; bh=FY/QQaHKZFf8+VhLn9dTOiHORfchu53rZSUmIftch1s=; b=xayoQ43yQN2vN3yH2GrQyonvZP0Fm2vPPvux+/5YHrpyGxIzuEfSw3BnIA58AsMi8D PSe+Z1g8E9mbS4BDQRa03TYVdchrDwqiVIcqyyGBv0wOGFIz+HYD7n0fXBAAdmdX77U/ dPWn39nfK3+KxV/BoQNU2nIcZJCLZuMH4J0vpNPq3Exww1H62p5GG+ewkuUkHQv4ZmsJ F6vo3JPaxwoaI9sQoy5xbvGANzndCccEDd75aqTgltYX5jdNXur3M4N/fU2mK1o39qpj 6SbeSecx1F1qT/dYVt8jZ+fD9Ck9i8bhKl/ROSJ3fx/+YMkt4Wv9+n/MooGWStFWKSvN CmbQ== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@intensifytech.com header.s=selector1 header.b=uvYEMSDl; arc=pass (i=1 spf=pass spfdomain=intensifytech.com dkim=pass dkdomain=intensifytech.com dmarc=pass fromdomain=intensifytech.com); spf=pass (google.com: domain of xxxx@intensifytech.com designates 40.107.139.70 as permitted sender) smtp.mailfrom=sri@intensifytech.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intensifytech.com Return-Path: <xxxx@intensifytech.com> Received: from IND01-BO1-obe.outbound.protection.outlook.com (mail-eopbgr1390070.outbound.protection.outlook.com. [40.107.139.70]) by mx.google.com with ESMTPS id c6si27725745pfn.180.2019.11.05.07.26.44 for <xxxxxx@gmail.com> (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 05 Nov 2019 07:26:45 -0800 (PST) Received-SPF: pass (google.com: domain of xxxx@intensifytech.com designates 40.107.139.70 as permitted sender) client-ip=40.107.139.70; Authentication-Results: mx.google.com; dkim=pass header.i=@intensifytech.com header.s=selector1 header.b=uvYEMSDl; arc=pass (i=1 spf=pass spfdomain=intensifytech.com dkim=pass dkdomain=intensifytech.com dmarc=pass fromdomain=intensifytech.com); spf=pass (google.com: domain of xxxxx@intensifytech.com designates 40.107.139.70 as permitted sender) smtp.mailfrom=sri@intensifytech.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intensifytech.com ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=EagyPKbdGwybcYrrZcYwqxrVYzu6HJMwBzLnEosuIYBOZpaJsA0l6xtaNLpJ8MdwyHDfOuRVQ1XjGVbOViONtT4m9i4wvl30iA24L23QqFOtREubQgwJlv+03iUfHvROkkrOMPKAw8ckBRMbnzDzUO//Ce06dT1bqofIR9ca/U8r7u9+E6VWWc1JGkOms2Q3plrm2xLHVS6RA44Gk/tRt/4fFNSQyR+EoH19TJaHaBALOxGaERIyo2q1rBLR70KTbxRTXf1sjDDwnocyHgEvV8Krc0SCNW/dte/SEz1AQy7EarKy83UxW1ghHXK31Sz1wUEQEGZOUeVpIUQ4mfINCg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=FY/QQaHKZFf8+VhLn9dTOiHORfchu53rZSUmIftch1s=; b=PLZFKasRGK0icDysHIr8eS2NFBf6VW/Z/W7gCDS4gAihBJtuNTksNWPv/i7/xEMYL13MIExJaXQg2qhTjW/qOjwrNu3RQlTMNvmbIfAodc+IvgtUi0+7GA63Mpc57psbEENbReMmmbQCGogh+2dis1PDwUN5IDbZ8sX4ay7jKCqsciCQgds0sreA8Y6VfiVeafCpR90OG/H1fD0k3VOpdjjDxL9HH0mGR5CNSdi/r08fCZZPHc7sJrIIM8ZwaE9BIrha8Jf9I37ZaHOlLiQ7143MnvkK/SphPeTZPXmhDuGGiT74Qxfrga9fxf9XLWJRb1YvxzZYI1z7T3uhsUVJQw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intensifytech.com; dmarc=pass action=none header.from=intensifytech.com; dkim=pass header.d=intensifytech.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intensifytech.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=FY/QQaHKZFf8+VhLn9dTOiHORfchu53rZSUmIftch1s=; b=uvYEMSDljOtjvIJS1I8IT3Cu7MUt7d1q+Q1cQiojnnP0Z2b1WRryJ6g4iPyXWQgpt6976/N+KVLo596Y48DTreM6ysbjCzAwRav9sUypUiqz0uIrGxtQR0C87hMNSsnw+q8aBd2moL/3v+QNTAl0ZyW498k8l0UUL4qCTzLZb84= Received: from MA1PR01MB0715.INDPRD01.PROD.OUTLOOK.COM (10.174.58.16) by MA1PR01MB4057.INDPRD01.PROD.OUTLOOK.COM (20.179.239.202) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2408.24; Tue, 5 Nov 2019 15:26:43 +0000 Received: from MA1PR01MB0715.INDPRD01.PROD.OUTLOOK.COM ([fe80::c42:cfd3:90cd:5190]) by MA1PR01MB0715.INDPRD01.PROD.OUTLOOK.COM ([fe80::c42:cfd3:90cd:5190%12]) with mapi id 15.20.2408.024; Tue, 5 Nov 2019 15:26:42 +0000 From: xxxxxx <xxxx@intensifytech.com> To: "xxxxxx@gmail.com" <xxxxxxx@gmail.com> Subject: test email Thread-Topic: test email Thread-Index: AQHVk+1tOT1MCLHxfUiP+qbCeBXAvw== Date: Tue, 5 Nov 2019 15:26:42 +0000 Message-ID: <em25bacbbf-f876-4066-9cf5-ef1699f2f5ef@svadlakonda> Reply-To: xxxx <xxxx@intensifytech.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: spf=none (sender IP is ) smtp.mailfrom=xxxxx@intensifytech.com; x-originating-ip: [192.152.183.10] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: a3f6db74-5a33-415a-8dcf-08d762048fe0 x-ms-traffictypediagnostic: MA1PR01MB4057: x-microsoft-antispam-prvs: <MA1PR01MB40576ED4971EB7A142FDCBABBA7E0@MA1PR01MB4057.INDPRD01.PROD.OUTLOOK.COM> x-ms-oob-tlc-oobclassifiers: OLM:1728; x-forefront-prvs: 0212BDE3BE x-forefront-antispam-report: SFV:NSPM;SFS:(10009020)(7916004)(376002)(346002)(39840400004)(136003)(396003)(366004)(38564003)(189003)(199004)(3480700005)(5024004)(4744005)(2351001)(91956017)(6506007)(102836004)(43066004)(2501003)(64756008)(6306002)(1361003)(76116006)(54896002)(316002)(14454004)(99286004)(6436002)(9686003)(66556008)(25786009)(66476007)(6512007)(5640700003)(66946007)(66446008)(236005)(478600001)(486006)(6916009)(6486002)(8676002)(81156014)(81166006)(5660300002)(8936002)(26005)(256004)(14444005)(71200400001)(71190400001)(6116002)(3846002)(3450700001)(66066001)(86362001)(2906002)(33716001)(7736002)(606006)(476003)(7116003)(186003)(221733001)(76236002);DIR:OUT;SFP:1101;SCL:1;SRVR:MA1PR01MB4057;H:MA1PR01MB0715.INDPRD01.PROD.OUTLOOK.COM;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;MX:1;A:1; received-spf: None (protection.outlook.com: intensifytech.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: lC9dWTPUUVXGb9vzIlPdXP9y590kMq+gMRZ6UtN3fXpw580PktIW657MSWJOSBRVXird9+YFkiQRHIFNq9tDufZVlD5+RuiRkIBfcg5HkTslhcn1LljeNFDSA3eT4RN/I5qRrr2gVGRNXlKN7vegt6RDs3RlgVKwjYQCbzPtjJFZ1xhSW6FjFEmq+ZU8B7ijw2H5Fdj7Tmuo/yazAYWVw9dtISeh13RK0RY3G+P5Ty+/p7pFM1GO04xF6+JUJqaS/Ll+PBHHMCvvm0zREez1Xbny7bgbtWb21JLjvhgZ1l/9q8a+xUqMqxYzs+hoaqWT x-ms-exchange-transport-forked: True Content-Type: multipart/alternative; boundary="_000_em25bacbbff87640669cf5ef1699f2f5efsvadlakonda_" MIME-Version: 1.0 X-OriginatorOrg: intensifytech.com X-MS-Exchange-CrossTenant-Network-Message-Id: a3f6db74-5a33-415a-8dcf-08d762048fe0 X-MS-Exchange-CrossTenant-originalarrivaltime: 05 Nov 2019 15:26:42.8704 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 16df5b7c-763c-4dee-8f14-505c1f922afd X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: CVFXlTcw3P+TWZOYLocNGVfPNIjqWfqZHhVBqlCPj8UikiFHnxMlsqU7RqxqlEeYXhHicYln8EupGohAKQaYkA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: MA1PR01MB4057 --_000_em25bacbbff87640669cf5ef1699f2f5efsvadlakonda_ Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: base644.7KViews1like0CommentsRe: How to add user(s) to distribution list group in Office 365 using C#?
Kevin_Morgan I tried using sample code that you gave me. But command fails to me. Any suggestions? string connectionUri = "<a href="<a href="https://outlook.office365.com/powershell-liveid/" target="_blank">https://outlook.office365.com/powershell-liveid/</a>" target="_blank"><a href="https://outlook.office365.com/powershell-liveid/</a" target="_blank">https://outlook.office365.com/powershell-liveid/</a</a>>"; string loginPassword = ConfigurationManager.AppSettings["PWD"].ToString(); string loginUser = ConfigurationManager.AppSettings["UID"].ToString(); SecureString secpassword = new SecureString(); foreach (char c in loginPassword) { secpassword.AppendChar(c); } PSCredential credential = new PSCredential(loginUser, secpassword); Runspace runspace = System.Management.Automation.Runspaces.RunspaceFactory.CreateRunspace(); PowerShell powershell = PowerShell.Create(); PSCommand command = new PSCommand(); command.AddCommand("New-PSSession"); command.AddParameter("ConfigurationName", "Microsoft.Exchange"); command.AddParameter("ConnectionUri", new Uri(connectionUri)); command.AddParameter("Credential", credential); command.AddParameter("Authentication", "Basic"); powershell.Commands = command; runspace.Open(); powershell.Runspace = runspace; Collection<System.Management.Automation.PSObject> result = powershell.Invoke(); if (powershell.Streams.Error.Count > 0 || result.Count != 1) { throw new Exception("Fail to establish the connection"); } powershell = PowerShell.Create(); command = new PSCommand(); command.AddCommand("Invoke-Command"); string DLGroupName = "UnsubscribersList"; command.AddParameter("ScriptBlock", System.Management.Automation.ScriptBlock.Create("Add-DistributionGroupMember -Identity " + DLGroupName + " -Member " + txtEmail.Text)); command.AddParameter("Session", result[0]); powershell.Commands = command; powershell.Runspace = runspace; result = powershell.Invoke(); if (powershell.Streams.Error.Count > 0 || result.Count != 1) { throw new Exception("Command failed"); } I am getting this error while running Add-DistributionGroupMember command {Couldn't find object "test11@gmail.com". Please make sure that it was spelled correctly or specify a different object.} UPDATE: I tried add email address to contacts then adding to distribution List still get an error. using (powershell = PowerShell.Create()) { command = new PSCommand(); command.AddCommand("Invoke-Command"); command.AddParameter("ScriptBlock", System.Management.Automation.ScriptBlock.Create( "New-MailContact -Name '" + txtEmail.Text + "' -ExternalEmailAddress '" + txtEmail.Text + "'")); command.AddParameter("Session", result[0]); powershell.Commands = command; powershell.Runspace = runspace; result = powershell.Invoke(); if (powershell.Streams.Error.Count > 0 || result.Count != 1) { throw new Exception("Fail to establish the connection"); } } using (powershell = PowerShell.Create()) { command = new PSCommand(); command.AddCommand("Invoke-Command"); string DLGroupName = "UnsubscribersList"; command.AddParameter("ScriptBlock", System.Management.Automation.ScriptBlock.Create( "Add-DistributionGroupMember -Identity '" + DLGroupName + "' -Member " + txtEmail.Text + "")); command.AddParameter("Session", result[0]); powershell.Commands = command; powershell.Runspace = runspace; result = powershell.Invoke(); if (powershell.Streams.Error.Count > 0 || result.Count != 1) { throw new Exception("Fail to establish the connection"); } } Error Cannot convert the "test11@gmail.com" value of type "Deserialized.Microsoft.Exchange.Data.Directory.Management.MailContact" to type "System.Management.Automation.Runspaces.PSSession".7KViews0likes1Comment
Groups
Recent Blog Articles
No content to show