|
Try opening the same page on the server with server name as localhost. It will show the error details on the screen. You should be able to digout using those details.
- ashish
|
|
|
|
|
Hi,
I am using inbuild datagrid paging.
I don't want to display pagenumber(i.e 1 2 3.....) if there is only single page in datagrid.
Anybody knows how to do this.
thanks.
Nagraj
|
|
|
|
|
if datagrid1.pageSize<10 then '10 is your pagesize
datagrid1.allowPaging=false
else
datagrid1.allowPaging=true
end if
With regards,
Suresh Dayma
-- modified at 6:40 Friday 25th August, 2006
|
|
|
|
|
Yes,I want to display pagenumbers.But i don't want pagenumber when there is single page in grid.
I mean if pagesize =5 and only 4 records are there in grid,then pagenumber shows 1.This 1 I don't want on single page
I hope now i am clear.
|
|
|
|
|
Hey,
To give you my back ground, I come from a strong C++ background and have been using asp.net (c#) for a couple of months now and am not bad. I can create registration sites, secure logins, connecting to databases etc..
Now I just had a friend who needs someone to code the backend for a e-commerce site, the interface will be built by the other person but they need me to handle the backend coding, so basically what i would like advice on, is should I take the job?
I am not actually sure how big of a job this is. I know that the customer needs to be able to pay for the items by credit card. I am pretty sure I will need a secure site, and use of a ssl certificate, and the use of a merchant account from a bank? but again I dont (at the moment) have much experience.
If anyone could give me advice on whether A. I would be able to complete the job, B. How long should it should take, anc C. any good articles that could get me on my way I would be much appreciative.
Thanks for your time.
|
|
|
|
|
|
Hey,
To give you my back ground, I come from a strong C++ background and have been using asp.net (c#) for a couple of months now and am not bad. I can create registration sites, secure logins, connecting to databases etc..
Now I just had a friend who needs someone to code the backend for a e-commerce site, the interface will be built by the other person but they need me to handle the backend coding, so basically what i would like advice on, is should I take the job?
I am not actually sure how big of a job this is. I know that the customer needs to be able to pay for the items by credit card. I am pretty sure I will need a secure site, and use of a ssl certificate, and the use of a merchant account from a bank? but again I dont (at the moment) have much experience.
If anyone could give me advice on whether A. I would be able to complete the job, B. How long should it should take, anc C. any good articles that could get me on my way I would be much appreciative.
Thanks for your time.
|
|
|
|
|
Hi,
I am trying to create a TreeView programmatically, but cannot get my EventHandler to work - unless I do like below - is that really the way to do it?
I want to add a TreeView and when the user posts back some data, I want that data in the TreeView. My first thought was to put in if (!IsPostBack) before the CreateTreeView() call and then add the data in the EventHandler and then calling the CreateTreeView() at the very end. This, however, does not add the EventHandler
Do you really have to create the control twice? Once with the pre postback data and then one after adding the postback data to the control. The example below is very simple, but in my real app it will cause a lot of trouble as there are many controls with EventHandlers being added.
Can you execute any code after the events have fired?
I have been looking high and low for an answer, but have found none, so I hope some one can help
If you need more info, please let me know.
Kind regards,
Lars
public partial class _Default : System.Web.UI.Page
{
StringCollection nodes = new StringCollection();
TreeView TreeView1 = new TreeView();
protected void Page_Load(object sender, EventArgs e)
{
TreeView1.SelectedNodeChanged += new EventHandler(NodeChanged);
nodes.Add("Node1");
//if (!IsPostBack)
CreateTreeView();
}
protected void NodeChanged(object sender, EventArgs e)
{
// This could be data added by the user
nodes.Add("Node2");
CreateTreeView();
}
void CreateTreeView()
{
TreeView1.Nodes.Clear();
foreach (string s in nodes)
{
TreeNode node = new TreeNode(s);
TreeView1.Nodes.Add(node);
}
this.form1.Controls.Add(TreeView1);
}
}
|
|
|
|
|
The thing is that the postback resets the page to it's original state, so any information regarding the dynamically created controls is lost. Why is that? Because the Page class is stateless. The Page recreates child controls based on the tags in the aspx files, so your controls not being present there are not shown. That's why you need to recreate them. Their values are persisted in ViewSate however, so you only need to create the tags again (with the same ID of course) and you do not have to assign values again (that is if you want the values of the controls as they were on postback.
There is no other way around it. It's how ASP.NET works.
regards,
Mircea
Many people spend their life going to sleep when they’re not sleepy and waking up while they still are.
|
|
|
|
|
Thank you for the answer
|
|
|
|
|
Can we make two function in a class that have same name and same number of parameters but function return types are different.
Can anybody help me.
Thanks in advance.
kartik rathi
|
|
|
|
|
|
Ya I too think so you need to have some difference in the parameters.
Best Regards,
Apurva Kaushal
|
|
|
|
|
Creating a function with the same name is called overloading. You can create as many functions as you want with the same name, as long as the parameters are not the same number.
Why do I mean by the same?
You can have two functions with the same number of parameters as long as at least one of them is of a different type than the other definion.
But this will not compile:
public void abc(int m)<br />
{<br />
}<br />
<br />
public int abc(int m)<br />
{<br />
}
because the return type is not part of the function signature. Only the name and the parameters are.
regards,
Mircea
Many people spend their life going to sleep when they’re not sleepy and waking up while they still are.
|
|
|
|
|
Nice expalnation.
Best Regards,
Apurva Kaushal
|
|
|
|
|
Hi Friends,
Why the asp.net controls having two different width and height in IE and mozilla firefox?
Regards,
Thomas
|
|
|
|
|
Well they don't but if they display differently in IE than Mozilla, it's because of the incompatibilities probably caused by the elements they reside into (tables, divs, etc). These are usually the ones that cause problems with height/width display.
regards,
Mircea
Many people spend their life going to sleep when they’re not sleepy and waking up while they still are.
|
|
|
|
|
|
Quite informative.
Best Regards,
Apurva Kaushal
|
|
|
|
|
Hello,
How can I provide different data formats in my web application.
Some user wants PST (mm/dd/yyyy), some wants IST(dd/mm/yyyy).
My database date setting is PST.
If any one have idea, please advice.
Best Regards,
S Kumar
|
|
|
|
|
If you want to display the dateformat according to the user then you can store the dateformats for each of the user in the database and then you can display the date in user format.
Best Regards,
Apurva Kaushal
|
|
|
|
|
Hi Apurva Kaushal,
Formatting is not a issue while dispalying to user.
My Problem is USER INTERFACE, while entering data some user wants to enter data in mm/dd/yyyy format and some user wants to enter data in dd/mm/yyyy.
But database setting is mm/dd/yyyy only.
Best Regards,
S Kumar
|
|
|
|
|
Here two(there may be some more also) ways are there which you can opt for:
1. either you use a javascript calender(for the user to enter the date) or you can even use dropdownlist control for the user to select the date.
2. If user has to enter the specifically in a textbox then enforce to enter in a particular format.
Best Regards,
Apurva Kaushal
|
|
|
|
|
Hi Apurva,
Thanks for your reply.
Presently we have have text box for date fields and users are habitual for this, I think we can't change to drop down box.
Best Regards,
S Kumar
|
|
|
|
|
In that case I feared you have to go for the enforcement for the format of the date i.e ask the user to enter the date in a particular format.
Best Regards,
Apurva Kaushal
|
|
|
|