|
web
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
No accessible overloaded 'DataRowCollection.Add' can be called without a narrowing conversion."mnarrowing conversion" ewrror mesage. Thanks Bill ----------------- Dim rValue(0) As Object rValue(0) = CInt("1001") dS.Tables(0).Rows.Add(rValue(0)) Error: Additional information: No accessible overloaded 'DataRowCollection.Add' can be called without a narrowing conversion. The Add method is expecting an Array of type Object, not one element of an
Array of type Object. ds.Tables(0).Rows.Add(rValue) should work. Tony Show quoteHide quote "Bill Nguyen" wrote: > What do I need to do to add a row to a table with single column? I got the > "mnarrowing conversion" ewrror mesage. > > Thanks > > > > Bill > > ----------------- > > > > Dim rValue(0) As Object > > rValue(0) = CInt("1001") > > dS.Tables(0).Rows.Add(rValue(0)) > > Error: > Additional information: No accessible overloaded 'DataRowCollection.Add' can > be called without a narrowing conversion. > > > Thanks Tony;
This works well. one more thing, can I sort the DS.Tables(0) after adding this new row? Bill Show quoteHide quote "tlkerns" <tlke***@discussions.microsoft.com> wrote in message news:3B91DB33-14DF-4E54-BB82-9280263E29C5@microsoft.com... > The Add method is expecting an Array of type Object, not one element of an > Array of type Object. > > ds.Tables(0).Rows.Add(rValue) > > should work. > > Tony > > "Bill Nguyen" wrote: > >> What do I need to do to add a row to a table with single column? I got >> the >> "mnarrowing conversion" ewrror mesage. >> >> Thanks >> >> >> >> Bill >> >> ----------------- >> >> >> >> Dim rValue(0) As Object >> >> rValue(0) = CInt("1001") >> >> dS.Tables(0).Rows.Add(rValue(0)) >> >> Error: >> Additional information: No accessible overloaded 'DataRowCollection.Add' >> can >> be called without a narrowing conversion. >> >> >>
Center in Child
Disable objectdatasource-control Class Instantiation Inability to trap form.show event Data Access Application Block Creating Multiple Listviews in Code scope - integer file upload download on aspx problem Add new items to combobox after the datasource is set DrawString with Hotkey Character Underlined |
|||||||||||||||||||||||