Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 339117
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 12, 20262026-05-12T10:29:35+00:00 2026-05-12T10:29:35+00:00

i have an app that sends out email but i have to only send

  • 0

i have an app that sends out email but i have to only send out 50 recipients at a time (due to server limitations)

i got a great response on my original question (break up array into little arrays) on how to break up a large array into smaller arrays. split this up into arrays of 50 (and send out multiple mails)

but now there is one more level of complexity. People can enter names in the to, cc or bcc

so now the trick is, you start with 3 arrays (the to: array, the cc: array and the bcc: array)

and have to split up the mails so each mail doesn’t have more than 50 total recipients.

NOTE: that there is no ideal optimization that is necessary, as long as it functionally works.

EDIT: To clarify (as there were a few questions here below, there is 3 clear arrays upfront, the “to”, the “cc” and the “bcc”). if i merge them all together and then send out 50 at time, how do i know what to put in the to, cc, and bcc. i need to keep them seperate.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-12T10:29:35+00:00Added an answer on May 12, 2026 at 10:29 am

    Am I missing something? Can’t you just do it like this?

    foreach (var batchOf50 in SplitIntoBatches(toArray, 50))
    {
        SendEmail(batchOf50, null, null);    // first param is the to list
    }
    
    foreach (var batchOf50 in SplitIntoBatches(ccArray, 50))
    {
        SendEmail(null, batchOf50, null);    // second param is the cc list
    }
    
    foreach (var batchOf50 in SplitIntoBatches(bccArray, 50))
    {
        SendEmail(null, null, batchOf50);    // third param is the bcc list
    }
    

    (I’ll leave the implementation of SplitIntoBatches and SendEmail as an exercise for the reader!)

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Suppose I have a client side app that sends out requests to a rails
I have a rails app that sends out many notification e-mails. We have a
I have some automated functionality built into my web app that sends email daily
I have an app that sends multiple Ajax requests simultaneously. I was originally running
A theoretically question: I have a C# Windows Form app, that sends back some
I have one simple app that suppose to get information from user and send
I have a MT2070 scanner that needs to communicate to a PC app (send
have an app that finds your GPS location successfully, but I need to be
I've got a Rails 3.2 app that will need to send various transactional &
I am writing an app that ultimately wants to send some XML via email.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.