|
Prasanna Kumar Pete wrote: Try using
Server.UrlEncode()
OR
HttpUtility.UrlEncode()
thanks but please give a proper syntax how to use Server.UrlEncode() or HttpUtility.UrlEncode()
|
|
|
|
|
string strEncoded = HttpUtility.UrlEncode("CCP – 2415 (ESC)");
Thanks & Regards
Pete
|
|
|
|
|
but how can i use that(
Prasanna Kumar Pete wrote: string strEncoded = HttpUtility.UrlEncode("CCP – 2415 (ESC)");
) in html pages.... please tell me
modified on Wednesday, November 26, 2008 4:34 AM
|
|
|
|
|
for html pages you might need to use
encodeURIComponent() available in javascript
Thanks & Regards
Pete
|
|
|
|
|
I am new to NUnitASP. I learend NUnitASP from the website.
When i used NUnitASP in my sample application, when i run the nunit am getting the message Reason- Has no Testfixtures ,
when i am creating the class,which is inherited from the NunitAdapter.cs its not getting inheritedin my sample application class.
I went through some website, and knew that, i have to copy the
NunitAdapter.cs file into my sample application.
So, i copied that file, again i am getting the same error.
Anybody, could you give me the solution for this.
Any links for using NUNitASP with Vb.net, becuase lot of examples
available in C# only.
Thanks in advance.
Regards,
sowmya
|
|
|
|
|
sowmya k wrote: I am new to NUnitASP
Don't use that one. Split the logic that has to be tested to separate assemblies and use NUnit or any other testing framework to do the test. AFAIK, NUnitASP is not worth for using.
|
|
|
|
|
Hi friends.
I have a bit problem here.
below code generate image from jpg to png but not working with eps.
protected void Page_Load(object sender, EventArgs e)
{
string path = Server.MapPath(Request.QueryString["Path"]);
byte[] by = FileToArray(path);
MemoryStream ms = new MemoryStream(by, 0, by.Length);
ms.Write(by, 0, by.Length);
System.Drawing.Image img = Bitmap.FromStream(ms);
ms.WriteTo(Response.OutputStream);
}
public byte[] FileToArray(string sFilePath)
{
System.IO.FileStream fs = new System.IO.FileStream(sFilePath,
System.IO.FileMode.Open, System.IO.FileAccess.Read);
System.IO.BinaryReader br = new System.IO.BinaryReader(fs);
Byte[] bytes = br.ReadBytes((Int32)fs.Length);
br.Close();
fs.Close();
return bytes;
}
Thanks
Regards
kHan
please don't forget to vote on the post that helped you.
|
|
|
|
|
Try ImageGlue from Websupergoo.
|
|
|
|
|
Hi All
How can i optimize the HTML through Code.I want to reduce the page size and unnecessary tags.
Does any know the way or have suggestion?
|
|
|
|
|
It really depends on the type of data you are displaying and the controls you are using but it may be possible to use a Repeater control instead of a GridView control for instance.
Also, instead of setting properties on all off the controls for width, color etc, use CSS classes for all styling.
Disable ViewState where you can, this can add significantly to page size.
|
|
|
|
|
Thanks to reply.
Is there any way to directly optimize the html in aspx pages.
because first i have to save that aspx page into html then I can try to revomove unnecessary code.
|
|
|
|
|
If you are having issues with the size of pages, then check if you are abusing the ViewState by putting too much junk into it. You can turn use of the ViewState off on controls that don't need to track state.
If its just your markup thats getting too big, either redesign your pages or switch on HTTP compression. :P
|
|
|
|
|
Syed Ali Raza wrote: How can i optimize the HTML through Code
There are many methods. I believe CP has some excellent articles on this subject. Try doing a search. I'd suggest the following
1 - Disable viewstate if it is not required
2 - Implement lazy loading kind of stuff using AJAX. So you won't load unnecessary data on page load,
3 - Don't use tables for page outlining. If you are using, make it small. Don't wrap whole content in one table. Browsers can render the content only after getting the end element. So wrapping the whole content in a single table will make rendering slow.
4 - Don't use DataGrid/GridView unnecessarily. Try with some lightweight controls like repeater.
many more..
|
|
|
|
|
Hi Coders,
I use Update Panel in my Page. there is a textbox having property password type when the page refresh the password in that textbox get disappear.I want to show that password all time.
Any Help would be appreciated.
Gautam
|
|
|
|
|
u can store password in a cookie
|
|
|
|
|
|
|
I think because it is a password type textbox it wont save the text typed in.
Deliver yesterday, code today, think tomorrow.
"http://www.heuse.com/cphumor.htm"
|
|
|
|
|
I know this but tell me how can I overcome this problem
|
|
|
|
|
Check this Thread out it might help you
Password Textbox
Deliver yesterday, code today, think tomorrow.
"http://www.heuse.com/cphumor.htm"
|
|
|
|
|
|
Your question doesn't suit this forum. Its not ASP.NET question. please go to proper forum for better answer
Anand Desai
Developer
Atharva Infotech
|
|
|
|
|
Well, you obviously didn't like my answer when you asked this last time, but I'll still try and give you one last chance. If you are using SQL Server there is no such instruction as LOCK [TABLE].
As you are obviously not that familar with SQL I suggest you do some reasearch before playing with isolation levels. After using relational databases for the best part of 20 years I can count on the fingers of both hands the number of times I have had to alter the default isolation levels to achieve simple locking.
Finally, to repeat myself one more time, if you lock a record when a user starts to VIEW it you are asking for problems. What if they leave it on their screen and go for lunch or go home? Nobody else will be able to do anything with it.
Simple rule of thumb, aquire locks late and release early.
Good luck, you will need it.
Bob
Ashfield Consultants Ltd
|
|
|
|
|
I am writing test cases using NUnitAsp, am unable to inherit the class WebFormTestCase Class into my tsetscalss.
Am i missing any reference or what?
Please, can anyone help me?
|
|
|
|
|
How to create a PDF file using ASP.NET
|
|
|
|