|
Elizma wrote: I understand this must be done in AJAX
You can do this without using AJAX concepts also. Handle the particular event and rebind the grid after deletion.
If you need to do with AJAX, you can work with XmlHttpRequest and response objects which allows to send request to server pages in AJAX fashion.
Easy alternative for implementing AJAX in ASP.NET is to use ASP.NET AJAX extensions. Download the AJAX toolkit and work with the controls provided in it.
Elizma wrote: ask the user if he/she is sure they want to delete the row
Assuming you will use AJAX toolkit, there is a ModalPopup control available. Use that to get confirmation from user. The Grdiview has to be placed in an UpdatePanel control so that it will be updated without a page refresh.
|
|
|
|
|
Hi,
I need to set the my webrequest as it is originating from a search engine crawler.
So, The server side code can have "true" value for IsCrawler Propety.
I am using WebRequest Class to Make the Request.
Please, I have been searching this for a month.
Thanks,
Nagaraj
|
|
|
|
|
Nagaraj Muthuchamy wrote: I need to set the my webrequest as it is originating from a search engine crawler.
You can cast the WebRequest.Create to a HttpWebRequest object and set the UserAgent property similar to a crawler sets. This[^] paper explains how a crawler is identified. Read this and follow the same format.
|
|
|
|
|
i have an aspx page with few control
i wants its clientid in an external javascript file
how do i get it
i am using vb.net as the code behind
at present in my external js file i have
var tid = document.getElementById("shapedrpdw");
can anybody help
|
|
|
|
|
Seriously Speaking, I am not able to understand your problem. Do you want to pass some controls id to External JS files ?
cheers,
Abhijit
|
|
|
|
|
The reason I ask is that I have found a site in PHP(LAMP) which meets my customer's needs almost perfectly, but I may need to add one more site in the same FTP which has done it in ASP.net as I am a .NET programmer. However, I Would like to convert my project from windowx platform to Linux with the help of mono project.can i sucess it?have any problem at hosting time?Plz reply as soon as possible
By
Soumya
|
|
|
|
|
soumyaraj wrote: can i sucess it
It depends. AFAIK, MONO has implemented till .NET framework 2.0. Having said that, if your application is using any .NET 3.0/3.5 specific classes, it will not work on MONO. You can download a compatibility checking program from their website which will report the possible errors in the conversion.
I'd rather take a new windows hosting where PHP and ASP.NET is supported and migrate the existing PHP website to this new server rather than thinking about MONO.
|
|
|
|
|
i have done it in Asp.net 2.0
|
|
|
|
|
i have the details in dropdown list, when i clicked the submit button it wll reflect in gridview.... anyone can help...
|
|
|
|
|
You want to means Gridview data should be based on selection of Dropdownlist. If yes, then You can !!. On click on Submit button, fetch the data from database( If it your data source ) based on Dropdown list values and display it in Grid.
cheers,
Abhijit
|
|
|
|
|
venkatnaras wrote: i have the details in dropdown list, when i clicked the submit button it wll reflect in gridview
You are not understanble.Please be in detail for correct answer
Cheers!!
Brij
|
|
|
|
|
beyond a certain limit my string builder does not append the string and its value becomes
null.(i.e. when beyond some length of string)
what can i do for this.
|
|
|
|
|
bhavna4321 wrote: beyond a certain limit my string builder does not append the string and its value becomes
null
Weird! What is the reason for appending such huge strings?
|
|
|
|
|
Is there any exception?
First check the capacity of stringbulder object if it is less than the string you are assigning to stringbuilder then increase the capacity using the property Capacity or EnsureCapacity mathod.and let me know the result too.
Cheers!!
Brij
|
|
|
|
|
Brij wrote: then increase the capacity using the property Capacity or EnsureCapacity mathod
You don't need to ensure the capacity explicitly. StringBuilder knows to grow and shrink whenever required.
|
|
|
|
|
You are right Navneeth.but the amount of memory allocated is implementation-specific, and ArgumentOutOfRangeException is thrown if the amount of memory required is greater than the maximum capacity.
Cheers!!
Brij
|
|
|
|
|
Hi all,
iam going to validate the email ID if it is already exist in DB using custom validator
Here is code
protected void ValidateEmail(object source, System.Web.UI.WebControls.ServerValidateEventArgs args)
{
string sqlCmd =
"SELECT Email FROM User_Profile WHERE Email = " +
Util.Quote(email.Value.Trim());
OdbcCommand command = new OdbcCommand(sqlCmd, con);
OdbcDataReader reader = command.ExecuteReader();
args.IsValid = !reader.HasRows;
reader.Close();
}
iam getting Error at this Place that
Util.Quote(email.Value.Trim());
'System.Web.UI.Util' is inaccessible due to its protection level
kindly guide me what iam doing wrong
best Regards
Rameez
modified on Monday, December 29, 2008 7:22 AM
|
|
|
|
|
rameez Raja wrote: 'System.Web.UI.Util' is inaccessible due to its protection level
Since I cannot find "Util" anywhere in the Microsoft documentation as a member of "System.Web.UI", nor any reference to a "System.Web.UI.Util" namespace, I would guess that it is not a public class/namespace. It is most likely something that is used internally in the .NET framework, and as such, you won't be able to use it directly.
WE ARE DYSLEXIC OF BORG. Refutance is systile. Your a$$ will be laminated.
There are 10 kinds of people in the world: People who know binary and people who don't.
|
|
|
|
|
MailAddress from = new MailAddress("nithya.d@demo.com");
MailAddress to = new MailAddress("nithydurai@gmai.com");
MailMessage message = new MailMessage(from, to);
message.Subject = "hai dear";
message.Body = "Hello this is a test Mail";
message.DeliveryNotificationOptions = DeliveryNotificationOptions.OnFailure | DeliveryNotificationOptions.Delay;
SmtpClient client = new SmtpClient("75.126.193.146");
// Include credentials if the server requires them.
client.Credentials = new NetworkCredential("info@afxisi.net", "afxisi");
message.Headers.Add("Disposition-Notification-To", "nithya.d@afxisi.co.in");
//client.SendCompleted += new
// SendCompletedEventHandler((this.SendCompleted));
Boolean bTemp = true;
try
{
client.Send(message);
}
catch (SmtpFailedRecipientsException ex)
{
for (int i = 0; i < ex.InnerExceptions.Length; i++)
{
SmtpStatusCode status = ex.InnerExceptions[i].StatusCode;
if (status == SmtpStatusCode.MailboxBusy ||
status == SmtpStatusCode.MailboxUnavailable)
{
Console.WriteLine("Delivery failed - retrying in 5 seconds.");
System.Threading.Thread.Sleep(5000);
client.Send(message);
}
else
{
Console.WriteLine("Failed to deliver message to {0}",
ex.InnerExceptions[i].FailedRecipient);
}
}
}
catch (SmtpException ex)
{
Response.Write(ex.ToString());
}
catch (ObjectDisposedException ex)
{
Response.Write(ex.ToString());
}
catch (Exception ex)
{
Response.Write(ex.ToString());
}
}
}
i send the wrong mail id... but this program not catch the SmtpFailedRecipientsException.... pls help me
|
|
|
|
|
First of all your code is broken. You copied the MSDN example directly into an ASP.NET page? A Console can't work on ASP.NET/web applications.
|
|
|
|
|
i also download the MSDN code.... mail send perfectly but i send wrong mailid... i cannot capture the failure mailid
|
|
|
|
|
Usually the mail-box unavailable or storage size exceeded kind of errors appear hours after you send the mail. This might be the reason that exception is not throwing. To test what I said, change the server to gmail(or whatever is the recipients mail server) and send the mail. Since both are in same server, I assume the exception can be raised by the SmtpClient class.
|
|
|
|
|
can you give any example coding sir
|
|
|
|
|
The example which you got from MSDN is enough. All you have to do is change the server to a server where your recipients email exist.
|
|
|
|
|
have u define web.config file
|
|
|
|