Click here to Skip to main content
12,623,027 members (37,185 online)
   

ASP.NET

 
GeneralRe: MVC - How are you scripting..? Pin
john-ph26-Sep-12 18:57
memberjohn-ph26-Sep-12 18:57 
QuestionHow to copy the content of textbox to the clipboard Pin
vinay_28923-Sep-12 22:25
membervinay_28923-Sep-12 22:25 
QuestionCreating Textboxes Dynamically Pin
ASPnoob23-Sep-12 3:53
memberASPnoob23-Sep-12 3:53 
AnswerRe: Creating Textboxes Dynamically Pin
Vani Kulkarni23-Sep-12 19:32
memberVani Kulkarni23-Sep-12 19:32 
AnswerRe: Creating Textboxes Dynamically Pin
vinay_28923-Sep-12 21:59
membervinay_28923-Sep-12 21:59 
AnswerRe: Creating Textboxes Dynamically Pin
ema2000_t24-Sep-12 12:55
memberema2000_t24-Sep-12 12:55 
AnswerRe: Creating Textboxes Dynamically Pin
n.podbielski28-Sep-12 2:12
membern.podbielski28-Sep-12 2:12 
AnswerRe: Creating Textboxes Dynamically Pin
RichardGrimmer28-Sep-12 5:11
memberRichardGrimmer28-Sep-12 5:11 
Questionasp.net web form or asp.net mvc ?? Pin
Mohamad Shahmardan22-Sep-12 14:04
memberMohamad Shahmardan22-Sep-12 14:04 
AnswerRe: asp.net web form or asp.net mvc ?? Pin
Vani Kulkarni23-Sep-12 19:30
memberVani Kulkarni23-Sep-12 19:30 
AnswerRe: asp.net web form or asp.net mvc ?? Pin
Harris John23-Sep-12 19:43
memberHarris John23-Sep-12 19:43 
GeneralRe: asp.net web form or asp.net mvc ?? Pin
Mohamad Shahmardan24-Sep-12 4:06
memberMohamad Shahmardan24-Sep-12 4:06 
GeneralRe: asp.net web form or asp.net mvc ?? Pin
n.podbielski28-Sep-12 2:13
membern.podbielski28-Sep-12 2:13 
Questionjquery ui autocomplete Pin
Member 901582221-Sep-12 19:19
memberMember 901582221-Sep-12 19:19 
Help me
I am using jquery ui autocomplete but it's not working

i write this code

web page
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
<title>Untitled Page</title>
<link href="./Script/jquery-ui-1.8.1.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="./Script/jquery-1.4.2.min.js"></script>
<script type="text/javascript" src="./Script/jquery-ui-1.8.1.min.js"></script>
<script type="text/javascript">
$(document).ready(function(){
$("tbAuto").autocomplete({
source: function(request, response){
$.ajax({
type: "POST",
contentType: "application/json; charset=utf-8",
url: "WebService.asmx/getDepartementName",
data: "{'Name':'" + request.term +"'}",
dataType: "json",
async: true,
success: function(data){
response(data.d);
},
error: function(result){
alert(result);
}
});
},
minLength: 1
});
});
</script>
</head>
<body>
<form id="form1" runat="server">
<div class="demo">
<div class="ui-widget">
<label for="tbAuto">department name :<asp:TextBox ID="tbAuto" runat="server"></asp:TextBox> </label>
</div>
</div>
</form>
</body>
</html>

web service -

Imports System.Web
Imports System.Web.Services
Imports System.Web.Services.Protocols
Imports System.Data
Imports System.Data.OleDb
Imports System.Web.Script.Services
Imports System.Collections.Generic

<ScriptService()> _
<WebService(Namespace:="http://tempuri.org/")> _
<WebServiceBinding(ConformsTo:=WsiProfiles.BasicProfile1_1)> _
<Global.Microsoft.VisualBasic.CompilerServices.DesignerGenerated()> _
Public Class WebService
Inherits System.Web.Services.WebService
Dim con As New dbConnection
Dim da As OleDbDataAdapter
Dim tempDT As New DataTable
Dim SQL As String
Dim rows, i As Integer
Dim DepNames As New List(Of String)

<WebMethod()> _
Public Function getDepartementName(ByVal prefixText As String) As String()
Try
con.connect()
SQL = "select DEPARTMENT_NAME from TBLDEPARTMENT_1 where upper(DEPARTMENT_NAME) like upper('%" & prefixText & "%')"
da = New OleDbDataAdapter(SQL, con.con)
da.Fill(tempDT)
rows = tempDT.Rows.Count
If rows > 0 Then
For i = 0 To rows - 1
DepNames.Add(tempDT.Rows(i)(0))
Next
End If
Return DepNames.ToArray()
Catch ex As Exception
Throw ex
End Try
End Function

this webservice is works with ajax autocomplete extender but not with jquery
this not gives any error and not call webservice method.

thanks
AnswerRe: jquery ui autocomplete Pin
Sandeep Mewara21-Sep-12 20:34
mvpSandeep Mewara21-Sep-12 20:34 
AnswerRe: jquery ui autocomplete Pin
jkirkerx22-Sep-12 15:03
memberjkirkerx22-Sep-12 15:03 
AnswerRe: jquery ui autocomplete Pin
n.podbielski28-Sep-12 2:17
membern.podbielski28-Sep-12 2:17 
QuestionHow to put line numbers in Textbox with multiline Pin
vinay_28921-Sep-12 3:28
membervinay_28921-Sep-12 3:28 
AnswerRe: How to put line numbers in Textbox with multiline Pin
Shameel21-Sep-12 4:08
memberShameel21-Sep-12 4:08 
AnswerRe: How to put line numbers in Textbox with multiline Pin
Sandeep Mewara21-Sep-12 7:28
mvpSandeep Mewara21-Sep-12 7:28 
GeneralRe: How to put line numbers in Textbox with multiline Pin
vinay_28923-Sep-12 22:01
membervinay_28923-Sep-12 22:01 
QuestionWCF / Single instance / multple concurrency question Pin
Luca Dominici20-Sep-12 6:58
memberLuca Dominici20-Sep-12 6:58 
AnswerRe: WCF / Single instance / multple concurrency question Pin
Expert Coming20-Sep-12 14:57
memberExpert Coming20-Sep-12 14:57 
GeneralRe: WCF / Single instance / multple concurrency question Pin
Luca Dominici20-Sep-12 22:36
memberLuca Dominici20-Sep-12 22:36 
GeneralRe: WCF / Single instance / multple concurrency question Pin
Expert Coming24-Sep-12 9:21
memberExpert Coming24-Sep-12 9:21 
GeneralRe: WCF / Single instance / multple concurrency question Pin
Luca Dominici24-Sep-12 22:10
memberLuca Dominici24-Sep-12 22:10 
QuestionAjax Tab Events And Gridview help Pin
HimalR820-Sep-12 2:57
memberHimalR820-Sep-12 2:57 
AnswerRe: Ajax Tab Events And Gridview help Pin
jkirkerx21-Sep-12 11:52
memberjkirkerx21-Sep-12 11:52 
GeneralRe: Ajax Tab Events And Gridview help Pin
HimalR825-Sep-12 12:42
memberHimalR825-Sep-12 12:42 
GeneralRe: Ajax Tab Events And Gridview help Pin
jkirkerx25-Sep-12 13:53
memberjkirkerx25-Sep-12 13:53 
QuestionMVC v MVVM Pin
eddieangel19-Sep-12 13:22
membereddieangel19-Sep-12 13:22 
AnswerRe: MVC v MVVM Pin
john-ph25-Sep-12 21:09
memberjohn-ph25-Sep-12 21:09 
QuestionUsing Jquery in DataList Pin
mrkeivan19-Sep-12 10:04
membermrkeivan19-Sep-12 10:04 
AnswerRe: Using Jquery in DataList Pin
@AmitGajjar19-Sep-12 21:55
member@AmitGajjar19-Sep-12 21:55 
QuestionFiltering in header Pin
byka19-Sep-12 2:40
memberbyka19-Sep-12 2:40 
AnswerRe: Filtering in header Pin
Sandeep Mewara19-Sep-12 10:30
mvpSandeep Mewara19-Sep-12 10:30 
Questionlearning asp.net c# linq Pin
Ha_Hoa_A1018-Sep-12 22:49
memberHa_Hoa_A1018-Sep-12 22:49 
AnswerRe: learning asp.net c# linq Pin
Sandeep Mewara18-Sep-12 23:19
mvpSandeep Mewara18-Sep-12 23:19 
GeneralRe: learning asp.net c# linq Pin
Richard MacCutchan19-Sep-12 0:20
mvpRichard MacCutchan19-Sep-12 0:20 
GeneralRe: learning asp.net c# linq Pin
Sandeep Mewara19-Sep-12 2:32
mvpSandeep Mewara19-Sep-12 2:32 
QuestionHow to Create and Access Session Variables Pin
ASPnoob18-Sep-12 21:22
memberASPnoob18-Sep-12 21:22 
AnswerRe: How to Create and Access Session Variables Pin
Sandeep Mewara18-Sep-12 23:25
mvpSandeep Mewara18-Sep-12 23:25 
AnswerRe: How to Create and Access Session Variables Pin
jkirkerx19-Sep-12 11:04
memberjkirkerx19-Sep-12 11:04 
GeneralRe: How to Create and Access Session Variables Pin
gopal pradhan9-Nov-12 0:25
membergopal pradhan9-Nov-12 0:25 
AnswerRe: How to Create and Access Session Variables Pin
niranjan47923-Sep-12 22:15
memberniranjan47923-Sep-12 22:15 
QuestionTurning a VS2010 project into a control Pin
Syntax 40418-Sep-12 14:35
memberSyntax 40418-Sep-12 14:35 
AnswerRe: Turning a VS2010 project into a control Pin
Sandeep Mewara18-Sep-12 23:55
mvpSandeep Mewara18-Sep-12 23:55 
QuestionDynamic Control Help. Pin
sam_asp.net18-Sep-12 11:13
membersam_asp.net18-Sep-12 11:13 
AnswerRe: Dynamic Control Help. Pin
Sandeep Mewara18-Sep-12 23:33
mvpSandeep Mewara18-Sep-12 23:33 
QuestionDisplaying multiple overlapping images Pin
avsesis18-Sep-12 4:09
memberavsesis18-Sep-12 4:09 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.


Advertise | Privacy | Mobile
Web02 | 2.8.161128.1 | Last Updated 3 Dec 2016
Copyright © CodeProject, 1999-2016
All Rights Reserved. Terms of Service
Layout: fixed | fluid