|
Which version of Firefox ? any errors that you have received ?
|
|
|
|
|
Thanks For Your Reply..
I am using Mozilla Firefox2.0 in my local system.
I am not receiving any error.Calculations are not taking place
in gridview footer.While this script runs fine with other browsers.
Any Help can u provide.
Thank you.
|
|
|
|
|
Please Anybody Tel me the varous script injection
problems and it solutions
Shaikh Tauhid Hasan
|
|
|
|
|
|
Are you talking abt Java script injection ? However Google is there as he said.
|
|
|
|
|
Hi,
i am starter in aps.net , and i've created a webproject in asp.net2.0 and SqlServer2000 in Windows 2003 server.My doubt is ,
The images are in the folder named "img" and when i added the image to the Webpage
the is like this "../img/he.jpeg" .When i upload this site will the images with this path be displayed or not?
Plz help.
|
|
|
|
|
No the images will not displayed. If you have the same directory structure in the web server you can use Server.MapPath("/img") + "filename".
|
|
|
|
|
Try to use the full path of the image name like:
http://servername/vdname/images/imagename.jpg
Either you love IT or leave IT...
|
|
|
|
|
Good day
On RowDataBound event i have hidden the Field called ID that will appear after the Check Box like this
protected void GridView1_RowDataBound(object sender, GridViewRowEventArgs e)
{
e.Row.Cells[1].Visible = false;
}
Now its time to Delete the Selected Records from a Gridview and i have the Following code on the Delete Button
foreach (GridViewRow row in GridView1.Rows)
{
CheckBox chkbx = (CheckBox)row.FindControl("myCheckBox");
if (chkbx != null && chkbx.Checked)
{
List.Add(GridView1.Columns[1]);
Userarr.Add(GridView1.Columns[2]);
for(int i = 0 ; i < List.Count ; i++)
{
int Staff_ID = obj.Get_User_Id(Convert.ToString(Userarr[i]),Convert.ToString(Session["ActiveDatabase"]));
obj.Responsibility_Caretaker_Remove(Convert.ToInt32(List[i]), Staff_ID,Convert.ToString(Session["ActiveDatabase"]));
}
}
}
I know you will complain about Arraylist, lets look at the Solution, i will change later.
Now what am doing here is: I add the Value of the second Field and the third to Different Arraylist and using for loop and calling a method that will call a Sp that will Delete the record based on those two Fields. Now my Problem is that the Field
List.Add(GridView1.Columns[1]);
has been set to false in the Visible Property as you have seen above. And am getting index out of bounds errors. How can i get the value on that hidden Field.
Thanks
Vuyiswa Maseko,
Few companies that installed computers to reduce the employment of clerks have realized their expectations.... They now need more and more expensive clerks even though they call them "Developers" or "Programmers."
C#/VB.NET/ASP.NET/SQL7/2000/2005/2008
http://www.vuyiswamaseko.tiyaneProperties.co.za
vuyiswa@its.co.za
http://www.itsabacus.co.za/itsabacus/
|
|
|
|
|
You can access the text property for the cell even if it is invisible. I'm not sure why you are grabbing the column object from the grid and expecting to get a value from that. I'm also not sure why you are adding to the List in a foreach and then looping through the entire list every foreach iteration?
I think you might want to try something this instead:
foreach (GridViewRow row in GridView1.Rows)
{
CheckBox chkbx = (CheckBox)row.FindControl("myCheckBox");
if (chkbx != null && chkbx.Checked)
{
int Staff_ID = obj.Get_User_Id(Convert.ToString(row.Cells[2].Text),Convert.ToString(Session["ActiveDatabase"]));
obj.Responsibility_Caretaker_Remove(Convert.ToInt32(row.Cells[1].Text), Staff_ID,Convert.ToString(Session["ActiveDatabase"]));
}
}
Hope this helps.
|
|
|
|
|
Thank you very much it Helped.
Resolved
Thanks
Vuyiswa Maseko,
Few companies that installed computers to reduce the employment of clerks have realized their expectations.... They now need more and more expensive clerks even though they call them "Developers" or "Programmers."
C#/VB.NET/ASP.NET/SQL7/2000/2005/2008
http://www.vuyiswamaseko.tiyaneProperties.co.za
vuyiswa@its.co.za
http://www.itsabacus.co.za/itsabacus/
|
|
|
|
|
Oh can see you've already got the solution. Regards
|
|
|
|
|
Hi,
1. At what point are you getting the IndexOutOfRangeException? Have you stepped through your code?
2. Instead of hiding the ID column you can decide not to bind the ID column to the gridview in the first place, by not specifying it in the gridview boundfield collections.
You can set the ID column of the datasource as a Primary Key to the GridView Rows which you can use for your delete.
hope this helps,
Ibrahim
|
|
|
|
|
Hello,
I have placed a html table control on my web page. I wish to fill the rows and columns with dataset's rows and column. Please tell me the easy the faster way to fill the html table with dataset.
Dataset is carrying 20 rows and 8 columns.
Thanks & Regards
Girish Sharma
|
|
|
|
|
The easiest way is go for a GridView control in asp.net 2.0. You can display the dataset content in a tabular format by writing few lines of code.
It will also maintain the ViewState between postback.
You can also provide the sorting, paging and filter options.
|
|
|
|
|
So, finally, i am using GridView control, but one little question more:
How do i set column name as per query column; i.e. suppose select query is :
select Cname as "Candidate Name" from table1. So i wish to give the column name "Candidate Name" like wise.
Thanks & Regards
Girish Sharma
|
|
|
|
|
You can use RowDataBound event. Google it. you can do it like in that event,
"If e.Row.RowType = DataControlRowType.Header Then
do somthing
End If"
|
|
|
|
|
You can't use a HTML table in the code-behind to bind it to the dataset. You need to set runat="server" attribute to true. You can also use the HTMLTextWrite class to generate the table. Otherwise, you can always use the grid view control with out writing so many lines of code. But it totally depends on the requirement.
Either you love IT or leave IT...
|
|
|
|
|
Hi,
I have never used this control.Cay any one tell me:-
1) how to display image in detailsview control.I have store that image path in database.I want to display that image using the path store in that database.
2) and i want to hide columns of the detailsview control.Is it possible?.If yes how it is possible.
Can any one provide me the example..........if possible.
Thanks in advance.
Regards,
Pranav.
Pranav Dave
|
|
|
|
|
Put this code in .aspx page
<asp:DataList ID="dataListImages" runat="server" RepeatColumns="3" RepeatDirection="Horizontal"
Width="100%" CellPadding="2" CellSpacing="0">
<ItemTemplate>
<img alt="" src='<%#DataBinder.Eval(Container.DataItem, "Image_Path")%>' />
</ItemTemplate>
</asp:DataList>
In code behind .cs file
private void BindDataList()
{
using (SqlConnection connection = new SqlConnection("Database=DOTNET;Server=HELLO-COMP;Integrated Security=SSPI"))
{
string queryString = "SELECT Image_Path FROM Image_Table";
SqlCommand command = new SqlCommand(queryString, connection);
SqlDataAdapter da = new SqlDataAdapter(command);
DataTable dt = new DataTable();
da.Fill(dt);
dataListImages.DataSource = dt;
dataListImages.DataBind();
}
}
protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
BindDataList();
}
}
|
|
|
|
|
Tell me, please, how to delete individual pages from auntifikatsii file web.config
Thanks
|
|
|
|
|
What ...?
You question is not clear.
What is auntifikatsii file?
|
|
|
|
|
Sorry,
authentication...individual pages from authentication in the Web.Config file
|
|
|
|
|
Do you want to delete pages from web.config file ?
|
|
|
|
|
Xpycm wrote: how to delete individual pages from auntifikatsii file web.config
|
|
|
|