Skip to content

All posts by Manoj - 3. page

Overload Webservice.

TO workout the error when we overload the [WebMethod] like the following you must change webservice code as follows However, we may also get errors if which is the auto […]

Use Session Enabled Webservice in WindowsForm.

public class MyService : System.Web.Services.WebService { [WebMethod(EnableSession=true)] public void setMethod(bool value) { Session[“myBoolVariable”] = value; } [WebMethod(EnableSession=true)] public bool getMethod() { return (bool)Session[“myBoolVariable”]; } }   In above Webservice Session […]

StrorProcedure To Generate Data Provider Class From Table

************** Execute StoreProcedure **************** sp_CreateDataProviderFromTable ‘Tablename’, ‘name’ ************** StoreProcedure to store *************** CREATE proc [dbo].[sp_CreateDataProviderFromTable] ( @TableName NVARCHAR(50), @MethodName varchar(100) ) as DECLARE @ProtdVars VARCHAR(max),@PublicProps VARCHAR(max), @CMDProps VARCHAR(max), @InsertStmt VARCHAR(max), […]

Store Procedure To Generate Class From Table

*********** Execute StoreProcedure ********************** sp_GenerateClassFromTable ‘TableName’ *********** StoreProcedure to store ********************* CREATE proc [dbo].[sp_GenerateClassFromTable] ( @TableName NVARCHAR(50) ) as DECLARE @ProtdVars NVARCHAR(max),@PublicProps NVARCHAR(max), @CMDProps NVARCHAR(max), @InsertStmt NVARCHAR(max), @UpdateStmt NVARCHAR(max) Declare […]