Can I use the ASP.NET AJAX Control Toolkit in my MVC4 Application? - asp.net-mvc-4

I've spent a fair amount of time researching this, as I would rather not find out through trial and error.
Can I use the ASP.NET AJAX Control Toolkit in my MVC4 Application? Is there Microsft documentation that gives definitive information?
Yes, I know that MVC4 does not have VIEWSTATE. I am using the Razor view engine.

The documentation for the toolkit states specifically that it is for web forms, not mvc.
http://ajaxcontroltoolkit.codeplex.com/
If there is a specific piece of functionality you required, then you might want to see if there is a plugin available for jquery to replicate it.
http://api.jquery.com

Related

Speech to text in dot net core 3.1 web app without using cloud services like azure

I am trying to implement speech to text on my .net core 3.1 web app without using any cloud services like Azure, AWS, or Google.
I have found options like deepspeech, kaldi,pocketpheonix. It looks like they can be implemented on a .net core app but being a beginner in .net core and backend development I don't know how to use them and their documentation is not very beginner-friendly.
So if you can provide a brief overview of how to implement these apis on .net core or link to some articles, that would be very helpful.
Just my personal view, some Kaldi or PocketSphinx experts might have a different view.
Kaldi + PocketSphinx
You will need to compile all sources yourself on Windows and Kaldi is a headache to build on Linux, so I guess it is not much better on Windows. That said, they use less resources and are usually quicker.
DeepSpeech
Just download the current English acoustic model (pbmm) and language model (scorer) and use the .NET example code. Should work without compilation.

Using AJAX in WebSite Razor 3

I am programming a website in VS2013 in VBHTML (Razor 3).
This site does not use MVC.
I'm looking for documentation to use AJAX, but I only find information using MVC.
Does anyone know if it is possible to use AJAX without MVC????
Yes, it is possible to use AJAX in a non-MVC web application.
The below link should help get you started.
https://www.codeproject.com/Articles/691298/Creating-AJAX-enabled-web-forms
"Beginning ASP.NET 4.5.1 in C# and VB" by Imar Spannjaars walks you thru creating a website (not using Web Matrix) and chapter 13 is all about ASP.NET AJAX. This book uses websites instead of web applications and does not cover any MVC.
Also the book "Professional ASP.NET 4.5 in C# and VB" is also a good resource.
This book focuses on developing applications using webforms.
https://www.amazon.com/Professional-ASP-NET-4-5-C-VB/dp/1118311825/ref=sr_1_2?ie=UTF8&qid=1498491649&sr=8-2&keywords=ASP.NET+4.5
Hopefully this will help you out.
Best regards,
Joe

What is the equivalent of WebForms in ASP.NET Core?

I am doing my final year project in Computer Science and the project is a system for managing a college, like openSIS, but using ASP.NET Core to build it.
I need help on how to Add, Update, and Remove data using regular HTML forms, such as via <form/> and <input type="submit"/>. I knew how to do this in WebForms, but not in ASP.NET Core.
What you're asking to do is possible "out of the box" with ASP.NET Core and does not require a third-party solution.
Solution #1: ASP.NET Core Razor Pages
Microsoft - Introduction to Razor Pages
This is probably the most direct approach with the least to learn, and it is the modern equivalent to "Classic ASP.NET Web Forms." You are probably asking about this:
The basic idea is you create an "ASP.NET Core Web Application" project in Visual Studio and select the "Web Application" project template (confirming that ".NET Core" is selected in the template selection dialog before you click OK.)
You can then add "Razor Pages" containing HTML, CSS, and JavaScript, and use a simple post-back method via a regular HTML Form with a Submit Button. The link above has a topic on doing just that.
Solution #2: ASP.NET Core MVC
Microsoft - Overview of ASP.NET Core MVC
This is the second-most direct approach but does require you to grasp MVC concepts: Models, Views and Controllers. Implementing Razor Pages would only require you to grasp HTML and Razor Page code-behind, however, MVC as a pattern will provide your resulting project with a more maintainable and testable approach to the project.
The basic idea is to scaffold an "ASP.NET Core Web Application" project in Visual Studio, then select the "Web Application (Model-View-Controller)" project template.
Instead of adding Pages you add Views, to do anything useful these Views will have corresponding Controllers. There will also be Models defined, as you would see in a Razor Pages solution. In the case of MVC the Models are posted to your Controllers via Actions.
The link above covers the subject in detail, and there are numerous Stack Overflow posts on general MVC concepts.
Solution #3: RESTful Web APIs and Client-Side JavaScript
Microsoft - Building Web APIs
This is probably the least direct and most-technical approach. You will want to be familiar with "JavaScript" and "XHRs", "JSON" (or XML, but JSON has become de facto), and you will want to be versed in what it means to be a "RESTful Web Service" ie. that HTTP supports basic verbs to POST, GET, and DELETE a resource.
The basic idea is you create an "ASP.NET Core Web Application" project in Visual Studio using the MVC scaffold. You then implement Controllers to behave as RESTful web services. You can add Razor Pages and/or MVC Views to deliver the HTML and JavaScript.
With this approach you can create "Single-Page Applications" that never need to reload, where the HTML and JavaScript for the entire application can be delivered up-front and then RESTful web services used to modify the UI at the client. This can get advanced, and most developers will want to look into using a client-side templating engine. The leanest and simplest to use is probably going to be KnockoutJS, but others are more popular (and more complex.) Knockout has the value of solving a very specific problem: data-binding an HTML UI to JavaScript objects.
Regardless of the approach you take, start here: Microsoft - Get Started with ASP.NET Core
If you like the Web Forms way of development, or if you have a large ASP.NET Web Forms application and you need to implement new pages in it, you can try DotVVM.
It is not "Web Forms on .NET Core", but:
many concepts in DotVVM are similar to ASP.NET Web Forms (postbacks, server controls, master pages, even the names of the controls and page lifecycle events)
it is easy to learn for ASP.NET Web Forms developers
no cryptic viewstate hidden field
the controls don't produce ugly HTML
the MVVM pattern is used
no need to know or write JavaScript - C#, HTML and CSS is enough to start coding
DotVVM supports both .NET Core and full .NET Framework
can be added to existing ASP.NET Web Forms or MVC applications on .NET Framework
DotVVM is open source
Visual Studio extension with IntelliSense and project templates
Disclaimer: I am one of the authors of DotVVM. This post is not meant to advertise the project, I just believe it responds to the question because the main motivation to build DotVVM was the fact that Web Forms are not ported to ASP.NET Core, and many people is looking for the similar way of building web applications. DotVVM is not a port of Web Forms to .NET Core. Our intent is to build a framework which is conceptually similar, but which avoids the things Web Forms were criticized for (viewstate, testability and ugly HTML output).
DotVVM GitHub
Documentation
Gitter Chat
If you are referring to WebForms from ASP.NET (before MVC webstack came), there is no WebForms for ASP.NET Core and unlikely to ever be ported.
There is however a similar project (usually referred as Razor Pages or View Pages, see RazorPages GitHub repository) which allows to create Razor views which are not backed by a controller.
But as far as I know it's not release ready (there is no nuget package for it on nuget.org) and you'd have to use some previous from nightly builds or stable myget repositories.

Web API run VB6 COM components in STA mode

Masters,
I've few past developed VB6 components that are heavily used in our most of the applications
Now, we want to consume same components for newly developing Web API project.
But, as per this post ,
http://www.west-wind.com/weblog/posts/2012/Sep/18/Creating-STA-COM-compatible-ASPNET-Applications
We found strike on Asp.net Web API it might due to we don't have any page in Web API project.
Please tell me correct workaround achieve this.
Thanks in advance.
I would suggesting looking into the StaTaskScheduler http://blogs.msdn.com/b/pfxteam/archive/2010/04/07/9990421.aspx

What framework should I choose to build a WCF Restful API

I am wanting to build a Restful API using WCF however I am struggling to make a decision on how to accomplish this.
The WCF Rest Starter Kit was developed for .Net 3.5 and has not progressed past Preview 2. Although it can be used within the current .NET Framework and within Visual Studio 2010 it seems from my research to be dead in the water and superseded by the new WCF Web API which is currently in Preview 5.
On the other hand the WCF Web API is only at preview stage and should not really be used in a production application as many things could possibly change before its release. There is also no indication if its nearing completion and if it’s going to be in the next .NET Framework release and when that is intended to be.
I find myself between rock and a hard place and look to the wider community to provide me with some guidance on this if at all possible.
You should regard this tweet from Glenn Block.
Using ASP.NET MVC for building a Restful API should be straight forward and easy way to do it.
However I've used WCF Web Api with WCF Rest Contrib in production without any problems.
See
Creating REST API with ASP.NET MVC that can speak both JSON and Plain Xml
RESTful Services With ASP.NET MVC
ASP.NET MVC – Create easy REST API with JSON and XML
Maybe OpenRasta is what you are looking for?
See also
RESTful framework alternatives to WCF
I depends on your application. If its a Website (also has views) that offers the REST API using ASP.NET MVC would be less technology, less effort, less know-how etc.
If its JUST an REST API choose what you like more from development style: ASP.NET MVC or WCF Web API