Ticket #350 (closed defect: fixed)
Expected MgIndexOutOfRangeException is not thrown by calling MgStringCollection:: SetItem() with an index out of range.
| Reported by: | jessicacao | Owned by: | trevorwekel |
|---|---|---|---|
| Priority: | medium | Milestone: | 2.0 |
| Component: | General | Version: | |
| Severity: | major | Keywords: | MgStringCollection::SetItem |
| Cc: | Trevor Wekel | External ID: | 985059 |
Description
Expected MgIndexOutOfRangeException? is not thrown but MgInvalidArgumentException? by calling MgStringCollection:: SetItem?() with an index out of range.
Step to recur:
1. Construct a MgStringCollection? and add a string object into it.
2. Call SetItem?() with an index out of range.
Sample code:
MgStringCollection? strColl = new MgStringCollection?();
string str1 = "string1";
strColl.Add(str1);
// MgIndexOutOfRangeException? expected
strColl.SetItem?(3, str1);
Expect result: MgIndexOutOfRangeException?
Actual result: MgInvalidArgumentException?
Change History
Note: See
TracTickets for help on using
tickets.
