Questions




Answers
1
Sum of two column values from two different tables

I want sum of two column values from two different tables, how can I do it using SQL?

Suppose, these are my two tables, Table 1

...
Read More
sql sql server
Answers
1
ASP.NET Web-Form Error "WebForms UnobtrusiveValidationMode requires a ScriptResourceMapping for 'jquery'. Please add a ScriptResourceMapping named jquery(case-sensitive)."

I have created a new empty ASP.NET web-forms project using Visual Studio, after adding the new .aspx (web-form) file with the RegularExpressionValidator code as shown below, I am getting an error "WebForms UnobtrusiveValidationMode requires a ScriptResourceMapping for 'jquery'. Please add a ScriptResourceMapping named jquery(case-sensitive)."

Here is the code of my Web-Form page(Default.aspx)

<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="EmailIdValidate.Default" %>

<!DOCTYPE html>
<script runat="server">
    protected void Button1_Click(object sender, EventArgs e)
    {
        Label1.Text = "Your email: " + TextBox1.Text.ToString();
    }
</script>
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>Validate email address using RegularExpressionValidator in ASP.NET</title>
</head>
<body>
    <form id="form1" runat="server">
    <div>
        <h2 style="color:Red">RegularExpressionValidator: email</h2>
        <asp:Label 
             ID="Label1" 
             runat="server"
             Font-Bold="true"
             Font-Italic="true"
             Font-Size="Large"
             ForeColor="SeaGreen"
             >
        </asp:Label>

        <br /><br />
        <asp:Label ID="Label2" runat="server" Text="Email">
        </asp:Label>
        <asp:TextBox  ID="TextBox1" runat="server" >
        </asp:TextBox>

        <asp:RequiredFieldValidator 
             ID="RequiredFieldValidator1"
             runat="server"
             ControlToValidate="TextBox1"
             Text="*"
             >
        </asp:RequiredFieldValidator>

        <asp:RegularExpressionValidator 
            ID="RegularExpressionValidator1"
            runat="server" 
             ValidationExpression="\w+([-+.']\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*"
            ControlToValidate="TextBox1"
            ErrorMessage="Input valid email address!"
            >
        </asp:RegularExpressionValidator>

        <br /><br />
        <asp:Button 
             ID="Button1" 
             runat="server" 
             Text="Submit email"
             Font-Bold="true"
             ForeColor="DodgerBlue" 
             OnClick="Button1_Click"
             />
    </div>
    </form>
</body>
</html>

When building the project and running it browser getting error details as shown below

...

Read More
C# ASP.NET
Answers
1
How do Add class using Javascript?

I wanted to add or remove classes from my HTML <div> dynamically using Javascript, I don't want to use jQuery here, so How can I add a class using JS?

If possible, I would also like to know how can I toggle class in Javascript

...
Read More
Javascript js-add-class javascript-toggle-class
Answers
1
How to trigger click on pressing Enter key inside text input using Javascript or jQuery?

How to trigger the click event on the search button, when user press enter key inside text input html, suppose this is my HTML

...
Read More
jQuery Javascript trigger button click on enter key jquery
Answers
3
Cannot find the check box for enabling SSL in visual studio 2017 (ASP.NET Core project)

Hi, I want to enable SSL for my ASP.NET Core project in Visual studio 2017, but when I'm checking my visual studio project to enable SSL, it looks like this in properties

...

Read More
ASP.NET enable-ssl-in-asp-net-core visual-studio
Answers
1
How to add headers before sending Ajax Request using jQuery?

I was trying to add custom headers before sending ajax request to the server (controller in .NET MVC), but I am not able to send it, here is what I am using as of now

...
Read More
jQuery javascript add header in ajax request jquery ajax custom headers
Answers
2
Checkbox value not posting in ASP.NET MVC form?

I am trying to submit the form in ASP.NET MVC by updating a value of checkbox, but checkbox is not posting updated value to the C# Controller and posting null value, here is my razor code

...
Read More
ASP.NET MVC Razor checkbox value not posting mvc
Answers
2
Redirect to another view using Javascript

Hi, I have this script :

...
Read More
ASP.NET JavaScript
Answers
2
Convert lines of C# code from asp.net mvc 5 under visual studio 2015 to asp.net core2 under visual studio 2017

Hello, how can I made this code with asp.net core 2 under Visual studio 2017.

...
Read More
ASP.NET Code-changes-from-mvc-to-core
Answers
4
FB popup not back in the web main windows, but stay in the popup

Hi, I had ask a question on this link about how can minimize a full page login with facebook in just popup :

https://qawithexperts.com/questions/360/login-with-facebook-using-oauth-redirect-us-to-full-page-how

but this FB popup does not return to main windows, stay in the popup , I would like to have code which should return back login details in the main tab.

Right now, when logging using popup It is still inside popup & not redirected to the main tab.

...

Read More
ASP.NET Login-fb-with-pop-up

Page 5 of 41