ASPForums.Net RSS Feed additions to the content that appears on ASPForums.Net(c) 2017 All rights reserved.Will Asynchronous email will be sent even after Web Page is closed in ASP.Net?<p>Hi,</p> <p>I'd like a suggestion, I read this good Article:</p> <p><a href=""></a></p> <p>My Req. is after some event (ie click button) start send email process, but I'd like that user can close also the webpage without waiting the response of sending email.</p> <p>How can I do this, working with webservice or ?</p> <p>Tks&nbsp;</p> <p>Br\Vincenzo</p>, 20 Oct 2015 05:13:21 GMTWhat FaultContract in WCF?<p>Hi</p> <p>I am having small clarification in Message and Fault Contract.</p> <p>fault contract is mainly used to handle the exception that happened in service to the consumer of the service. In other words it is used to customize the message in the service and send it to the consumer.</p> <p>My doubt is that why should i go for FaultContract. I can use MessageContract or Even i can put some datamember in the datacontract to store the exception and send it to the application.</p> <p>Hope this is clear. Please let me know if this is not.</p>, 06 Aug 2014 00:52:09 GMTWhat Asynchronous call in WCF<p>Hi</p> <p>can any one explain me async call in wcf. What is the advantage and how it is used in WCF</p>, 12 Aug 2014 04:23:50 GMTWeb Service vs ASP.NET Web API and implementing Web API<p>Hi,&nbsp;</p> <p>I am new to web service and Web API.</p> <p>Need to know practicle things which we can do with WEB API and not with web service, which can demonstrate, why we should prefer WEB API over WEB Serveice.</p> <p>&nbsp;</p> <p>Need example except web service using SOAP,XML etc, if any.</p>, 30 Sep 2016 02:11:08 GMTweb project C# run correctly on my system but it runs another system that time design change<p>web project in c# working properly on my system(Computer), but this project run on another syatem that time web page design will be change.</p> <p>web page design in the with &nbsp;css.</p> <p>what can i do for solve this issue ?</p>, 20 May 2016 01:43:08 GMTWCF Error Failed to update Service Reference 'WCFService.Reference' There was an error downloading<p>Error1Failed to update Service Reference 'SecurityWCFService.Reference'.Error:There was an error downloading 'http://localhost/SecServiceSite/Service.svc'.The request failed with HTTP status 404: Not Found.Metadata contains a reference that cannot be resolved: 'http://localhost/SecServiceSite/Service.svc'.There was no endpoint listening at http://localhost/SecServiceSite/Service.svc that could accept the message. This is often caused by an incorrect address or SOAP action. See InnerException, if present, for more details.The remote server returned an error: (404) Not Found.(0x80131509)file:///D:/Ram/rajesh/New Folder (2)/Intranet/myAsmara/App_WebReferences/SecurityWCFService/Reference.svcmapD:\...\myAsmara\</p>, 13 Oct 2014 01:10:18 GMTProgrammatically change WCF Services EndPoint Address in ASP.Net<p>I currently have a wcf web service that is referenced by my hosted application and have configured the web.config file with the end-point. I need to be able to dynamically chand the eddredd for the endpoint upon login. Can someone help me with this?</p>, 21 Apr 2017 01:55:25 GMTPass parameters to Web API in ASP.Net<p>How to sending Parameter or Request to Web API When It is Hosted onLine?</p>, 09 Sep 2014 03:21:55 GMTWarning: This web reference does not conform to WS-I Basic Profile v1.1. SOAP 1.1 binding was not found:<p>Hi,</p> <p>&nbsp;</p> <p>I want to create a Proxy class file from WSDL which is having Soap12 bindings style. I tried to create that using Wsdl.exe from command prompt. But i received the following error</p> <p>&nbsp;</p> <p><strong>Warning: This web reference does not conform to WS-I Basic Profile v1.1.</strong><br /><strong>SOAP 1.1 binding was not found: WS-I's Basic Profile 1.1 consists of implementat</strong><br /><strong>ion guidelines that recommend how a set of core Web services specifications shou</strong><br /><strong>ld be used together to develop interoperable Web services. For the 1.1 Profile,</strong><br /><strong>those specifications are SOAP 1.1, WSDL 1.1, UDDI 2.0, XML 1.0 and XML Schema.</strong></p> <p><strong>For more details on the WS-I Basic Profile v1.1, see the specification</strong><br /><strong>at</strong></p> <p><strong>Warning: one or more bindings were skipped.</strong><br /><strong>Warnings were encountered. Review generated source comments for more details.</strong></p> <p><strong><br /></strong></p> <p><strong>so i couldn't create the class file. Please help</strong></p> <p>&nbsp;</p>, 26 Feb 2014 09:24:36 GMTUse HttpContext.Current in WCF Service<p>I have created an WCF service for client in However the Response is not getting from POst method. Below is the code snippet:</p> <p>&nbsp;</p> <p>&nbsp;</p> <pre class="brush: csharp">public void Post() { System.Web.HttpContext.Current.Response.Clear(); System.Web.HttpContext.Current.Response.Write(&#34;&lt;html&gt;&lt;head&gt;&#34;); System.Web.HttpContext.Current.Response.Write(string.Format(&#34;&lt;/head&gt;&lt;body onload=\&#34;document.{0}.submit()\&#34;&gt;&#34;, FormName)); System.Web.HttpContext.Current.Response.Write(string.Format(&#34;&lt;form name=\&#34;{0}\&#34; method=\&#34;{1}\&#34; action=\&#34;{2}\&#34; &gt;&#34;, FormName, Method, Url)); for (int i = 0; i &lt; Inputs.Keys.Count; i++) { System.Web.HttpContext.Current.Response.Write(string.Format(&#34;&lt;input name=\&#34;{0}\&#34; type=\&#34;hidden\&#34; value=\&#34;{1}\&#34;&gt;&#34;, Inputs.Keys[i], Inputs[Inputs.Keys[i]])); } System.Web.HttpContext.Current.Response.Write(&#34;&lt;/form&gt;&#34;); System.Web.HttpContext.Current.Response.Write(&#34;&lt;/body&gt;&lt;/html&gt;&#34;); System.Web.HttpContext.Current.Response.End(); } </pre> <p>&nbsp;</p>, 22 Jun 2015 07:23:35 GMTService Oriented Architecture with WCF<p>I want to secure my WCF services from unauthorized access. I am using ASP MVC as a front end to access my WCF services. Can I encrypt my services URL in JS file? And how I maintain the state management. I am calling my services directly through AJAX call and I am avoiding Model and Controller (using only for redirections from menu). What is the best approach to create SOA?<img src="file:///C:/Users/khabib/Desktop/arch.png" alt="Arch" /></p>, 28 Mar 2016 02:11:31 GMTSend email using web application like Contact Us page in ASP.Net<p>how can the user send their requirement via email using my web application in must send mail to the mail account which associated with a Gmail account in my site......</p> <p>Dear i have a site ...on my site, there is three textbox&nbsp;</p> <p>1."From" in this box user need to write his mail id.</p> <p>2."Subject" what he/she is going to send me&nbsp;</p> <p>3. "Message Box"</p> <p>4.And a button called "Send"</p> <p>user type their mail id , subject and message and then user click on the button and the mail will come to my email is which is attached&nbsp;to my site</p> <p>&nbsp;</p>, 20 Jul 2016 03:52:15 GMTUpload image using WCF Rest WebService in ASP.Net<p>How to upload and save images as (BLOB) in databse in using WCF</p> <p>&nbsp;</p> <p>am getting images as bytes in my datatable..but returns error 400 if multiple images selected</p> <pre class="brush: csharp"> DocumentID = int.Parse(Request.QueryString[&#34;DocID&#34;]); byte[] fileData = new byte[file.InputStream.Length]; //Stream streamdata = new MemoryStream(fileData); file.InputStream.Read(fileData, 0, Convert.ToInt32(file.InputStream.Length)); file = getfile.UploadedFiles[filecnt]; if (dtImage == null || dtImage.Rows.Count == 0) { dtImage = new DataTable(); dtImage.Columns.Add(&#34;REQID&#34;); dtImage.Columns.Add(&#34;DocType&#34;); dtImage.Columns.Add(&#34;FileType&#34;); dtImage.Columns.Add(&#34;uploadId&#34;); //dtImage.Columns.Add(&#34;DATA&#34;, typeof(Byte[])); //dtImage.Columns.Add(&#34;DATAstream&#34;, typeof(Stream)); for (int i = 0; i &lt;= 0; i++) { DataRow dtrowtar = dtImage.NewRow(); dtrowtar[0] = DocumentID; dtrowtar[1] = ddlType.SelectedValue.ToString(); dtrowtar[2] = file.GetExtension().ToString(); dtrowtar[3] = 1; dtrowtar[4] = fileData; //dtrowtar[5] = streamdata; dtImage.Rows.Add(dtrowtar); } } else { int DocIndex = dtImage.Rows.Count; dtImage.Rows.Add(); dtImage.Rows[DocIndex][&#34;REQID&#34;] = dtImage.Rows[0][&#34;REQID&#34;]; dtImage.Rows[DocIndex][&#34;DocType&#34;] = ddlType.SelectedValue.ToString(); dtImage.Rows[DocIndex][&#34;FileType&#34;] = file.GetExtension().ToString(); dtImage.Rows[DocIndex][&#34;uploadId&#34;] = int.Parse(dtImage.Rows[DocIndex - 1][&#34;uploadId&#34;].ToString()) + 1; dtImage.Rows[DocIndex][&#34;Data&#34;] = fileData; //dtImage.Rows[DocIndex][&#34;DATAstream&#34;] = streamdata; } } </pre> <p>&nbsp;</p>, 03 Dec 2013 00:36:17 GMTUpload Image file using Web Service in ASP.Net<p>Hello,</p> <p>I want web service which will upload images (.jpeg, .jpg, .png) on server and this web service will call by android app, I am using web service <strong>not</strong> WCF.</p>, 01 Sep 2015 04:36:17 GMTUpload file using Web Service in ASP.Net<p>Hello,</p> <p>I have one web method and I want to upload file on server using this method please guide me how to implement it.</p>, 24 Aug 2015 04:46:21 GMTMy ASP.NET Web application did not make use of the HTTP Strict Transport Security (HSTS) mechanism<p><strong>Hi</strong></p> <p><strong>My ASP.NET Web application did not make use of the HTTP Strict Transport Security (HSTS) mechanism. </strong></p> <p><strong>This could potentially expose users to Man in the Middle (MitM) attacks. </strong></p> <p><em>When a web application uses HSTS, it specifies that users must connect using HTTPS and that communication should cease if there are any errors in the certificate chain. </em></p> <p><em>In this way, users are prevented from clicking through certificate errors or accessing the application over a compromised channel.</em></p> <p><strong>How to implement HSTS</strong></p> <p><strong>How Can I Prevent exposing users to Man in the Middle (MitM) attacks?</strong></p>, 04 Jul 2017 03:50:30 GMTInsert data to Database using Restful Web Service in ASP.Net<p>hi,</p> <p>&nbsp;</p> <p>I am making restful api through which i want to insert data in sql db i have this code but its not working please advice what i am doing wrong</p> <pre class="brush: csharp"> [WebInvoke(Method=&#34;Post&#34;, RequestFormat=WebMessageFormat.Json, UriTemplate= &#34;AddCountry/{countryname}&#34;, ResponseFormat= WebMessageFormat.Json,BodyStyle =WebMessageBodyStyle .Wrapped)] public void addcountry(string countryname) { string constring = ConfigurationManager.ConnectionStrings[&#34;DefaultConnection&#34;].ConnectionString; using (SqlConnection con = new SqlConnection(constring)) { using (SqlCommand cmd = new SqlCommand(&#34;INSERT INTO Country (CountryName) VALUES (@CountryName)&#34;, con)) { cmd.CommandType = CommandType.Text; cmd.Parameters.AddWithValue(&#34;@CountryName&#34;, countryname); con.Open(); int rowsAffected = cmd.ExecuteNonQuery(); con.Close(); } } }</pre> <p>&nbsp;</p>, 15 Jun 2017 07:36:40 GMTInsert data into Database using WCF Service in ASP.Net<p>please guide me</p> <p>How to insert data in DB by Web Service/WCF service</p> <p>&nbsp;</p> <p>Thanks</p>, 28 May 2015 02:11:34 GMTImplement N tier architecture using web service in ASP.Net<p>Please share me demo site using N Tier with Webservice.</p> <p>Thanks</p>, 20 Dec 2013 10:25:56 GMTHow to use SignalR chat in ASP.Net Web Forms Example<p>2 questions</p> <p>i) I am trying to establish a web page with chat facility on web form, since most of the other pages of that site have already been done on Web form and not in MVC.&nbsp;While searching some Jquery based chat examples for web form, none were available and even very few ones available are not working. So, I guess the SignalR feature is only doable from MVC and not from Web forms. Is it so?</p> <p>If not, provide me with some good examples which works well...</p> <p>ii) &nbsp;The hardest part is the Global.asax.cs page....Global.asax is available on Web forms and not Global.asax.cs.</p> <p>&nbsp;</p> <p>How to accomplish this?</p> <p>&nbsp;</p>, 26 Nov 2014 02:52:20 GMTHow to use session variable in WebMethod in VB.Net<p>hi,</p> <p>how can i access session&nbsp;variable inside of web method</p> <p>&nbsp;</p>, 26 Aug 2016 02:26:44 GMTHTTP Error 404.0 - Not Found when accesing WCF SVC service<p>I wanna host a wcf service that only GET data</p> <p>It works fine on my Localhost but when i host on url it gives error</p> <p>&nbsp;</p> <pre class="brush: html">Detailed Error Information: Module IIS Web Core Notification MapRequestHandler Handler StaticFile Error Code 0x80070002 Requested URL Physical Path G:\PleskVhosts\\httpdocs\Service1.svc\singleword\hi Logon Method Anonymous Logon User Anonymous</pre> <p>I dont know whats the issue</p> <p>&nbsp;My config</p> <pre class="brush: xml">&lt;?xml version=&#34;1.0&#34;?&gt; &lt;configuration&gt; &lt;appSettings&gt;&lt;/appSettings&gt; &lt;connectionStrings&gt; &lt;!--&lt;add name=&#34;NewTestConnectionString&#34; connectionString=&#34;Data Source=RHC-PC;Initial Catalog=NewTest;Integrated Security=True&#34; providerName=&#34;System.Data.SqlClient&#34; /&gt;--&gt; &lt;/connectionStrings&gt; &lt;system.web&gt; &lt;customErrors mode=&#34;Off&#34;&gt; &lt;/customErrors&gt; &lt;/system.web&gt; &lt;system.webServer&gt; &lt;httpErrors errorMode=&#34;Detailed&#34;&gt;&lt;/httpErrors&gt; &lt;validation validateIntegratedModeConfiguration=&#34;false&#34;/&gt; &lt;/system.webServer&gt; &lt;system.serviceModel&gt; &lt;serviceHostingEnvironment multipleSiteBindingsEnabled=&#34;true&#34;&gt; &lt;baseAddressPrefixFilters&gt; &lt;add prefix=&#34;htttp://;/&gt; &lt;/baseAddressPrefixFilters&gt; &lt;/serviceHostingEnvironment&gt; &lt;services&gt; &lt;service name=&#34;StressApi.Service1&#34; behaviorConfiguration=&#34;StressApi.Service1Behavior&#34;&gt; &lt;endpoint address=&#34;../Service1.svc&#34; binding=&#34;webHttpBinding&#34; contract=&#34;StressApi.IService1&#34; behaviorConfiguration=&#34;webBehaviour&#34;&gt; &lt;/endpoint&gt; &lt;/service&gt; &lt;/services&gt; &lt;behaviors&gt; &lt;serviceBehaviors&gt; &lt;behavior name=&#34;StressApi.Service1Behavior&#34;&gt; &lt;serviceDebug includeExceptionDetailInFaults=&#34;false&#34;/&gt; &lt;/behavior&gt; &lt;/serviceBehaviors&gt; &lt;endpointBehaviors&gt; &lt;behavior name=&#34;webBehaviour&#34;&gt; &lt;webHttp/&gt; &lt;/behavior&gt; &lt;/endpointBehaviors&gt; &lt;/behaviors&gt; &lt;/system.serviceModel&gt; &lt;/configuration&gt; </pre> <p>&nbsp;</p>, 15 Apr 2015 01:01:41 GMTHow to work with 100 fields on a web form in ASP.NET<p>i am having a requirement where i have to create a form having nearly 100 fields. i have divided the form into three modules using multiview/tabs.can i have 100 columns in sql server table or should i use three tables by setting relationship using primary and foreign keys.</p> <p>What i have Tried &nbsp;!!</p> <p><br />i have tried using multiview where i have divided the form into three views and and make first view submission table as primary and remaining two views with fields as foreign keys. also tried by executing multiple query(transactions) at a time,but could not find the best solution.which one is effiecient and best!!!.</p> <p>&nbsp;</p> <p>&nbsp;</p>, 24 Jul 2017 03:28:34 GMTHow to use WCF Service to upload multiple files in ASP.Net<p>I want to upload multiple files(it may contain images too) to my server using WCF Service in how can I do?</p>, 17 Jul 2014 01:34:30 GMTHow to use Session in Web Service web method in ASP.Net<p>sir i am following one of your links:</p> <p><a href=""></a></p> <p>&nbsp;</p> <p>But this concept is not working in master page, i have kept the script in the master page and calling the function in the content page link button OnClientClick. Function gets called, but its not calling the webservice method, i have just replaced one line:</p> <p>Kindly suggest, bit urgent.</p> <p>url: "CS.aspx/SetSession",<br /><br />with<br /><br />url: 'WebService.asmx/SetSession',</p>, 07 Sep 2014 23:21:58 GMTHow to set page as default page in web application c# and open that page while using URL Routing<p>I am creating new web application c# project. Now in there i am using url routing. The basic url would be while developement is <strong>localhost/VAEBS</strong> . Now i want that whenever <strong></strong> or <strong>localhost/VAEBS</strong> is opened in browser it must open my login page, like this <strong>localhost/VAEBS/LoginScreen</strong> . Yet it is openeing login screen on typing <strong>localhost/VAEBS</strong> , but it is not showing LoginScreen text in url , which needs to be like this <strong>localhost/VAEBS/LoginScreen</strong></p>, 24 May 2016 09:16:15 GMTHow to secure and hide WCF (Rest) service Parameters when passing through URL in ASP.Net<p>how to provide security in wcf rest because we will send the values in url here user can able to see and modify. we need to provide security for this how to do in wcf rest give me any article related to this?</p>, 03 Jul 2014 06:34:56 GMTHow To refresh web page automatically like (Cricinfo Website)<p>Hello EveryOne</p> <p>I have a question i want to refresh my web page automatically like cricinfo website. I know he timer logic but the requirement of the client restrict me to avoid the timer logic. Anyone know any solution or any third party tool.&nbsp;</p> <p>Thanks in advance</p>, 11 Apr 2016 07:29:01 GMTHow to read and parse SOAP XML from a Web Service in ASP.Net<p>How to read soap xml in</p> <p>&nbsp;</p> <pre class="brush: xml">&lt;espec:LoginEnvelope xmlns:espec=&#34;; enabled=&#34;false&#34;&gt; &lt;soap:Envelope xmlns:soap=&#34;;&gt; &lt;soap:Header/&gt; &lt;soap:Body&gt; &lt;m:AuthenticateUser xmlns:m=&#34;http://localhost/AdobeIntegration/ImportData.svc/Authenticate&#34;&gt; &lt;m:username&gt;uname&lt;/m:username&gt; &lt;m:password&gt;pwd&lt;/m:password&gt; &lt;m:domain&gt;dm&lt;/m:domain&gt; &lt;/m:AuthenticateUser&gt; &lt;/soap:Body&gt; &lt;/soap:Envelope&gt; &lt;/espec:LoginEnvelope&gt;</pre> <p>&nbsp;</p>, 23 Jan 2014 05:15:40 GMTHow to Publish a Silverlight Application with WCF Service<p>I have my application in Silverlight. Can anyone please give me a walk through of how to publish it. I have published my application.</p> <p>The Issue is when i run the .Html then it starts but doesnt work.ONly design is displayed and no functionality work.No Insert,Update,Delete takes place.Not even data is displayed in combo at Load.</p>, 02 Aug 2015 23:42:53 GMT