title: Angular 7 multiple query string, how to
body: <p>I have an asp.net method that accepts a list of items as a parameter. The function works and has been tested. Now this method is being consumed by Angular. My question is, how can I successfully pass multiple parameters from within Angular? </p>
  
  <p>Essentially, I'm trying to achieve this: </p>
  
  <pre><code>localhost:4200/download?item=fname&amp;item=lname&amp;item=cc
  </code></pre>
  
  <p>The values are being passed from Angular material design check boxes.</p>
  
  <blockquote>
    <p>Asp.Net Core </p>
  </blockquote>
  
  <pre><code>[HttpGet("downloadbooks")]
  public IActionResult Download(IList&lt;string&gt; item)
  {
    //omitted for simplicity
  }
  </code></pre>
  
  <blockquote>
    <p>Angular Service</p>
  </blockquote>
  
  <pre><code>downloadfunction(item: any = []){
    return this.http.get(url + `books/downloadbooks?item=${item}`,  { headers: new HttpHeaders({'Content-Type': 'application/json',
        }), responseType: 'blob'}
      );
  }
  </code></pre>
  
  <blockquote>
    <p>Angular TS</p>
  </blockquote>
  
  <pre><code>fname;
  fnameChecked = false;
  
  lname;
  lnameChecked = false;
  
  cc;
  ccChecked = false;
  
  
    onfnameChecked() {
      this.fname= ""
      if (this.fnameChecked) {
        this.fname = "fName"
      }
    }
  
    onlnameChecked() {
      this.lname= ""
      if (this.lnameChecked) {
        this.lname = "lName"
      }
    }
  
   onccChecked() {
      this.cc= ""
      if (this.ccChecked) {
        this.cc= "cc"
      }
    }
  
  downloadBooks(){
  
  //I want to pass multiple parameters within the dowloadfunction()
  //only one parameter is passed at the moment.
  
   this.downloadService.downloadfunction(this.fname).subscribe(blob =&gt; {
   link.href= window.URL.createObjectURL(blob);
  })
  }
  </code></pre>
  
  <blockquote>
    <p>Angular html</p>
  </blockquote>
  
  <pre><code>
      &lt;mat-checkbox class="example-margin" name="fnameChecked" [(ngModel)]="fnameChecked" [checked]="fnameChecked" (change)="onfnameChecked()"&gt;First name&lt;/mat-checkbox&gt;
  
      &lt;br /&gt;
      &lt;mat-checkbox class="example-margin" name="lnameChecked" [(ngModel)]=" lnameChecked " [checked]=" lnameChecked " (change)="onlnameChecked()"&gt;Last Name &lt;/mat-checkbox&gt;
      &lt;br /&gt;
  &lt;mat-checkbox class="example-margin" name="ccChecked" [(ngModel)]="ccChecked " [checked]=" ccChecked " (change)="onccChecked()"&gt;Credit card&lt;/mat-checkbox&gt;
  
    &lt;button mat-raised-button [mat-dialog-close]="" color="primary" (click)="downloadBooks()"&gt;&lt;a [target]="'_blank'"&gt;Submit&lt;/a&gt;&lt;/button&gt;
  
  </code></pre>