|
ashutosh_karna wrote: Can anybody tell me how do i put a java applet in asp.net page (.net 3.5)
Here is my complete article on Java and .net integration. Hope this will help you.
ashutosh_karna wrote: Also, is it possible to show slideshow in a small box withing an asp.net page. if yes, Please tell me how?
Why you want to use java applet for this. Normal javascript can do it easily. If you are going to use java applet that is an overhead. If Applet is disabled in the browser it will not work.
|
|
|
|
|
I have a some report messages in a content place holder within a master page in .aspx page.
I want to put a "Save Button" on my page, which saves the webpage to user's computer (just like "SaveAs File dialog box" in windows application". Can anybody tell me how do I save a webpage in .txt or .pdf or .doc or .htm format (any of theses) on button click event
|
|
|
|
|
You want to save the page content in client system when user click on save button on you page?
|
|
|
|
|
|
When they push the button, you render the content of the page to a stream and pass that with a content header to say it's a file. To save as anything other than plain text, requires more work, a third party add in, or the Microsoft tools for office. htm is easy, that's what you were sending in the first place, so you don't need to reformat it at all, just stream it.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
I have a gridview in webpage, which generates a new row with 2 textboxes on clicking a button by end - users. Now, I dont want my users to press a button each time they want to add a new row & then enter some data in textboxes. Instead, I want to call button_click method as soon as "tab" key is pressed and focus is automatically set to the next row's first textbox.
How can I do it in asp.net with C#?
Please also, tell which namespace is to be added.
|
|
|
|
|
With javascript. Call the method that your click event calls, in js, in the right event of the tab.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
Hi All,
I need to a regular expression for 'RFC 3986 URI' validation. Can someone help me?
Thanks...
MJ_Developer
|
|
|
|
|
mj_developer wrote: I need to a regular expression for 'RFC 3986 URI' validation
RFC 3986 URL Validation
May this will help you
|
|
|
|
|
Hi All,
I have a problem with "ExecuteNonQuery". When I insert or update my database record then SqlCommands.ExecuteNonQuery always return -1 but same thing I use another sql server its working fine.
I am sure that the actual problem is in my MS-SQL Server.
what should I do? Please me out.........
Thanks
Raj
|
|
|
|
|
For UPDATE, INSERT, and DELETE statements, the return value is the number of rows affected by the command. When a trigger exists on a table being inserted or updated, the return value includes the number of rows affected by both the insert or update operation and the number of rows affected by the trigger or triggers. For all other types of statements, the return value is -1. If a rollback occurs, the return value is also -1.
Anyways if you are able post here your piece of code and Sql statement then would be helpful to assist you.
|
|
|
|
|
hi,
No, you could not understand what I want to say. My previous all projects were working fine all ExecuteNonQuery working well but now I don't know all are ExecuteNonQuery return -1. When I used different used another SQl Server installed in other PC. then is works fine.
|
|
|
|
|
Did you read the quote from my Post ?
|
|
|
|
|
Show your code to see where could be problem.
I Love T-SQL
"Don't torture yourself,let the life to do it for you."
If my post helps you kindly save my time by voting my post.
|
|
|
|
|
Quote From MSDN NOCOUNT affects the return value
it says "For UPDATE, INSERT, and DELETE statements, the return value is the number of rows affected by the command. For all other types of statements, the return value is -1. If a rollback occurs, the return value is also -1."
There is another case that causes it to return -1: if NOCOUNT is set to ON. This usually happens because the query includes the line "SET NOCOUNT ON", but it can also be set in the "Connection Defaults" screen in the SQL Server management tool.
Please go through the statement. Hope this will help you.
|
|
|
|
|
Hi,
I have to print only the cheque numbers on the cheque pad which is a continuous roll of paper.I am printing it using javascript.Only first four cheques includes in the first page. when second page comes,certain height gap comes.After every page,there is some gap in the page break.How can i overcome this problem?
regards
Bill
|
|
|
|
|
You can't. All js can do, is print the current page. You'd have to load all your cheques onto one page and print that page.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
<asp:ObjectDataSource ID="ObjectDataSource1" runat="server" DataObjectTypeName="G1_OnlineStoreObjects.Book"
DeleteMethod="Delete" SelectMethod="LoadBySeries" TypeName="G1_OnlineStoreDAO.BookDAO"
UpdateMethod="Update">
< SelectParameters >
<asp:QueryStringParameter Name="seriesID" Type="Int32" QueryStringField="SeriesID" />
< / SelectParameters >
< / asp:ObjectDataSource >
<asp:ObjectDataSource ID="ObjectDataSource2" runat="server" DataObjectTypeName="G1_OnlineStoreObjects.Book"
DeleteMethod="Delete" SelectMethod="LoadByVolumes" TypeName="G1_OnlineStoreDAO.BookDAO"
UpdateMethod="Update">
< SelectParameters >
<asp:QueryStringParameter Name="volumeID" Type="Int32" QueryStringField="VolumeID" />
< / SelectParameters >
< / asp:ObjectDataSource >
<asp:GridView Visible="false" ID="GridView1" runat="server" AutoGenerateColumns="False"
DataKeyNames="ID,SeriesID,VolumeID" DataSourceID="ObjectDataSource1" CellPadding="4"
ForeColor="#333333" GridLines="None">
< Columns >
<asp:CommandField ShowEditButton="True" ShowDeleteButton="True" />
<asp:BoundField DataField="BookName" HeaderText="BookName" SortExpression="BookName" />
< / Columns >
< / asp:GridView >
<asp:GridView Visible="false" ID="GridView2" runat="server" AutoGenerateColumns="False" DataKeyNames="ID,VolumeID,SeriesID"
CellPadding="4" DataSourceID="ObjectDataSource2" ForeColor="#333333" GridLines="None">
< Columns >
<asp:CommandField ShowDeleteButton="True" ShowEditButton="True" />
<asp:BoundField DataField="BookName" HeaderText="BookName" SortExpression="BookName" />
< / Columns >
< / asp:GridView >
besides that i have 2 page: Series.aspx and Volume.aspx. in Series when I click at some field I want it redirect me on ObjectDataSource1 and GridView1. like that when I click at Volume's field must redirect me on ObjectDataSource2 and GridView2.
How different this 2 DataSource in codebehind?
C# Developer
|
|
|
|
|
can anybody tell me how to bind css file to web user control!
as if im using master page,i can bind css file but i want to know if there is any way to add tag
for css in web user control!
|
|
|
|
|
Spurple wrote: i want to know if there is any way to add tag for css in web user control!
You are talking about Custom user control? You can simple add the css reference like you did in same other page. Please correct me if my understanding of your question is wrong.
|
|
|
|
|
you need to bind the css once in a page.just include it in the master page that will be available in the entire page.i e you webusercontrol will also be able access the css if master page is applied on the page.
|
|
|
|
|
Hi to all,
I am trying to send the "contact us" from data to email on submit button click. But giving this error.
Server Error in '/VICTORIAIN' Application.
Mailbox unavailable. The server response was: not local host hotmail.com, not a gateway
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.Net.Mail.SmtpFailedRecipientException: Mailbox unavailable. The server response was: not local host hotmail.com, not a gateway
Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.
Stack Trace:
[SmtpFailedRecipientException: Mailbox unavailable. The server response was: not local host hotmail.com, not a gateway]
System.Net.Mail.SmtpTransport.SendMail(MailAddress sender, MailAddressCollection recipients, String deliveryNotify, SmtpFailedRecipientException& exception) +858231
System.Net.Mail.SmtpClient.Send(MailMessage message) +2004
Contact_Us.send_data_to_mail() +189
Contact_Us.BtnSubmit_Click(Object sender, EventArgs e) +18
System.Web.UI.WebControls.Button.OnClick(EventArgs e) +105
System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) +107
System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) +7
System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +11
System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +33
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1746
Version Information: Microsoft .NET Framework Version:2.0.50727.1433; ASP.NET Version:2.0.50727.1433
I am using this code:
SmtpClient smtpClient = new SmtpClient();
MailMessage message = new MailMessage();
MailAddress fromAddress = new MailAddress(TxtEmail.Text, TxtName.Text);
message.From = fromAddress;
message.To.Add("rohanrajpoot@in.com");
message.Subject = "This person has contacted us!";
message.IsBodyHtml = false;
message.Body = TxtMessage.Text;
smtpClient.Send(message);
In web.config I did this:
<system.net>
<mailSettings>
<smtp>
<network host="myhostname" port="25" userName="loginname" password="pass" defaultCredentials="true" />
</smtp>
</mailSettings>
</system.net>
Can anyone assist me....
cheers,
sneha
|
|
|
|
|
sneha Choudhary wrote: <smtp>
<network host="myhostname" port="25" username="loginname" password="pass" defaultcredentials="true">
Does SMTP configure Properly ?
|
|
|
|
|
I agree with the previous comment, it seems like your SMTP mail server must be configured incorrectly in your web.config file. I tested your code (slightly modified), using localhost as the mail server; it worked just fine.
string TxtEmail = "Sue.Smith@123.com";
string TxtName = "Sue Smith";
string TxtMessage = "This is a test email message.";
using(MailMessage message = new MailMessage())
{
message.From = new MailAddress(TxtEmail, TxtName);
message.To.Add(new MailAddress("rohanrajpoot@in.com"));
message.Subject = "This person has contacted us!";
message.IsBodyHtml = false;
message.Body = TxtMessage;
SmtpClient smtpClient = new SmtpClient { Host = "localhost" };
smtpClient.Send(message);
}
Regards,
Gary
|
|
|
|
|
Hi All,
Did any one know how to use HighSlide Popup in .net and I need to Show Routeplanner in highslide popup?
Can any one help me ?
Thankyou In Advance,
YamunaRani.
|
|
|
|