EDIT: Sorry forgot to mention what i was using.... I installed VS Web 2008 Express, so i am trying to use it in ASP.NET,... also, the instructions that i have seen say to use the ASP.NET Ajax, i am going to look at the video again., that does a step by step,.
and see if i did something wrong.
I finally got the AJAX controlbox to show,
After i add the extender and try to add the page method i get the exception
Exception has been thrown by the target of an invocation
how do i make sure that the control kit is correctly installed??? i have installed the 3.5 ext, and downloaded the kit., when i try to launch the AjaxControlToolkit.sln Web VS 2008 gives me a
"The projects componenets are not installed on this computer. Please re-install Visual Studio"
i download the latest AjaxControlToolkit-Framework3.5
in the readme it says
"Welcome to the ASP.NET AJAX Control Toolkit!
Included in this package:
* AjaxControlToolkit - A set of sample ASP.NET AJAX controls and source
* SampleWebsite - A web site that demonstrates how to use the controls and
contains the rest of the Toolkit documentation
* ToolkitTests - A web site that contains automated tests for all controls
* AjaxControlExtender - A VSI installer that will install templates onto your
machine to enable creation of new ASP.NET AJAX extender controls using
Visual Studio 2005
To get started, simply load the "AjaxControlToolkit.sln" solution in Visual
Studio 2005, and run the solution. This will launch the web site and allow
you to experiment with the different controls. Also included in the solution
is the source code for all the controls.
The web site also contains walkthroughs covering:
* Setting up your machine to use control extenders
* Using control extenders with your ASP.NET web site
* Creating new control extenders
* Writing your own automated tests
Version 3.0.11119.0
2007-11-19 release of the AJAX Control Toolkit targets the official release of .NET Framework 3.5 and Visual Studio 2008.
AjaxControlToolkit-Framework3.5.zip is the full release package with complete source code to all controls, the test framework, VSI, and more.
AjaxControlToolkit-Framework3.5-NoSource.zip contains only the sample web site and VSI and is for people who don't need or want the source code for the controls.
I have VS 2005 Pro, I Installed the Ajax Tooklit and the 2005 SDK.
The Sample project opens, loads and runs normally, but when I put an Autocomplete on my form and Right-Click - Add Form Methods. It trys to add code then pops.
I look in the Code behind and see a messed up function:
Public Function GetCompletionList() As System.String[]
End Function
Looks like a mix of VB and C#
What code is supposed to be added so I can continue?
<System.Web.Services.WebMethodAttribute(), System.Web.Script.Services.ScriptMethodAttribute()> _
Public Shared Function GetCompletionList(ByVal prefixText As String, ByVal count As Integer, ByVal contextKey As String) As String()
' you can create a custom string array and return it
Dim r As String() = {"aaa", "bbb", "ccc"}
Return r
End Function
[System.Web.Services.WebMethodAttribute(), System.Web.Script.Services.ScriptMethodAttribute()]
public static string[] GetCompletionList(string prefixText, int count, string contextKey)
{
// you can create a custom string array and return it
string[] r = {"aaa", "bbb", "ccc"};
return r;
}
perfect., since you are looking at ajax.net you might run into dynamiclly adding controls and order matters in that so you might want to look at
http://forums.asp.net/p/1142457/2191394.aspx#2191394 just incase
lets try baby steps., this code if from my proof of concept... it was specifically written to do something so i have had to strip some stuff out, you know how fancy dynamic code gets., i think i also have some commented out code in my app that i might have
used to start building my dynamic content., try the following..
Dim manager As ScriptManager =
New ScriptManager
form1.Controls.Add(manager)
Dim APanelControl
As Control
Dim aAccord As AccordionDim accordPane
As AccordionPane
'' ADD some DATA
aAccord =
New Accordion
Dim AccordianLoopHolder as integer = 1 ' in this case.. my code is dynamically creating by loops., so lets just make this ., 1
oh i do understand that you are not using accordians :) i wasnt sure how much you had explored on the ajax.net i believe i have an autocomplete piece that i did also., somewhere., the issue is that most of my prrof of concepts become
website1...... websiteN :)
so right now im gotomypc'd into my laptop which has the code.... ill be headed back home in a bit, when i am infront of it i could try to get you what you are looking for?
found it., this one doesnt use dynamic code to create the textbox+autocomplete but... it has a static textbox with autocomplete., this works, you shd be able to figure out dynamic build up with this., or when i get home i can help you by looking for my dynamic
code..
now to attach the file somewhere for you to download
k., here is the piece that does the autocomplete., it might solve your issue as it will overcome the vs bug., its simple, might be too simple for you., but like i said i dont mind helping you build this into what you want
The file webresource.axd does not exist, I don't know if that is a .Net thing though.
I looked at the source of the ASP.NET Sample and they have the same sys.Application, they dont have sys defined anywhere but IE has no errors for their sample.
I can't find what is different between the sample and mine.
You could try not using a web control just to see if it works? And then backtrack to getting it working in a control?But
I do not think its mainly because of that,
Ok, i tore out everything but the 5 files involved
I put the rar file on a free website:
http://dryrtf.freewebspace.com/
I downloaded The Ajax Control Toolkit Web Site and it completely works
I have a VS 2005 Pro website that I am trying to add the Autocomplete to.
I have added Ajax to the Tool bar in VS, I can drag n drop items onto a page and see the components.
That tiny sample shows the error (yellow exclaim in bottom left status bar area of ie)
but here is my Config:
<!--
Note: As an alternative to hand editing this file you can use the
web admin tool to configure settings for your application. Use
the Website->Asp.Net Configuration option in Visual Studio.
A full list of settings and comments can be found in
machine.config.comments usually located in
\Windows\Microsoft.Net\Framework\v2.x\Config
-->
<configuration>
<appSettings/>
<connectionStrings/>
<system.web>
<!--
Set compilation debug="true" to insert debugging
symbols into the compiled page. Because this
affects performance, set this value to true only
during development.
Visual Basic options:
Set strict="true" to disallow all data type conversions
where data loss can occur.
Set explicit="true" to force declaration of all variables.
-->
<compilation debug="true" strict="true" explicit="true">
<assemblies>
<add assembly="System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
<add assembly="System.Runtime.Serialization.Formatters.Soap, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
<add assembly="System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
<add assembly="System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
<add assembly="System.Design, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
<add assembly="System.Management, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
<add assembly="System.Drawing.Design, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
<add assembly="System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
<add assembly="System.Web.Extensions.Design, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
<add assembly="Microsoft.VisualStudio.Shell, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/></assemblies>
</compilation>
<pages>
<namespaces>
<clear/>
<add namespace="System"/>
<add namespace="System.Collections"/>
<add namespace="System.Collections.Specialized"/>
<add namespace="System.Configuration"/>
<add namespace="System.Text"/>
<add namespace="System.Text.RegularExpressions"/>
<add namespace="System.Web"/>
<add namespace="System.Web.Caching"/>
<add namespace="System.Web.SessionState"/>
<add namespace="System.Web.Security"/>
<add namespace="System.Web.Profile"/>
<add namespace="System.Web.UI"/>
<add namespace="System.Web.UI.WebControls"/>
<add namespace="System.Web.UI.WebControls.WebParts"/>
<add namespace="System.Web.UI.HtmlControls"/>
</namespaces>
</pages>
<!--
The <authentication> section enables configuration
of the security authentication mode used by
ASP.NET to identify an incoming user.
-->
<authentication mode="None"/>
<!--
The <customErrors> section enables configuration
of what to do if/when an unhandled error occurs
during the execution of a request. Specifically,
it enables developers to configure html error pages
to be displayed in place of a error stack trace.
<customErrors mode="RemoteOnly" defaultRedirect="GenericErrorPage.htm">
<error statusCode="403" redirect="NoAccess.htm" />
<error statusCode="404" redirect="FileNotFound.htm" />
</customErrors>
-->
<customErrors mode="Off"></customErrors>
</system.web>
</configuration>
put 1 more in there the version should be right., you could compare that line with the samples web.config line (that work)... to ensure the token/versioning...
<add
assembly="Microsoft.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"/>
also check in the web.config for the samples that work if there is a <httpHandlers> tag,,,, if there is try to place that in your web.config....
looked at your project., initially it didnt work., i need to run for dinner., but., what i did was i moved your function call for the list to the defaults code behind
Public Shared
Function GetCompletionList(ByVal prefixText
As String,
ByVal count As
Integer, ByVal contextKey
As String)
As String()
' you can create a custom string array and return it
Dim r
As String() = {"Prolax",
"Profin", "Prodex"}
Return r
End Function
and it worked., i think because u are registering the getcompletionlist in the usercontrol it wont/cant fire it up., its possible that to fire it up you might need to use
Member
3 Points
55 Posts
Add Autocomplete page method throws a Exception has been thrown by the target of an invocation
Feb 18, 2008 11:34 PM|zeeomar|LINK
EDIT: Sorry forgot to mention what i was using.... I installed VS Web 2008 Express, so i am trying to use it in ASP.NET,... also, the instructions that i have seen say to use the ASP.NET Ajax, i am going to look at the video again., that does a step by step,. and see if i did something wrong.
I finally got the AJAX controlbox to show,
After i add the extender and try to add the page method i get the exception
Exception has been thrown by the target of an invocationany ideas?
Member
186 Points
136 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
Feb 19, 2008 02:06 AM|sandynaidu|LINK
Check Wheather ur AJAX Control kit is Properly installed and configured...[Yes]
Member
186 Points
136 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
Feb 19, 2008 02:16 AM|sandynaidu|LINK
Just check out This one if u have an problem to configure AJAX Toolkit
http://weblogs.asp.net/nannettethacker/archive/2008/02/07/ajax-control-tookit-installation-in-visual-web-developer.aspx
Member
3 Points
55 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
Feb 19, 2008 02:18 AM|zeeomar|LINK
how do i make sure that the control kit is correctly installed??? i have installed the 3.5 ext, and downloaded the kit., when i try to launch the AjaxControlToolkit.sln Web VS 2008 gives me a
"The projects componenets are not installed on this computer. Please re-install Visual Studio"
i tried to watch http://www.asp.net/learn/ajax-videos/video-76.aspx
But his version is the full version of VS 2008 and it opens it with no problems!!
Member
3 Points
55 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
Feb 19, 2008 02:25 AM|zeeomar|LINK
adding in that dll, doesnt put anything in the list., i have checked the essential components i have
all the frameworks installed
ASP.NET Ajax 2.0 Ext 1.0
ASP.NET Ajax 2.0 Templates for VS 2008
ASP.NET 3.5 Ext CTP
Member
3 Points
55 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
Feb 19, 2008 02:34 AM|zeeomar|LINK
another thing that doesnt make sense...
i download the latest AjaxControlToolkit-Framework3.5
in the readme it says
"Welcome to the ASP.NET AJAX Control Toolkit!
Included in this package:
* AjaxControlToolkit - A set of sample ASP.NET AJAX controls and source
* SampleWebsite - A web site that demonstrates how to use the controls and
contains the rest of the Toolkit documentation
* ToolkitTests - A web site that contains automated tests for all controls
* AjaxControlExtender - A VSI installer that will install templates onto your
machine to enable creation of new ASP.NET AJAX extender controls using
Visual Studio 2005
To get started, simply load the "AjaxControlToolkit.sln" solution in Visual
Studio 2005, and run the solution. This will launch the web site and allow
you to experiment with the different controls. Also included in the solution
is the source code for all the controls.
The web site also contains walkthroughs covering:
* Setting up your machine to use control extenders
* Using control extenders with your ASP.NET web site
* Creating new control extenders
* Writing your own automated tests
Please open the sample web site or http://ajax.asp.net/ajaxtoolkit/ for more
details!"
Why is it talking about VS 2005 when., the download info at http://www.codeplex.com/AtlasControlToolkit/Release/ProjectReleases.aspx?ReleaseId=8513 says
Version 3.0.11119.0
2007-11-19 release of the AJAX Control Toolkit targets the official release of .NET Framework 3.5 and Visual Studio 2008.
Member
3 Points
55 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
Feb 19, 2008 01:09 PM|zeeomar|LINK
Okay, i am back to square one... :)
I have the control kit showing in my toolbox.
I drop a txt box., add the autocomplete extender., click on Add methods for that extender., it gives me the invocation error
:)
Member
3 Points
55 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
Feb 22, 2008 09:17 PM|zeeomar|LINK
Okay, i have done a screen capture so that you guys can see what i am talking about,
Click here to View/Download AVI
None
0 Points
12 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
May 29, 2008 12:46 PM|Dry|LINK
This is happening to me as well.
I have VS 2005 Pro, I Installed the Ajax Tooklit and the 2005 SDK.
The Sample project opens, loads and runs normally, but when I put an Autocomplete on my form and Right-Click - Add Form Methods. It trys to add code then pops.
I look in the Code behind and see a messed up function:
Public Function GetCompletionList() As System.String[]
End Function
Looks like a mix of VB and C#
What code is supposed to be added so I can continue?
Thanks
None
0 Points
12 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
May 29, 2008 01:07 PM|Dry|LINK
Ok found it on another post:
<System.Web.Services.WebMethodAttribute(), System.Web.Script.Services.ScriptMethodAttribute()> _
Public Shared Function GetCompletionList(ByVal prefixText As String, ByVal count As Integer, ByVal contextKey As String) As String()
' you can create a custom string array and return it
Dim r As String() = {"aaa", "bbb", "ccc"}
Return r
End Function
[System.Web.Services.WebMethodAttribute(), System.Web.Script.Services.ScriptMethodAttribute()]
public static string[] GetCompletionList(string prefixText, int count, string contextKey)
{
// you can create a custom string array and return it
string[] r = {"aaa", "bbb", "ccc"};
return r;
}
Member
3 Points
55 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
May 29, 2008 01:09 PM|zeeomar|LINK
actually, i think i got it working., search for all my posts, the answer is out there., let me try to find it for you.
Member
3 Points
55 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
May 29, 2008 01:13 PM|zeeomar|LINK
perfect., since you are looking at ajax.net you might run into dynamiclly adding controls and order matters in that so you might want to look at http://forums.asp.net/p/1142457/2191394.aspx#2191394 just incase
None
0 Points
12 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
May 29, 2008 02:13 PM|Dry|LINK
The rabbit hole you just sent me down has made me remove all html of the autocomplete and try to add code on page load to do it all.
(I prefer code to html)
So in my page load:
It still doesn't work, but there is a Javascript error on the page:
Error: 'Sys' is undefined.
I viewed Source and see:
The first part is my treeview, the Sys is the Ajax generation.
my hole seems to have cave'd in
Any Ideas?
Member
3 Points
55 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
May 29, 2008 02:36 PM|zeeomar|LINK
lets try baby steps., this code if from my proof of concept... it was specifically written to do something so i have had to strip some stuff out, you know how fancy dynamic code gets., i think i also have some commented out code in my app that i might have used to start building my dynamic content., try the following..
form1.Controls.Add(manager)
Dim APanelControl As Control'' ADD some DATA
aAccord =
New Accordion Dim AccordianLoopHolder as integer = 1 ' in this case.. my code is dynamically creating by loops., so lets just make this ., 1aAccord.ID =
"Accordion_" & AccordianLoopHolderaAccord.Width = "184"
aAccord.EnableTheming =
TrueaAccord.AutoSize = AutoSize.None
aAccord.TransitionDuration = 20
aAccord.FramesPerSecond = 250
aAccord.SelectedIndex = 0
accordPane.ID =
"Accordion_" & AccordianLoopHolder & "_PaNeX" accordPane.HeaderContainer.Controls.Add(BuildeAccHeader_ReturnHeader)accordPane.ContentContainer.Controls.Add(BuildContentForContainerTable)aAccord.Panes.Add(accordPane)
'Panel1.Controls.Add(aAccord) ' Add Accordian to Panel cant remember if you need this. :) think you do.?
'' DONE ADDING data
None
0 Points
12 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
May 29, 2008 02:48 PM|Dry|LINK
Yea, I think you do.
I hate to be picky when I'm in need, but do you have samples of the AutoComplete Page code?
I'm not using Accordians, Just trying to help user spell things from the database in a Drug Name text box.
Thanks
Member
3 Points
55 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
May 29, 2008 02:54 PM|zeeomar|LINK
oh i do understand that you are not using accordians :) i wasnt sure how much you had explored on the ajax.net i believe i have an autocomplete piece that i did also., somewhere., the issue is that most of my prrof of concepts become
website1...... websiteN :)
so right now im gotomypc'd into my laptop which has the code.... ill be headed back home in a bit, when i am infront of it i could try to get you what you are looking for?
None
0 Points
12 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
May 29, 2008 02:59 PM|Dry|LINK
Thanks,
I think my problem might be from the multiple levels going on here.
My site has a Master Page (which is where I put the form since you can only have one)
Then the Page,
Than a Web user control that has the Textbox I am trying to make an autocomplete
The user control has more than one textbox, (Drug name, Strength, Pills per dose, and so on)
I have a few pages that needs the same information, that's why I put them in a user control.
Trying to make the user control handle it's own AutoComplete for only one of the Textboxes is where I'm at.
Member
3 Points
55 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
May 29, 2008 02:59 PM|zeeomar|LINK
found it., this one doesnt use dynamic code to create the textbox+autocomplete but... it has a static textbox with autocomplete., this works, you shd be able to figure out dynamic build up with this., or when i get home i can help you by looking for my dynamic code..
now to attach the file somewhere for you to download
Member
3 Points
55 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
May 29, 2008 03:03 PM|zeeomar|LINK
k., here is the piece that does the autocomplete., it might solve your issue as it will overcome the vs bug., its simple, might be too simple for you., but like i said i dont mind helping you build this into what you want
www.deffuse.com/website7.zip
None
0 Points
12 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
May 29, 2008 03:25 PM|Dry|LINK
I made sure I was setting all the properties in your sample, and the ASP.NET Sample.
Still getting sys is not defined.
Looking in the ViewSource i see :
The file webresource.axd does not exist, I don't know if that is a .Net thing though.
I looked at the source of the ASP.NET Sample and they have the same sys.Application, they dont have sys defined anywhere but IE has no errors for their sample.
I can't find what is different between the sample and mine.
Member
3 Points
55 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
May 29, 2008 04:40 PM|zeeomar|LINK
did my sample work?
None
0 Points
12 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
May 29, 2008 04:58 PM|Dry|LINK
No there were too many errors in Web.Config
There's no file I hate more than Web.Config.
But I copyed the settings you used, do you think it is because i'm in a web usercontrol
Member
3 Points
55 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
May 29, 2008 05:07 PM|zeeomar|LINK
None
0 Points
12 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
May 29, 2008 05:27 PM|Dry|LINK
I put the ToolkitScriptManager on the Master's Page load (where the Form is) instead of the Control
and now I am getting the Same error on all pages!
(sys is undefined)
Does this give you any Ideas?
Member
3 Points
55 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
May 29, 2008 05:37 PM|zeeomar|LINK
do you think you can give me a project in a zip?
Member
3 Points
55 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
May 29, 2008 05:44 PM|zeeomar|LINK
actually here is a better question., are u using the RTM version ? do the samples in the toolkit run for you?
Member
3 Points
55 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
May 29, 2008 05:47 PM|zeeomar|LINK
and which of the two is correct
you have an ASP.NET web site, that you are trying to ajax enable
Or
you created a Ajax Control Toolkit Web Site
show me your web.config :)
None
0 Points
12 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
May 29, 2008 06:18 PM|Dry|LINK
Ok, i tore out everything but the 5 files involved
I put the rar file on a free website:
http://dryrtf.freewebspace.com/
I downloaded The Ajax Control Toolkit Web Site and it completely works
I have a VS 2005 Pro website that I am trying to add the Autocomplete to.
I have added Ajax to the Tool bar in VS, I can drag n drop items onto a page and see the components.
That tiny sample shows the error (yellow exclaim in bottom left status bar area of ie)
but here is my Config:
Member
3 Points
55 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
May 29, 2008 06:30 PM|zeeomar|LINK
try this
under
<assemblies>
put 1 more in there the version should be right., you could compare that line with the samples web.config line (that work)... to ensure the token/versioning...
<add assembly="Microsoft.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"/>
also check in the web.config for the samples that work if there is a <httpHandlers> tag,,,, if there is try to place that in your web.config....
<add verb="GET" path="ScriptResource.axd" type="Microsoft.Web.Handlers.ScriptResourceHandler" validate="false"/>
if you want., you could show me the web.config for the one that works and i can tell you where to copy paste., or put it together for you :)
None
0 Points
12 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
May 29, 2008 07:59 PM|Dry|LINK
I added the httphandlers and the sys error finally went away but the dropdown is still not showing.
Did you look at the Project? on the free site?
Here's the web.config from the AjaxSampleSite that works:
Member
3 Points
55 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
May 29, 2008 08:41 PM|zeeomar|LINK
looked at your project., initially it didnt work., i need to run for dinner., but., what i did was i moved your function call for the list to the defaults code behind
<System.Web.Services.WebMethodAttribute(), System.Web.Script.Services.ScriptMethodAttribute()> _
Public Shared Function GetCompletionList(ByVal prefixText As String, ByVal count As Integer, ByVal contextKey As String) As String() ' you can create a custom string array and return it Dim r As String() = {"Prolax", "Profin", "Prodex"} Return r End Functionand it worked., i think because u are registering the getcompletionlist in the usercontrol it wont/cant fire it up., its possible that to fire it up you might need to use
xyzusercontrol.GetCompletionList
i can mess with it when i get back.,
Member
3 Points
55 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
May 29, 2008 08:50 PM|zeeomar|LINK
k. ,figured it all out
atc.ServicePath =
""because you have it blank., its going to the main callers page.
because your control is nexted in default.aspx
it will look for the service there, try notuseing service path., or try to point to control :)
None
0 Points
12 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
May 29, 2008 09:41 PM|Dry|LINK
You are Awesome!
It is working perfectly!
Thank you so much for your help! I really appreciate you spending your time to help someone you don't even know!
Thanks again! You Rock!
-Dry
(it is pulling from the Database flawlessly! and quicker than I thought it would.)
[Yes]
Member
3 Points
55 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
May 29, 2008 10:51 PM|zeeomar|LINK
glad 2 help :)
None
0 Points
12 Posts
Re: Add Autocomplete page method throws a Exception has been thrown by the target of an invocatio...
May 30, 2008 11:06 AM|Dry|LINK
Just to help people in the future I fixed the sample i made with zeeomar's help and uploaded it to the free site:
http://dryrtf.freewebspace.com/