|
Hi all
when i execute the following code it dosent display the single quotes(') with in the textbox.
how to solve this problem
any one pls suggest me.
Dim t As String
t = "'"
Dim str As String
str = ""
str = str & ""
Response.Write(str)
By Paul
PAul
|
|
|
|
|
Dim t As String
' t = "'"
Dim str As String
str = ""
str = str & ""
Response.Write(str)
|
|
|
|
|
hello i have got problem in fckEditor in Asp.net. i want to upload the image but i have got the Error "XML request Error :Internal server Error 500". i m not able to find the solution. Some body please help me to sort out the problem and tell me how can i upload the image successfully without any bug.
|
|
|
|
|
Hi,
I want to show an alert box from the code behind file.I donot want to write anycode in the aspx.cs file. All script i need in the code behind itself and want to show alert box not on any event but on some particuar conditions like
protected void dropDownListDistributionGroup_SelectedIndexChanged(object sender, EventArgs e)
{
int result;
if(Result==0)
{
// show alert box
}
}
Another Important thing , i want the alert box to be shown on the same open page . Not like this, it shows the message at blank page. ie (after postback)
ClientScript.RegisterClientScriptBlock(typeof(Page), "Script1", "' alert('Please Select Start Date earlier than End Date.');");
thanx
sandeep
|
|
|
|
|
You can't use server code to show an alert on the page that you send the postback from. When the request reaches the server, it's already decided in the browser that whatever the server returns will replace that page.
---
b { font-weight: normal; }
|
|
|
|
|
if(Request==0)
{
RegisterStartupScript("startupScript","alert('Your alert message goes here');");
}
This should work on ur open page only.
lehya
|
|
|
|
|
just add some code to the response to the client:
Response.Write("alert('Please Select Start Date earlier than End Date');");
|
|
|
|
|
Response.Write("javascript:alert('AlertBox');");
|
|
|
|
|
Hi there..
How can i change the DataGrid row color and style when i click this row?
VS.NET\VB.NET
|
|
|
|
|
To change datagrid row color, use this code
Protected Sub DataGrid_ItemCreated(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.DataGridItemEventArgs) Handles DataGrid.ItemCreated
e.Item.Attributes.Add("Onclick", "this.style.backgroundColor = 'lightblue';")
End Sub
|
|
|
|
|
Thanx
|
|
|
|
|
If you using visio studio to create it, you can simply change the style by
1. select the datagrid
2. open the properties windows
3.click the Auto Format
at there you can chose the predefined style of the datagrid.
hope you can find it.
|
|
|
|
|
Hi
am trying to bind the data to table control.
what i need is the table should have only two columns and it should have some 30 rows.
how to do this?
thanks in advance
|
|
|
|
|
Hi, try to use the DataGrid control from asp.net, there you can say
dgMyDatagrid.DataSource = dtMyDataTable;
dgMyDatagrid.DataBind();
and it's fixed
Greetings,
KrIstOfK
|
|
|
|
|
Hi,
Plase a Table control on the UI, SO it generates a code for CodeBehind as like
=======>Protected WithEvents Table1 As System.Web.UI.WebControls.Table
Then declare variables as followes
Private tableRow As New System.Web.UI.WebControls.TableRow
Private tableRowCells(1) As System.Web.UI.WebControls.TableCell
and Code as followes
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
tableRow = New System.Web.UI.WebControls.TableRow
tableRowCells(0) = New System.Web.UI.WebControls.TableCell
tableRowCells(1) = New System.Web.UI.WebControls.TableCell
tableRowCells(0).Text = "A"
tableRowCells(1).Text = "B"
tableRow.Cells.AddRange(tableRowCells)
Table1.Rows.Add(tableRow)
End Sub
Now suppose if you are displaying data from a dataset, you can have loop and can also ristrict to any number of recs to display using loop
hops this helps
Chinna Srihari
Tech Lead, Capgemini
|
|
|
|
|
I need to display my data in the dropdownlist in ascending order. i can't find the properties to allow me make it happen. How i do to sort the dropdownlist ? coding or just chosing the properties? Thanks...
|
|
|
|
|
When you bind an arraylist to your dropdownlist you can first sort the arraylist and then bind the data to the dropdown
myArrayList.Sort();
you can also make a comparer to sort it like you want or implement IComparer if the arraylist contains self-made class-objects.
Afterwards you can get your collection of items by myDropDownList.Items which will get you a list of listitems
|
|
|
|
|
I no use array to sort the items. My dropdownlist's items is load from the database, so how i code to sort the list before i bind the dropdownlist..thanks.
|
|
|
|
|
You can get the data in the sorted order from the database itself.
Best Regards,
Apurva Kaushal
|
|
|
|
|
There are two ways to achive this
1. When populating dropdownlist from database include the sorting there and there itself (by default ASC / DESC)
2. If you are populating from XML or code creats a dataset with specific column and set as following
.<tablename>.DefaultView.Sort = .<tablename>.<columnname>.ToString
is same at both the ends
Chinna Srihari
Tech Lead, Capgemini
|
|
|
|
|
There are two ways to achive this
1. When populating dropdownlist from database include the sorting there and there itself (by default ASC / DESC)
2. If you are populating from XML or code creats a dataset with specific column and set as following
<dataset>.<tablename>.DefaultView.Sort = <dataset>.<tablename>.<columnname>.ToString
<dataset> is same at both the ends
Chinna Srihari
Tech Lead, Capgemini
|
|
|
|
|
I sort the problem already by you all helping...Thank for you all !!
|
|
|
|
|
After opening word document in the browser, back button is getting disabled. How to enable the back button?
|
|
|
|
|
How to insert or add a table in powerpoint presentation from ASP.NET using C#?
|
|
|
|
|
First of all: I don't think this belongs to the asp.net section, but in the C# forum.
To answer your question: how do you generate your powerpoints. You use xml based generation or interops or something else?
|
|
|
|