|
Hi all
I have asp.net project. In this project if user is login and leaves any page then after 5 minutes it automatically goes to login page and after again login it comes to home page.
problem is i want to return user on the same page where he left it.
can any body help me?
Raghvendra Kumar Roy
|
|
|
|
|
You need to pass a return URL on the query string when you go to the login page, then use that to redirect back
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
How? Will i have to mention it in web.config?
can you explain me please
Raghvendra Kumar Roy
|
|
|
|
|
Hi
I have a normal string-variable in asp.net/c#, that contains cr/nl characters that I want to replace with <br> tags. When viewing the string in debugmode in VS2005, I can see them in there as "\r\n".
I have tried replacing with:
str.Replace("\r\n","<br>");
str.Replace(Environment.Newline,"<br>");
but it does not work. How can I do that?
Wonder if its something about UniCode-characters.
Thanks.
|
|
|
|
|
This should work fine. You should put a closing tag in your breaks, so they are XHTML.
What happens when you try this ?
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
yes, but it does not, wonder if its something about UniCode-characters
|
|
|
|
|
Are you just calling them like this?
str.Replace("\r\n","<br>");
str.Replace(Environment.Newline,"<br>");
Or are you actually assigning the value back to str?
str = str.Replace("\r\n","<br>");
str = str.Replace(Environment.Newline,"<br>");
|
|
|
|
|
i have two dates in mm/dd/yyyy format example
1/1/2000 - 1/31/2000
can i loop though these dates in vb.net
or
can i use the for each statement here i this case ?
Sonia Gupta
Soniagupta1@yahoo.co.in
Yahoo messengerId-soniagupta1
Love is Friendship and Friendship is Love....
|
|
|
|
|
use while loop in vb.net this will help u.
just check the last date and do it.
Piyush Vardhan Singh
Programmer
TAS NewDelhi
India
|
|
|
|
|
sir if u please provide an example
Thank You.
Sonia Gupta
Soniagupta1@yahoo.co.in
Yahoo messengerId-soniagupta1
Love is Friendship and Friendship is Love....
|
|
|
|
|
Use the AddDays function on the datetime to get the next day, and a while loop to loop until the value is a particular date.
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
thanks
Sonia Gupta
Soniagupta1@yahoo.co.in
Yahoo messengerId-soniagupta1
Love is Friendship and Friendship is Love....
|
|
|
|
|
Hi All,
i am having some problems with reading data from an excel file (.xls) using my web application built using ASP .Net 1.0 (C#) . it works fine in windows XP (IIS 5.1). but when hosted in windows 2003 server (IIS 6.0) i am getting errors like "Could not find installable ISAM" , "Unspecified Error" etc. i am using C# OLEDB connection to establish a link with the excel file. i have tried almost all formats of connection strings. but the error occurs when Open() method of oledb connection is called.
some of the connection strings i used are :
"Provider=Microsoft.Jet.OLEDB.4.0;" +
@"Data Source=" + excelFileName +"; Jet OLEDB:Engine Type=5;"+
"Extended Properties=\"Excel 5.0;HDR=Yes;ReadOnly=true \"";
-------------------------------------------------------------------------------------
"Provider=Microsoft.Jet.OLEDB.4.0;" +
@"Data Source=" + excelFileName +";"+
"Extended Properties=" + (char)34 + "Excel 1.0;HDR=Yes;ReadOnly=true " + (char)34;
--------------------------------------------------------------------------------------
"Provider=Microsoft.Jet.OLEDB.4.0;" + @"Data Source=" + excelFileName + ";" + " Extended Properties=Excel 12.0;HDR=Yes; ReadOnly=true ";
------------------------------------------------------------------------------------------
"Provider=Microsoft.Jet.OLEDB.4.0;data source=" + excelFileName + ";" + " Extended Properties=\"Excel 2.0;HDR=Yes;ReadOnly=true \"";
----------------------------------------------------------------------------------------------
"Provider=Microsoft.Jet.OLEDB.4.0;" +
@"Data Source=" + excelFileName +"; Jet OLEDB:Engine Type=5;"+
"Extended Properties=\"Excel 10.0;HDR=Yes;IMEX=1;ReadOnly= true \"";
----------------------------------------------------------------------------------------------
please help me to identify the cause of this error and a solution..
Thanks in advance
Sajitha Jose
|
|
|
|
|
Hi,
I have a date and time column in my datagrid and the time in this column is displayed with AM/PM format (ex:"10/11/2006 1:17:25 PM"). But when i export to excel, this time is turned into 24-hour format (ex:"10/11/2006 13:17"). How can i maintain the same format in excel sheet also.
Thanks in Advance
Phanindra...
|
|
|
|
|
Hi
I am using vs.net 2005 and asp.net 2.0 .
In aspx design code i wrote the code as
<% dim i as integer
i="images/ga.jpg"
%>
now i dont want to provide src prpperty value directly.
i have to give variable value how to give this
plz help me ......
Thanks in advance
Haritha
|
|
|
|
|
Why did you create a new account and ask this twice ?
Your code doesn't work. You create an integer and assign a string to it. VB.NET, being crap, will probably turn your int into a string, but you'd do well not to rely on your language of choice being rubbish.
Your code doesn't do anything sensible, but you can assign a variable value to the src property in your code behind, I don't see the issue. Of course, it needs to be a server control.
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
harithadotnet wrote: dim i as integer
i="images/ga.jpg"
Passing string value to integer value ? How this is possible ?
I am not sure that I understood your problem, are you trying to assign variable value to src of image tag ? That could be something like
<image src=<%=i%>
|
|
|
|
|
:-DUse string type variable and assign it to image control property (it means take i as a string type varible)
Nand Kumar Das
|
|
|
|
|
Hi
I am using vs.net 2005 and asp.net 2.0 .
In aspx design code i wrote the code as
<% dim i as integer
i="images/ga.jpg"
%>
<asp:image id="img1" src="" runat="server">
now i dont want to provide src prpperty value directly.
i have to give variable value how to give this
plz help me ......
Thanks in advance
Haritha
|
|
|
|
|
I've run into a bug that I thought I bring it up here.
I created a simple website and I tried to build it and got the following error:
"Unrecognized attribute 'xmlns'. Note that attribute names are case-sensitive. C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Config\web.config 68"
I looked at the web.config file in the project and such line didn't exist.
Next I went to VS2005 and build a simple website, tried to build got the same error.
Then I realize, they are both looking at the same web.config, which is located in
C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\CONFIG
Even though in VS2008 I had selected .Net 3.5, it went and changed the web.config in the 2.0 section.
Any ideas?
Thanks!
|
|
|
|
|
Your website is configured to use the v2 framework. Go into IIS, right click on your virtual directory and select Properties, then on the ASP.NET tab select the propper version for the ASP.NET runtime.
Cheers,
Mircea
"Pay people peanuts and you get monkeys" - David Ogilvy
|
|
|
|
|
i didnt have any option
in iis like that
thanks
|
|
|
|
|
In IIS, expand "Web Sites" and look for your virtual directory. Right click on the virtual directory.
Cheers,
Mircea
"Pay people peanuts and you get monkeys" - David Ogilvy
|
|
|
|
|
Hi friends,
I am a beginner in asp.net c# ,now i am in a difficult situation like in my project i want to implement certificate authentication..i really need your help and suggestions...please anybody help me out like how can i implement that give some code samples for that...i am waiting for your reply....
Regards
Alex
|
|
|
|
|
Hai .,
Cud any1 plz help on how to autoscroll to down in multiline textbox ... plz help me out
|
|
|
|