use.. Inserted.Locationcode it will fetch the location code from inserted location enjoy :)
Dinesh Sharma
use.. Inserted.Locationcode it will fetch the location code from inserted location enjoy :)
Dinesh Sharma
Use this ....enjoy :) MSCal.SelectedDate = YourDate;
Dinesh Sharma Team Leader (Software Development)
Use this....enjoy :) RegisterClientScriptBlock("Alert", "alert('Purchase Invoice save successfully')");
Dinesh Sharma Team Leader (Software Development)
Hello Frends I m using ASP.Net 2.0 and trying to send mail but its showing me error ... Error Message is --Mailbox unavailable. The server response was: 5.7.1 Unable to relay for dineshsharmain@gmail.com my code is -- in web.config - and in .CS File - try { MailMessage message = new MailMessage(); message.From = new MailAddress(txtEMailFrom.Text); message.To.Add(new MailAddress("dineshsharmain@gmail.com")); message.Subject = txtSubject.Text; message.Body = txtMsg.Text; SmtpClient client = new SmtpClient(); client.Send(message); lblMsg.Text = DeliveryNotificationOptions.OnSuccess.ToString(); } catch (SmtpException ex) { lblMsg.Text = ex.Message + " " + ex.InnerException; } Thanx Dinesh Sharma
Hi just use document.form1["TextBox"].value to set or get values
Dinesh Sharma Team Leader (Software Development)
Hi guffa thanks for your great help.....Now I am able to do this :cool:. Thanks :)
Dinesh Sharma
Hi Frends I wanna call a java function on page load event on my .aspx.cs page and want to pass some values from there....but its not working.....:confused: I am doing like this.... this.Attributes.Add("onload", "setObj('Dinesh','Sharma',550,30)"); not working actually i need to call this java function on page load so i can use it like but i cant pass the values from my .cs page is there any way to pass the value from .cs page :confused: Dinesh Sharma -- modified at 3:59 Saturday 19th August, 2006
Dinesh Sharma
Thanks ToddHileHoffer I done this and now its working properly... Thanks a lot Dinesh Sharma
Dinesh Sharma
Hi frends I have written a trigger in MS-SQL 2000 runing successfully to insert single row.....but if i need to insert multiple rows from a select query in this trigger ......I am Confused ? :confused: Purpose of Trigger whenever a column will be updated in a table the data from two tables will be inserted into two tables where one table has multiple rows to insert. I am trying to use While loop but confused that what should be the condition there to break tha loop......pls help if someone knows. :confused: My trigger is IF (COLUMNS_UPDATED() ) > 49 BEGIN Declare @ServerDate datetime; Declare @TranID numeric(18,0); Declare @OppID numeric(18,0); Declare @ProductID int; Declare @Qty int; Declare @Cost numeric(18,2); Declare @Price numeric(18,2); Declare @Discount numeric(18,2); Declare @TaxAmt numeric(18,2); Declare @UserID numeric(18,0); Declare @ContactID numeric(18,0) Declare @CountProduct int SELECT @ServerDate=getdate() SELECT @OppID=Opp.OppId, @ContactID=Opp.ContactID, @UserID=Opp.UserID FROM Opportunity Opp INNER JOIN INSERTED ON Opp.OppId = INSERTED.OppId where Inserted.StatusID=3 if (Convert(varchar(10),@OppID) != '') BEGIN INSERT INTO [Transaction] (OppID,TranDate, ContactID,UserID) values (@OppId, @ServerDate, @ContactID, @UserID) SELECT @TranID=TranID from [Transaction] where TranDate=@ServerDate SELECT @ProductID=Opp.ProductID, @Qty=Opp.Qty, @Cost=Opp.Cost, @Price=Opp.Price, @Discount=Opp.Discount, @TaxAmt=Opp.TaxAmt FROM vOpportunityList Opp INNER JOIN INSERTED ON Opp.OppId = INSERTED.OppId where Inserted.StatusID=3 --Count row SELECT @CountProduct=count(Opp.ProductID) FROM vOpportunityList Opp INNER JOIN INSERTED ON Opp.OppId = INSERTED.OppId where Inserted.StatusID=3 --WHILE (-----------) --BEGIN INSERT INTO [TranProduct] (TranID,ProductID,Qty,Cost,Price,Discount,TaxAmt) values(@TranID, @ProductID, @Qty, @Cost, @Price, @Discount, @TaxAmt) --END END END
Dinesh Sharma
Hi Frends I am trying to write a trigger ....whenever a particular column updates in my table then this record i.e. updated should be inserted in another table. but problem is that its inserting all the records in IInd table whenever i update the record in first table. My trigger is...... CREATE TRIGGER CreateTrans ON [dbo].[Table1] FOR UPDATE AS IF (COLUMNS_UPDATED() & 49)=49 BEGIN INSERT INTO [Table2](x.ID) SELECT ID FROM Table1 x END GO Thanks Dinesh Sharma -- modified at 5:25 Wednesday 26th July, 2006
Dear All I have taken a backup for my database and trying to restore it on another computer .....but its showing me error while i m restoring this database... error is Too many backup devices specified for backup or restore only 64 are allowed. pls give me a solution if someone knows abt that...:confused: Dinesh Sharma
Hi frends I have developed my web application by using ASP.net 2.0 but not getting the idea to implement this on server ..... as we do in asp.net 1.1 create dll file and put it into bin folder keep all the .aspx files in folder and upload on to web server..... but in ASP.net 2.0 i am unable to create the DLL file and configure to IIS also... anybody can help....... Dinesh Sharma
hi all can i use multi threading in asp.net for my web application .....if yes then how?:confused: Dinesh Sharma
I am using cvsNT and tortoise CVS but i know nothing about it... that how to use it ...I am working on ASP.Net so if it would be on server and i 'll access it through client i'll have to configure IIS also.....how is it possible... pls suggest Thanx Dinesh Sharma
how can i put my project folder in repository on server to access the project by all team member. i wanna use cvs for it...but how ? I dont know that where should i put my folder in server :confused: :confused: Dinesh Sharma
how can i put my project folder in repository on server to access the project by all team member. i wanna use cvs for it...but how ? I dont know that where should i put my folder in server :confused: :confused: Dinesh Sharma Team Leader (Software Development)
how can i put my project folder in repository on server to access the project by all team member. i wanna use cvs for it...but how ? I dont know that where should i put my folder in server :confused: :confused: Dinesh Sharma
how can i put my project folder in repository on server to access the project by all team member. i wanna use cvs for it...but how ?:confused: I dont know that where should i put my folder in server Dinesh Sharma
how can i return 0 (false) for an error to insert data in SQL database. i am using ASP.Net (using vb.net) to call the stored procedure.... my procedure is... CREATE PROCEDURE Insert_Book ( @arg_Title VARCHAR(255), @arg_Price VARCHAR, @arg_PublishDate DATETIME, @arg_BookID INT OUT) AS DECLARE @rc Int BEGIN INSERT INTO Book ( Title, Price, PublishDate ) VALUES ( @arg_Title, @arg_Price, @arg_PublishDate ); /*SELECT @arg_BookID = @@IDENTITY;*/ IF @@ERROR <> 0 BEGIN /*SELECT @rc = 0*/ /*Print convert(Varchar,"An error occurred while adding the new Book information")*/ RETURN (99) END ELSE BEGIN /*SELECT @rc =99*/ /*PRINT Convert(Varchar,"The new author information has been loaded")*/ RETURN (0) END procedure call is... con = New clarion.connection Conn = New SqlClient.SqlConnection Conn.ConnectionString = con.GetConnectionString() Dim cmdtxt As SqlClient.SqlParameter Dim objErr As SqlClient.SqlException Dim txtAbbreviation As String Dim txtReturnCode As String Conn.Open() Dim cmd As New SqlClient.SqlCommand("Insert_Book", Conn) cmd.CommandType = CommandType.StoredProcedure cmdtxt = cmd.Parameters.Add("@arg_Title", "Nisha") cmdtxt.Direction = ParameterDirection.Input cmdtxt = cmd.Parameters.Add("@arg_Price", "") cmdtxt.Direction = ParameterDirection.Input cmdtxt = cmd.Parameters.Add("@arg_PublishDate", "01/05/06") cmdtxt.Direction = ParameterDirection.Input cmdtxt = cmd.Parameters.Add("@arg_BookID", "") cmdtxt.Direction = ParameterDirection.Input cmdtxt = cmd.Parameters.Add("@@Error", SqlDbType.Int) cmdtxt.Direction = ParameterDirection.ReturnValue cmd.ExecuteNonQuery() Conn.Close() If Convert.ToInt32(cmd.Parameters.Item("@@error").Value) <> 0 Then txtAbbreviation = Convert.ToString(cmd.Parameters.Item("RC").Value) txtReturnCode = Convert.ToString(cmd.Parameters.Item("@@error").Value) Else txtAbbreviation = Convert.ToString(cmd.Parameters.Item("@arg_Price").Value) txtReturnCode = Convert.ToString(cmd.Parameters.Item("@@error").Value) End If Dinesh Sharma Software Engineer