## CookieCollection::Add(const System::SharedPtr\<Cookie\>\&) method


Adds a cookie to the collection.

```cpp
void System::Net::CookieCollection::Add(const System::SharedPtr<Cookie> &cookie) override
```


| Parameter | Type | Description |
| --- | --- | --- |
| cookie | const System::SharedPtr\<Cookie\>\& | The cookie to add. |

## See Also

* Typedef [SharedPtr](../../../system/sharedptr/)
* Class [Cookie](../../cookie/)
* Class [CookieCollection](../)
* Namespace [System::Net](../../)
* Library [Aspose.Page for C++](../../../)
## CookieCollection::Add(System::SharedPtr\<CookieCollection\>) method


Adds cookies from the specified collection to the current one.

```cpp
void System::Net::CookieCollection::Add(System::SharedPtr<CookieCollection> cookies)
```


| Parameter | Type | Description |
| --- | --- | --- |
| cookies | System::SharedPtr\<CookieCollection\> | The collection from which cookies will be copied to the current one. |

## See Also

* Typedef [SharedPtr](../../../system/sharedptr/)
* Class [CookieCollection](../)
* Class [CookieCollection](../)
* Namespace [System::Net](../../)
* Library [Aspose.Page for C++](../../../)
