|
Hi all,
How long we can store the value in session object may we increase the time duration of storage ?
Is there any way to increase the time of storage of value in session object ?
Rameez
|
|
|
|
|
Session.TimeOut will say the duration session data will be kept. You can set it to a custom value if required. But before you set it to a big value, make sure you know what you are doing.
|
|
|
|
|
Thanks for reply ,
bt how long we can store the value inside session object i mean time duration ?
OR
After what time Period session object lost their values automatically ?
Best Regards
|
|
|
|
|
Rameez Raja wrote: After what time Period session object lost their values automatically
That is what TimeOut property says. In default settings, session will timeout after 20 minutes.
|
|
|
|
|
By default in IIS, session is set to 20 minutes. But this can be changed in IIS.
Alternatively you can change setting timeout at runtime using Session.Timeout. But you need to me mindful if you have to change your session timeout.
Yusuf
Oh didn't you notice, analogous to square roots, they recently introduced rectangular, circular, and diamond roots to determine the size of the corresponding shapes when given the area. Luc Pattyn[^]
|
|
|
|
|
Refer these links
1. http://www.velocityreviews.com/forums/t300273-session-timeout-setting-in-iis.html
2. http://forums.devshed.com/asp-programming-51/session-and-connection-timeout-72998.html
|
|
|
|
|
Hi All,
I am trying to send a mail using C# code. i can infact send the mail with my code but the body of the mail is not being delivered. I can even send attachments. Any one please tell me where I am going wrong. I have downloaded a Rich text Editor(textbox) for the body of the mail.
Thanks in Advance.
archie
|
|
|
|
|
archie@hyd wrote: Any one please tell me where I am going wrong.
Without seeing your code how can we realistically help other than by suggesting random things that may or may not be relevant.
|
|
|
|
|
Did you debug your code? what did you see in the body of your message?
Yusuf
Oh didn't you notice, analogous to square roots, they recently introduced rectangular, circular, and diamond roots to determine the size of the corresponding shapes when given the area. Luc Pattyn[^]
|
|
|
|
|
Yusuf.A wrote: Did you debug your code?
Debugging? What a novel concept.
|
|
|
|
|
the OP googles 'what is debugging'.
my bad,
the OP posts question on CP, hlp need codz for debugging.
Yusuf
Oh didn't you notice, analogous to square roots, they recently introduced rectangular, circular, and diamond roots to determine the size of the corresponding shapes when given the area. Luc Pattyn[^]
|
|
|
|
|
Hi There,
I had Created A Message box using div tag to show error messages.It display erro messages properly.But when I try to show any error in update panel then it didn't show this error message box.Can anybody tell me what is the problem.
Thanks.
|
|
|
|
|
Are you trying to show an alert box from codebehind?
|
|
|
|
|
|
It is not possible to show an alert box from code behind on using the update panel. Update Panel just blocks these alerts.
Can you provide me with the code snippet so that i shall try to help you.
|
|
|
|
|
Thanks For Reply,
Which code you want see message creation code or what?
Thanks
|
|
|
|
|
The code you write in codebehind to display the alert
|
|
|
|
|
-----------------This the code which I had written in CommonClass where all my commonly used method stored.-------------------------------------------------
public static void ShowMessageBox(string Message, System.Web.UI.Page p)
{
System.Web.UI.WebControls.Label lblMessageBox = new System.Web.UI.WebControls.Label();
lblMessageBox.Text = "" + Environment.NewLine + " void(showBox('" + Message + "'))";
p.Controls.Add(lblMessageBox);
}
---------------------This is my Code Behind Code--------------------------------
CommonClass.ShowMessageBox(ex.Message.ToString(), this.Page);
By using this code I am calling method present in Common Class.
--------------------------And This Is My Message Box Code Which I had written On Master Page---------------------------------------
function showBox(str)
{
var width = document.documentElement.clientWidth + document.documentElement.scrollLeft;
var layer = document.createElement('div');
layer.style.zIndex = 2;
layer.id = 'layer';
layer.style.position = 'absolute';
layer.style.top = '0px';
layer.style.left = '0px';
layer.style.height = document.documentElement.scrollHeight + 'px';
layer.style.width = width + 'px';
layer.style.backgroundColor = 'LightGray';
layer.style.opacity = '.7';
layer.style.filter += ("progid:DXImageTransform.Microsoft.Alpha(opacity=80)");
document.body.appendChild(layer);
var div = document.createElement('div');
div.style.zIndex = 3;
div.id = 'box';
div.style.position = (navigator.userAgent.indexOf('MSIE 6') > -1) ? 'absolute' : 'fixed';
div.style.top = '200px';
div.style.left = (width / 2) - (400 / 2) + 'px';
div.style.height = '100px';
div.style.width = '400px';
div.style.backgroundColor = 'White';
div.style.border = '4px solid silver';
div.style.padding = '20px';
document.body.appendChild(div);
var myimg = document.createElement('IMG');
myimg.src= "../images3.jpg";
myimg.width= '50';
myimg.height = '50';
myimg.visible="true";
div.appendChild(myimg);
var p = document.createElement('p');
p.innerHTML = str;
p.style.position = "absolute";
p.style.top = '20px';
p.style.fontSize=14+'px';
p.style.fontWeight = "bold";
p.style.left = (width / 2) - (800 / 2) + 'px';
div.appendChild(p);
var btn=document.createElement('Button');
btn.innerHTML='Ok';
btn.style.border='2px solid silver';
btn.style.opacity = '.6';
btn.style.fontSize=16+'px';
btn.style.fontWeight = "bold";
btn.style.border='solid';
btn.style.position = "absolute";
btn.style.top = '100px';
btn.style.left = (width / 2) - (620 / 2) + 'px';
btn.onclick = function()
{
document.body.removeChild(document.getElementById('layer'));
document.body.removeChild(document.getElementById('box'));
};
div.appendChild(btn);
}
|
|
|
|
|
It's a simple update profile page containing a form with loaded value.
Whenever the page is opened those msg are coming.
SecurityException: Request for the permission of type 'System.Security.Permissions.FileIOPermission, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed.
What should I do to fix this?
|
|
|
|
|
Subarna4D wrote: What should I do to fix this?
May be by explaining more clearly.
Information provided by you is not sufficient for answering. Please provide more information like when this error message is coming. From where you are loading data. Also show us the relevant code where error is coming.
|
|
|
|
|
It's a member profile update page having his details in text boxes.Data are loaded from data base.WHenever the page is loaded a load_data function is called.This page has no complecated codes.But during loading the page it's showing the message security exception.....
If required field validators are removed then the problem is solved.
|
|
|
|
|
Do you have any trust levels set? Read about it here[^] and try to set the trust level.
|
|
|
|
|
NO i haven't.Actually this problem is happening in godaddy server only.Locally it's working fine.
|
|
|
|
|
Locally your application will be running on full trust level and everything will work fine. But on servers, there will be usually medium trust level and you will run into problems. Read this[^] MSDN article.
|
|
|
|
|
Dear,I actually want to get all email address from user's email contact list who get registered in my site. Truly speaking, it's just a way to friend request by sending email to those emails. I want to do it in c#.
modified on Monday, March 30, 2009 7:44 AM
|
|
|
|