473,778 Members | 1,910 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Access to a DataGrid in MultiPage from C#

Hello
I have a web form with MultiPage that contain DataGrid
My HTML code in the aspx page:
<iewc:multipa ge id="MP1" style="Z-INDEX: 101; LEFT: 225px;
POSITION: . . ."/>
iewc:PageVie w id="processData 1/"> asp:DataGrid id="DG2" style="Z-INDEX: 110; LEFT: 699px;

POSITION: absolute; TOP: 379px" unat="server">
</asp:DataGrid<
</iewc:PageView>
</iewc:multipage>
In the full HTML code I have more then one PageVive and
more then one DataGrid.
In my C# code I'm trying to fill the DataGrid in data from
the DB.

The C# code:
SqlConnection conn = new SqlConnection(. . .);
SqlCommand query = new SqlCommand("");
query = new SqlCommand("sel ect . . .",conn);
conn.Open();
SqlDataReader dr;
dr = query.ExecuteRe ader();
DG2.DataSource = dr; א Error DG2 not recognize
DG2.DataBind(); א Error DG2 not recognize
dr.Close();
conn.Close();

How can I have access to the DataGrid that is defined in
the HTML from the cs file?
Thank you very much!!!

Jul 21 '05 #1
0 1170

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

Similar topics

1
2423
by: news.microsoft.com | last post by:
Hello group, My goal is to attach an image over another image. Top image should be transparent so the back image is visible through the top one. Bellow is a test code in VB.NET. You need to create a form, a button (Button1) and an Picture Box (picBox). "watermark.jpg" is any jpg image, "beispiel.tif" is a multipage TIFF image with the white background, which will turn to transparent. The most important thing here is that the TIFF image...
2
1538
by: T.H.M | last post by:
Hello I have a web form with MultiPage that contain DataGrid My HTML code in the aspx page: <iewc:multipage id="MP1" style="Z-INDEX: 101; LEFT: 225px; POSITION: . . ."/> >iewc:PageView id="processData1/"> >asp:DataGrid id="DG2" style="Z-INDEX: 110; LEFT: 699px; POSITION: absolute; TOP: 379px" unat="server"> </asp:DataGrid<
1
1550
by: szabelin | last post by:
Is it possible to dynamically add a PageView to MultiPage? TabStrip has items property, so Tab and TabSeparator can be added... how about adding PageView to MultiPage? If not possible please recommend another client-side tab control. Thank you
0
317
by: Curtis Hatter | last post by:
I apologize if this has been answered, but on the .NET 247 site I saw a thread titled "Datagrid's ItemCommand Event", and had similar troubles with the Datagrid not properly firing the delete event if using a push button. I could not find the thread here, so I'm posting my finding's here in hopes that it will help others that are having the same problem. The problem: In a DataGrid the "Delete" command does not fire properly from a...
0
1858
by: mehul | last post by:
CheckBox template always evaluate to False even if checked in a DataGrid hosted inside a TabStrip in ASP.NET Hi, I am trying to develop an ASP.NET application. I am using TabStrip (which is part of IE WebControls). Inside a tab I have a datagrid defined as follows:
0
1355
by: RedEagle | last post by:
Hi, I don't know if you worked that out, but I have found a great workaround, inside EVERY PageView I put a Panel (just one or more panel for each PageView, it depends on how complicated is your front-end interface). Doing this way, the datagrid works just fine. Andy
0
1063
by: The Eeediot | last post by:
I've got a silly question for the group. I have an DataGrid that displays its information inside a panel... Well, actually it's a MultiPage object. I have a boader around the MultiPage object but when the DataGrid extends past the width of the web browser the top boarder ends at the edge of the browser window. How can I get to boarder to completely surround the DataGrid and make it look nicer? TIA...
0
824
by: T.H.M | last post by:
Hello I have a web form with MultiPage that contain DataGrid My HTML code in the aspx page: <iewc:multipage id="MP1" style="Z-INDEX: 101; LEFT: 225px; POSITION: . . ."/> >iewc:PageView id="processData1/"> >asp:DataGrid id="DG2" style="Z-INDEX: 110; LEFT: 699px; POSITION: absolute; TOP: 379px" unat="server"> </asp:DataGrid<
1
4893
by: Ira | last post by:
I was successful in creating the multipage Tif files in VB.net using the following the following code: Public Sub SaveSeveralOnePageFilesInADir(ByVal DrNm As String, ByVal resultFl As String) Dim pages As Bitmap = Nothing Dim PgCnt As Integer
0
9470
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,...
0
10298
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, 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...
0
10127
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 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...
0
9923
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 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...
0
5370
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...
0
5500
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4033
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
2
3627
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2865
bsmnconsultancy
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...

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.