|
WHAT IS MY SMTP SERVER AND HOW CAN I KNOW MY SMTP PLEASE?? I AM USING AN MS ACCESS NOT SQL .. THANKS FOR YOUR HELP!!
Adrian De Battista: .Net Programmer, Java Programmer and Web Designer.
|
|
|
|
|
Please don't shout....
ADY007 wrote: WHAT IS MY SMTP SERVER AND HOW CAN I KNOW MY SMTP PLEASE
Which bit don't you understand? Your SMTP server is an SMTP server that you control ( ). If you're not using SQL server, IIS also has one built in.
If you still can't find one, try talking to your company's admins - most will let developers use it if they behave themselves, and failing that, you'll just have to look for one of your own to download....plenty of them kicking around - try Google.
"Now I guess I'll sit back and watch people misinterpret what I just said......"
Christian Graus At The Soapbox
|
|
|
|
|
Hi, I read an article that said web controls caused performance problems when the application had much traffic.
But I have forgotten the link, does someone knows an article about this subject?
Thanks.
//Victor Blomberg, victor-y.com
|
|
|
|
|
|
Thanks!
But the content of that article I read where that you could not use web controls at all in certain situations. And yes, I have tested google, but unfortunately did I not found the article.
//Victor Blomberg, victor-y.com
|
|
|
|
|
Hey Victor,
Like I said earlier, there are lots and lots of articles floating on the internet about improving web applications (asp.net in particular). I don't know where you heard such harsh/radical statements about asp.net controls... in one of my projects I went crazy with the web controls, and the web site was just fine as far as performance.
Here is my advice:
1) If you need to trigger/handle an event only on the "client" side, use html controls (with JavaScript, of course).
2) If you need to make the roundtrip to the server, but you do NOT need to maintain any data being persisted within that control, use web control BUT make sure to set its ViewState property to False.
3) Avoid asp.Panel controls whenever possible, instead, use the good old html table
4) If you are using GridView that is connected to only ONE data source, you can set that GridView's ViewState property to false. This is because generally data controls data bind dynamically at each page load.
5) Put as much burden as possible on your client, learn to implement AJAX, and avoid postbacks.
6) Masterpages are convenient and look cool (I have three of them nested in one of my projects), but in the end they will be rendered as one GIANT page with a BIG ViewState and many web controls... long story short, keep your pages simple.
7) Make sure your app is NOT in debug mode after deployment.
8) Cache your web controls
9) ...the list goes on and on!
Nila
|
|
|
|
|
FIXED - CORRUPTED RECORDS IN DATABASE WERE THE PROBLEM
I'm using this code to retrieve images from an SQL Server DB. For some reason all the images are blurry. Anybody know why? I've verified the images stored in the DB are not blurry so I find it strange.
http://www.samspublishing.com/articles/article.asp?p=377078&seqNum=2&rl=1[^]
- Rex
Last modified: 7hrs 13mins after originally posted --
|
|
|
|
|
The strange thing is that it's not doing it to every image. Some look great and some look blurry and it's all using the same code. Is there something I need to do to repair images in SQL Server...
|
|
|
|
|
What format are your images in? What are you downloading them as?
More importantly, blurry images normally mean that the size does not match the original size. So, a 320x280 image will appear blurry if viewed at 300x270.
the last thing I want to see is some pasty-faced geek with skin so pale that it's almost translucent trying to bump parts with a partner - John Simmons / outlaw programmer
Deja View - the feeling that you've seen this post before.
|
|
|
|
|
I'm using that code almost verbatim. Every image is a jpeg and I batch sized all of them down for huge 3+ meg images to 200Kb on average images using "Easy Thumbnails" which will do more than just thumbnails. It's a nice product to just give away.
Oddly all of the images from Easy Thumbnail look great on disk and some of them look bad out of the DB. Here's my actual code (the output parameter is the URL parameter of the Image):
if (Request.QueryString["ImgID"] != null && Request.QueryString["Orientation"] != null)
{
System.Int32 _ImgID = Convert.ToInt32(Request.QueryString["ImgID"].ToString().Trim());
string _Orientation = Request.QueryString["Orientation"].ToString().Trim();
HttpContext.Current.Session["PrevID"] = _ImgID;
SqlDataReader thisReader = null;
SqlConnection thisConn = new SqlConnection(ConfigurationManager.ConnectionStrings["MediaGalleryConnectionString"].ConnectionString);
SqlCommand thisCmd = new SqlCommand("Command String", thisConn);
tmpStr = "Select PageImage, PageText from PhotoGallery WHERE RecordID='" + _ImgID.ToString() + "'";
thisCmd.CommandText = tmpStr;
try
{
thisConn.Open();
thisReader = thisCmd.ExecuteReader(CommandBehavior.CloseConnection);
while (thisReader.Read())
{
System.Drawing.Image _image = System.Drawing.Image.FromStream(new System.IO.MemoryStream((byte[])thisReader["PageImage"]));
System.Web.HttpContext.Current.Response.ContentType = "image/jpeg";
if (Request.QueryString["Orientation"].ToString().Trim() == "Landscape")
{
System.Drawing.Image _newimage = _image;
_newimage.Save(System.Web.HttpContext.Current.Response.OutputStream, System.Drawing.Imaging.ImageFormat.Jpeg);
}
else if (Request.QueryString["Orientation"].ToString().Trim() == "Portrait")
{
System.Drawing.Image _newimage = _image;
_newimage.Save(System.Web.HttpContext.Current.Response.OutputStream, System.Drawing.Imaging.ImageFormat.Jpeg);
}
}
}
catch{}
finally{}
}
|
|
|
|
|
Got it. Corrupted images in the database. I delete the entire record. Recreate it with a new PK/Index and it's all good. Strange.
- Rex
|
|
|
|
|
Hi All,
I am using DataGrid Control to ASP.NET,C# Web Application.
I have added template column for Data Grid and added Image button for ItemTemplate.
Now I need to fire Click event when Image button Pressed on a Perticular Data Row .
There are 20 or More rows in a DataGrid.
Can any one tell me how to bind ClickEvent for ImageButtons on a Template Column?
Thanks in advance.
|
|
|
|
|
Hi,
You can use oncommand for the imagebutton. Add an image button to your template like so.
<<asp:imagebutton commandargument="ValueYouPassIN" commandname="ImageClick" oncommand="ImageClick_Command" id="ImageButton1" runat="server">
Then just create a method that does what you want.
<br />
protected void ImageClick_Command(object sender, CommandEventArgs e) <br />
{<br />
Response.Write("test");<br />
<br />
} <br />
<br />
Regards
tom
|
|
|
|
|
hi there,
when redirect to another page using response.Redirect() ,it generates
an http get operation , i want to change the headers for that (get) to add cookie , i tried to use respnse.AddHeader(), request.Headers.Add() but didn't work ,it is urgent thanks
|
|
|
|
|
I'm sure this has been posted a million times before, but how do i force my footer stay at the bottom of my browser, even if the content is too small to push it down.
Posted by The ANZAC
|
|
|
|
|
Try this article on alistapart:
http://www.alistapart.com/articles/footers/[^]
the last thing I want to see is some pasty-faced geek with skin so pale that it's almost translucent trying to bump parts with a partner - John Simmons / outlaw programmer
Deja View - the feeling that you've seen this post before.
|
|
|
|
|
Hi Guys i need a help,
i'am creating a report application using ASP.NET & Crystal Report in VS2003,
i'am retrieving a lot of data from Oracle DB, it's about more than 75000 records.
if the amount of record less than 1500 it works fine and fast,
my problem is if the record number greater than that = the process is taking to long and it will stop because the session is timeout.
can somebody in here tell me how to generate report faster?
thanx
|
|
|
|
|
fajrif wrote: i'am retrieving a lot of data from Oracle DB, it's about more than 75000 records.
if the amount of record less than 1500 it works fine and fast,
my problem is if the record number greater than that = the process is taking to long and it will stop because the session is timeout.
Do you individually display all 75000 rows in the report, or are they aggregated in some way? If they are aggregated then it may be a good idea to produce a set of tables with the precalculated aggregates that can be used for the report. This is a common technique used to help generate a standard set of reports quickly. The drawback is that the data used for the report is not updated as frequently as the data in the source tables. Typically the reporting tables will be updated by an overnight batch, or at the weekend or month end depending on the type of report that is needed.
|
|
|
|
|
We are doing the same exercise. Table is having millions of records. Then we are storing agg values in tables i.e. Fact table. And life is simple. And make sure you use stored procedure and with good index technq. It really works and helps. I am eye witness for the same.
Amit
|
|
|
|
|
This many records are going to take a long time to produce in Crystal Reports, pretty much no matter what you do. Remember that the problem is not just the extraction of the records, it is also the rendering them for output (and that's a lot of data to play with). In situations like this, I would see if it is possible to pre-render the reports ready to be displayed.
the last thing I want to see is some pasty-faced geek with skin so pale that it's almost translucent trying to bump parts with a partner - John Simmons / outlaw programmer
Deja View - the feeling that you've seen this post before.
|
|
|
|
|
I want to show my error page in new page. Old page should still shows old data.
I write in applicationerror event in global, this:
response.write("window.open('errorpage.aspx')");
But there is a problem with it. The old page shows aspx error message displaying my code and exception. If I set custom error in config, my old page will be redirected to errorpage which is set in custom error tag.
If I use Server.ClearError() method, the old page will be cleared entirely and shows blank page.
I WANT MY OLD PAGE TO SHOW THE OLD DATA WITH USER CHANGES WHICH CAUSING ERROR AND THE NEW PAGE, SHOWS MY ERRORPAGE LIKE ERROR MESSAGE IN WINDOWS APPLICATION.
I don't want to handle my all errors by try catch. I want to handle all of them in allication error. Because I can find my latest exception by Server.GetLastError() method.
Please instruct me what to do.
Thanks
Rastgar
|
|
|
|
|
See the section on Application_Error in http://support.microsoft.com/kb/306355[^].
the last thing I want to see is some pasty-faced geek with skin so pale that it's almost translucent trying to bump parts with a partner - John Simmons / outlaw programmer
Deja View - the feeling that you've seen this post before.
|
|
|
|
|
Anyone know how to get / set the position of the scrollbars on a panel web server control.
Thus I can remember where a user was in a given panel, if they had used the scroll bars???
Many thanks
|
|
|
|
|
yourpanleid.scrollTop, yourpanelid.scrollLeft.
for your panel id, refer your page html which is rendered.
note, these two methods are client side methods.
you can save them in a hidden field. i save them in a hidden textbox by scrollchange() method. and set them by changescroll() method:
function scrollchange()
{
document.getElementById("txtScroll").value=document.body.scrollTop;
document.getElementById("txtScroll").value+=";"+document.body.scrollLeft;
}
function changescroll()
{
if(document.getElementById("txtScroll").value != "")
{
parts = document.getElementById("txtScroll").value.split(";");
document.body.scrollTop = parseInt(parts[0]);
document.body.scrollLeft = parseInt(parts[1]);
}
}
Thanks
Rastgar
|
|
|
|
|
Hi Rastgar
Many thanks for the pointer - FYI my implementation of the initialisation, is like this: (c#)
StringBuilder sb = new StringBuilder();
sb.Append("");
sb.Append("var szValue = document.getElementById('Panel1');");
sb.Append("szValue.scrollTop = 146;");
sb.Append("szValue.scrollLeft = 182;");
sb.Append("");
ClientScript.RegisterStartupScript(typeof(string), "Init", sb.ToString());
This then just runs at startup.
And of course I can harvest the values from the user by any number of means
Once again, many thanks
regards, John
|
|
|
|