Hi all,
I have 2 asp .net 2.0 projects currently being developed. One is in
VB .Net and the other in C#. In the VB .Net project I can cross-reference
a datatable object using the datatable.rows. item(i).item(j) , but in the
C# project I can not do it. That is, I do get:
error 'System.Data.Da taRowCollection ' does not contain a definition for
'Item'
They are running under the same development evironment. (i.e. Asp .Net 2.0)
Does anyone know what can be happening?
Thanks,
Carlos. 3 7717
I think in C# you should be able to say:
datatable.rows[i][j]
and that should return the proper object
Carlos wrote:
Hi all,
I have 2 asp .net 2.0 projects currently being developed. One is in
VB .Net and the other in C#. In the VB .Net project I can cross-reference
a datatable object using the datatable.rows. item(i).item(j) , but in the
C# project I can not do it. That is, I do get:
error 'System.Data.Da taRowCollection ' does not contain a definition for
'Item'
They are running under the same development evironment. (i.e. Asp .Net 2.0)
Does anyone know what can be happening?
Thanks,
Carlos.
Hi Carol,
In C# you need say like this;
DataRowCollecti on oDataRow = new DataRowCollecti on();
oDataRow[i][j];
Thanks,
Thiagarajan Rajendran.
Carlos wrote:
Hi all,
I have 2 asp .net 2.0 projects currently being developed. One is in
VB .Net and the other in C#. In the VB .Net project I can cross-reference
a datatable object using the datatable.rows. item(i).item(j) , but in the
C# project I can not do it. That is, I do get:
error 'System.Data.Da taRowCollection ' does not contain a definition for
'Item'
They are running under the same development evironment. (i.e. Asp .Net 2.0)
Does anyone know what can be happening?
Thanks,
Carlos.
The "indexer" in VB.net is called by .Item(someInt)
ex:
myCollection.It em(someInt)
in C#, the indexer is called like this
myCollection[someInt]; // no use of the work "Item" here.
"Carlos" <ch******@yahoo .comwrote in message
news:eH******** ********@TK2MSF TNGP02.phx.gbl. ..
Hi all,
I have 2 asp .net 2.0 projects currently being developed. One is in
VB .Net and the other in C#. In the VB .Net project I can cross-reference
a datatable object using the datatable.rows. item(i).item(j) , but in the
C# project I can not do it. That is, I do get:
error 'System.Data.Da taRowCollection ' does not contain a definition for
'Item'
They are running under the same development evironment. (i.e. Asp .Net
2.0)
>
Does anyone know what can be happening?
Thanks,
Carlos.
This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Carlos Ribeiro |
last post by:
Hello all,
I'm posting this to the list with the intention to form a group of
people interested in this type of solution. I'm not going to spam the
list with it, unless for occasional and relevant announcements. If
you're interested, drop me a note. But if for some reason you think
that this discussion is fine here at the c.l.py, please let me know.
** LONG POST AHEAD **
|
by: Ian Payne |
last post by:
Documentation says it does:
Quickwatch lists it (but <cannot view indexed property> as
expected)
So how come the compiler throws an error?
I can of course work round it (in C#) with myMatches,
but tend to use the Item property by default.
Ian
|
by: Scott Adams |
last post by:
When calling the Find function of a DataRowCollection, one has two options:
Overloads Public Function Find(ByVal key As Object) As DataRow
or
Overloads Public Function Find(ByVal keys() As Object) As DataRow
This function is easy to use if the primary key of your DataTable consists
of only one field. How can you use the Find functions if the primary key
consists of two database fields (composite key)?
|
by: emma middlebrook |
last post by:
Hi
Straight to the point - I don't understand why System.Array derives
from IList (given the methods/properties actually on IList).
When designing an interface you specify a contract. Deriving from an
interface and only implementing some of it means something is wrong:
either the interface specification is wrong e.g. not minimal or the
derivation is wrong e.g. the type can't actually honour this contract.
|
by: Luis Esteban Valencia |
last post by:
Compilation Error
Description: An error occurred during the compilation of a resource required
to service this request. Please review the following specific error details
and modify your source code appropriately.
Compiler Error Message: CS0117: 'System.Data.DataTable' does not contain a
definition for 'WriteXml'
Source Error:
| |
by: mfunkmann |
last post by:
Hi,
I recently got an error and I don't know how to fix it:
Error 1 'System.Data.DataColumn' does not contain a definition for
'Windows' C:\c#\CsharpPRO\Form1.Designer.cs 304 77 CsharpPRO
I am note sure what to do because all propertiers work, except the
System.Data.DataColumn..
I didn't write any code by hand and used the visual studio to set the
properties..
|
by: mfunkmann |
last post by:
Hi there!
I have a problem here: I am using System.Data.Column and the Designer
wrote follwing Code for me:
this.System = new System.Data.DataColumn();
So far great, but furthermore I was setting properties with the Design
it generated follwing Code:
|
by: thisisuniqueuserid |
last post by:
throwing error " 'Outlook.Items' does not contain a definition for 'Item' " in asp.net while I added references for Interop.Outlook,Office still showing same error. If any body can help
Thanks in advance
Dhananjay
|
by: Nelluru |
last post by:
Hi,
I am using Office XP PIA's to read a word document. I am able to read the whole content. The problem is that i want to get a particular word in the document instead of the whole content.
Will the _Document.Words property is useful to retrieve word by word form the document??? If it is possible, How to use it???
thanks
Nelluru
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
| |
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |