Jump to content

Search the Community

Showing results for tags 'web services'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • W3Schools
    • General
    • Suggestions
    • Critiques
  • HTML Forums
    • HTML/XHTML
    • CSS
  • Browser Scripting
    • JavaScript
    • VBScript
  • Server Scripting
    • Web Servers
    • Version Control
    • SQL
    • ASP
    • PHP
    • .NET
    • ColdFusion
    • Java/JSP/J2EE
    • CGI
  • XML Forums
    • XML
    • XSLT/XSL-FO
    • Schema
    • Web Services
  • Multimedia
    • Multimedia
    • FLASH

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


AIM


MSN


Website URL


ICQ


Yahoo


Jabber


Skype


Location


Interests


Languages

Found 3 results

  1. Dear friends, Basic need -------------- I need to call asmx webservice from javascript function. onbuttonclick, i am actually calling that javascript function. line with high size font is the problem area. please help guys working from past 5 days on this part WebService Registration with aspx page--------------------------------------------------- <form id="form1" runat="server"> <asp:ToolkitScriptManager ID="ToolkitScriptManager1" runat="server" EnablePageMethods="true"> <Services> <asp:ServiceReference Path="~/dataPreExist.asmx"/> </Services> </asp:ToolkitScriptManager> WEBSERVICE ------------------ <ToolboxItem(False)> _ Public Class dataPreExist Inherits System.Web.Services.WebService <WebMethod()> _ Public Function EnqPreExistOrNot(ByVal paraCcn As String, ByVal paraPcode As String) As Boolean Dim strsql6 As New StringBuilder Dim localdt6 As New DataTable ' ccn = "DJ079" ' party = "04BSPT0066" With strsql6 .Append("select * from complaintmastercrm where ccncd='" & paraCcn & "' and partycd='" & paraPcode & "'") End With localdt6 = CommonDb.ReturnDataTable(strsql6.ToString, "CRM") If localdt6.Rows.Count > 0 Then EnqPreExistOrNot = True MsgBox("pre Enquiry Exist") MsgBox("Pre Enquiry not exist") Else EnqPreExistOrNot = False End If End Function End Class End Namespace Javascript Function ------------------------- function webServiceCall() { var paraCcn; //var paraPartyCd; var paraPcode; //alert('hello last') paraCcn = document.getElementById("<%=lblCcn.clientID%>").innerHTML; paraPcode = document.getElementById("<%=hdnParty.clientID%>").value; paraPcode = paraPcode.replace(/,s*$/, ""); var a = new namespace1.dataPreExist(); //not working block a.EnqPreExistOrNot(paraCcn, paraPcode, OnSucessorFail); //not working block } function OnSucessorFail() { debugger; var proceed; proceed = confirm("Enquiry already Generated for this Machine and Cost Center"); if (proceed == true) { return true; } else { return false; } }
  2. <%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default3.aspx.cs" Inherits="Default3" %> <!DOCTYPE html> <html xmlns="http://www.w3.org/1999/xhtml"> <head id="Head1" runat="server"> <title></title> <script src="https://code.oovoo.com/webrtc/oovoosdk-0.0.7.min.js"></script> <script type="text/javascript"> function TestId() { WebService1.GetAppId(onSuccess, onFailure); } //situation 1 function onSuccess(result) { alert(result); } //situation 2 //function onSuccess(result) { // return result; //} function onFailure(result) { alert("Error Invoking the Web Service..."); } </script> </head> <body> <form id="form1" runat="server"> <asp:ScriptManager runat="server" ID="scriptManager"> <Services> <asp:ServiceReference Path="~/WebService1.asmx" /> </Services> </asp:ScriptManager> <div> <video id="localVideo" style="width: 300px; height: auto;" autoplay muted></video> </div> </form> <script type="text/javascript"> TestId(); // This line is working in situation 1 (onSuccess method situation 1) //BUT, WHEN I COMMENT METHOD IN SITUATON 1 AND UNCOMMENT SITUATION2 THEN LINE BELOW IS NOT WORKING var a = TestId(); //THIS LINE IS NOT WORKING WHEN SITUATION2 IS ACTIVE </script> </body> </html>
  3. Hello, very simple code block is below. Javascript functions that call web service methods are working when I called them between form tags. But they are not working at the beginning of the page. I specified lines that are not working below. Please help. <%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default2.aspx.cs" Inherits="Default2" %> <!DOCTYPE html> <html xmlns="http://www.w3.org/1999/xhtml"> <head runat="server"> <title></title> <script type="text/javascript"> function GetMyName() { WebService1.GetName(onNameSuccess, onNameFailure); } function onNameSuccess(result) { return result; } function onNameFailure(result) { alert("There is an error"); } function GetMySurname() { WebService1.GetSurname(onSurnameSuccess, onSurnameFailure); } function onSurnameSuccess(result) { return result; } function onSurnameFailure(result) { alert("There is an error"); } //JAVASCRIPT FUNCTIONS ARE NOT WORKING HERE //THESE TWO LINES ARE NOT WORKING var name = GetMyName(); var surname = GetMySurname(); </script> </head> <body> <form id="form1" runat="server"> <asp:ScriptManager ID="ScriptManager1" runat="server"> <Services> <asp:ServiceReference Path="WebService1.asmx" /> </Services> </asp:ScriptManager> //JAVASCRIPT FUNCTIONS ARE WORKING HERE </form> </body> </html>
×
×
  • Create New...