473,394 Members | 1,718 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,394 software developers and data experts.

Problem creating "n" DataViews

Hi people,
Necesito crear n dataviews en tiempo de ejecucion.
I need to create "n" DataViews in runtime.

I tried creating an array this way:

Dim LDView As Array = Array.CreateInstance(GetType(DataView), 10)

DSCapit = New DataSet("DS")
LGCap = New DataTable("DT")

Dim cACCOUNT As DataColumn
cACCOUNT = New DataColumn("ACCOUNT")

LGCap.Columns.Add(cACCOUNT)
DSCapit.Tables.Add(LGCap)
but the asignation is not working:

lDView(0) = New DataView(LGCap) '(1)

neither this way :
lDView.SetValue(New DataView(LGCap), 0) '(2)

This two way compilate but then cancel in runtime
in the array asignacion line (1) y (2)
The problem came from my need to create a tabcontrol with
"n" (variable) tabs within it, according to a database table
contents. And within each tab one datagrid with its corresponding
DataView, all created in runtime.
Any ideas?

TIA
Pablo
Aug 19 '05 #1
2 1459
Pablo,

Is this what you want, otherwise describe what why you need those dataviews?

Dim LDView(myTabControl.tabcount) As DataView
Dim DSCapit As New DataSet("DS")
Dim LGCap As New DataTable("DT")
LDView(0) = New DataView(LGCap) '(1)

I hope this helps,

Cor
Aug 19 '05 #2
Pablo,

Forget this part in the sentence from me. When I was answering your question
I had seen you did that, therefore I could make this snippet. However
forget to delete this. Your problem was well described.
describe what why you need those dataviews?


Cor
Aug 19 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: MiW | last post by:
Hi I'm making a kind of JavaScript-based library for creating SVG objects/elements. And I hit the wall... Every element (rect, circle etc.) can be created using *.createElement, then...
10
by: Assimalyst | last post by:
Hi, I'm attempting to use a data reader to load data from a single table, tblCountry, with two columns, countryNo (the Key) and countryName, into a DropDownList box. Here's the code: ...
1
by: David A Barajas | last post by:
Is is possible to launch an Access Application within another app, creating a Parent/Child relationship between the App/Access? I'm trying to create a system where I can distribute the Access app...
1
by: Dominique Vandensteen | last post by:
I want to dynamicly load a type (typename is defined in the database). This type is located in the exe itself or one of the dll's in the directory with the exe file. When creating an instance...
2
by: Pablo | last post by:
Hi people, Necesito crear n dataviews en tiempo de ejecucion. I need to create "n" DataViews in runtime. I tried creating an array this way: Dim LDView As Array =...
0
by: Norman Yuan | last post by:
I posted this issue a while ago. After moveing the ASP.NET 1.1 app to a brand new server, the same problem still there. System: Winows2003 server std. .NET 1.1 App: Invoicing system Problem:...
9
by: Ecohouse | last post by:
I have a main form with two subforms. The first subform has the child link to the main form identity key. subform1 - Master Field: SK Child Field: TrainingMasterSK The second subform has a...
1
by: eggie5 | last post by:
I am sending and receiving data from my client/server using the JSON format. However, it turns out, a lot of the time, that data has ":" or " ' " characters in it, which causes the the javascript...
17
by: radio1 | last post by:
Configuration: Access 2002 and SQL Server 2000 using a .ADP Project. I would VERY MUCH appreciate anyone's input into this problem I'm having. I have a form in Access that does not permit...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
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,...
0
jinu1996
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...
0
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...
0
tracyyun
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...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.