|
hi,
1. add a check box as template field
Follow the reply of 1119
2. In the delete button handler you can use following code
<br />
Dim i As Integer<br />
For i = 0 To GridView1.Rows.Count - 1<br />
Dim chk As CheckBox = GridView1.Rows(i).Cells(0).Controls(1)<br />
MsgBox(chk.Checked.ToString())<br />
Next<br />
This will display the check box states in each row..
Just an example.You can follow this method..
Sherin Iranimose
|
|
|
|
|
If u r using .NET FW 2.0 i.e. Visual Studio 2005, when u place Grid on the Web form , a smart tag appears on the top-right corner of the grid, click it and edit the template, it has options for what u want to do
|
|
|
|
|
Hi,
My web application is developed using third party controls ..... some forms are developed using crystalrepots.......
I opened one setup project and added our third party dlls and crystareport dlls finally builded the application..
Setup was created, I installed it in my system everything is working fine...
when I installed it in client machine(having .Net Framework) it is raising configuration error saying that "could not load assembly(crystal assemblies)........"
How to solve it...
Thanks
Hari
|
|
|
|
|
while creating the deploymet package u have to add those dlls in applications bin directory not in the MSI. And All the dependent dlls has to be added in applications bin. Then the MSI or website will work fine.
|
|
|
|
|
First u add the DLLs in bin comiple the project then u create the deployment pakage either MSI or using MSBuild
|
|
|
|
|
hi,
how to do delete in grid view .i am not using sqldatasourse control.i am directly binding to a table present in database through dataset.
if i will use the sqldatasourse control for dataview,if any updatation will made latter in database will it bind automiticlly to the sqldatasourse?
p.sethi
|
|
|
|
|
Hi
First You should enable AutogenerateDelete button property of grid view.
Then You can write your delete code inside RowDeleting Function of grid view.
thats all for delete a row..
The second question, You can try it Yourself????
-- modified at 4:05 Friday 11th May, 2007
Sherin Iranimose
|
|
|
|
|
Hi.
I'm new in ASP .NET and I have a problem, I don't know why, but when I add ObjectDataSource to my page and go to Configure Data Source, there is, all the time, empty list, so I cannot choose any business object. I have connection to database and I have some DataSets, so where is the problem? Why I have empty list?
Thank you for help.
Greetings
David
|
|
|
|
|
It's a little more complicated than that chap!
Have you coded up a middle tier object to act AS your datasource? An object exposing select, update and delete methods that you can tie the ODS to?
Google is your friend
"Knock me down, I'll get straight back up again, I'll come back stronger than a powered up pacman"
(Lilly Allen / Kaiser Chiefs)
|
|
|
|
|
Hello,
I'm using ASP.NET 2.0. I have to make a Gridview containing a couple of buttons. I inserted the buttons using ItemTemplates. When the GridView is rendered to the client the ItemTemplates containing the buttons are allways placed to the left hand of the gridview and the data is placed right of the buttons. Is it possible to put the ItemTemplates/Buttons to the right hand side of the GridView and the data to the left hand side?
Thanks for any help on this.
Best tregards
Jens
|
|
|
|
|
hi,
Set AutoGenerateColumns = "False" for you gridview and create boundcolumns for all the data to display and at the last create your tempaltecolumns to display the buttons.
Thanks and Regards,
Chetan Ranpariya
|
|
|
|
|
Hi Chetan,
thanks for your answer. So when i get this right, you suggest to generate the template columns dynamically? When do i have to do this (After databinding for instance) and do i do it?
Best regards
Jens
|
|
|
|
|
Hi
U dont need to create template columns dynamically.
<asp:gridview runat="server" autogeneratecolumns="false" id="dg">
<columns>
<asp:BoundFiled datafield="field1"/>
<asp:boundfield datafield="field2"/>
<asp:templateField>
<ItemTemplate>
<asp:button id="bttn" runat="server" text="Click"/>
</ItemTemplate>
</asp:templatefield>
</columns>
I hope this will help u.
</asp:gridview>
Thanks and Regards,
Chetan Ranpariya
|
|
|
|
|
Dear Chetan,
thank you very much for your kind help. That was exactly what i needed. Man, you made my day
Thanks again
Jens
|
|
|
|
|
How to take backup of particular DB :
1} in vbscript
Develop2Program & Program2Develop
|
|
|
|
|
Navneet Hegde wrote: in vbscript
????????
|
|
|
|
|
need a component that will backup db in sql 2000 without any query back to sql2K
Develop2Program & Program2Develop
|
|
|
|
|
|
Hello everybody,
I've searched for this for a long time, but could not find an easy example or something that made sence (for me)
I've asked several collegue's of mine but they are not that good in communication, so i don't understand anything of what they are trying to explain me.
Do you have a clear example of passing variables from a page to a web control?
Thanks in adavce!
Stef
|
|
|
|
|
Add One property (setter, getter) for the control, Then use this as a varible to pass value.
Regards,
Sylvester G
sylvester_g_m@yahoo.com
|
|
|
|
|
Yea! i mean that!
Do you have an example for me?
Stef
|
|
|
|
|
[DefaultProperty("ImageUrl"),<br />
ToolboxData("<{0}:ImageButton runat=server></{0}:ImageButton>")]<br />
public class ImageButton : System.Web.UI.WebControls.LinkButton<br />
{<br />
[Bindable(true),<br />
Category("Appearance"),<br />
DefaultValue(""),<br />
Description("Specifies the image url for the button when in its normal state.")]<br />
public string ImageUrl<br />
{<br />
get<br />
{<br />
object o = ViewState["RollOverImageUrl"];<br />
if (o != null)<br />
return (string) o;<br />
else<br />
return String.Empty;<br />
}<br />
<br />
set<br />
{<br />
ViewState["RollOverImageUrl"] = value;<br />
}<br />
}<br />
<br />
[Bindable(true),<br />
Category("Appearance"),<br />
DefaultValue(""),<br />
Description("Specifies the image url for the button when the mouse is hovered above the button.")]<br />
public string DownImageUrl<br />
{<br />
get<br />
{<br />
object o = ViewState["RollOverRollOverImageUrl"];<br />
if (o != null)<br />
return (string) o;<br />
else<br />
return String.Empty;<br />
}<br />
<br />
set<br />
{<br />
ViewState["RollOverRollOverImageUrl"] = value;<br />
}<br />
}<br />
<br />
<br />
[Bindable(true),<br />
Category("Appearance"),<br />
DefaultValue(""),<br />
Description("Specifies the image url for the button when the mouse is Rollovered above the button.")]<br />
public string RollOverImageUrl<br />
{<br />
get<br />
{<br />
object o = ViewState["RollOverRollOverRollOverImageUrl"];<br />
if (o != null)<br />
return (string) o;<br />
else<br />
return String.Empty;<br />
}<br />
<br />
set<br />
{<br />
ViewState["RollOverRollOverRollOverImageUrl"] = value;<br />
}<br />
}<br />
This is my ImageButton derived from LinkButton And I have added some more properties for image urls
Regards,
Sylvester G
sylvester_g_m@yahoo.com
|
|
|
|
|
THANK YOU!! =D You make my day (acually week but who cares)
Stef
|
|
|
|
|
Can u a little bit clearer on ur Question ?
Wht do u mean by passing value from webpage ,because web page already contains web controls ? R u talking about user controls and passing value between them ?
Type : Clarification of Question
Deo
Bijay Bhaskar Deo
Thanks & Regard
|
|
|
|
|
Well...
Nevermind =D i get it know
thanks in advacne
-- modified at 3:55 Friday 11th May, 2007
Stef
|
|
|
|