Questions tagged [asp.net]

ASP.NET is a Microsoft web application development framework that allows programmers to build dynamic web sites, web applications and web services. It is useful to use this tag in conjunction with the project type tag e.g. [asp.net-mvc], [asp.net-webforms], or [asp.net-web-api]. Do NOT use this tag for questions about ASP.NET Core - use [asp.net-core] instead.

Filter by
Sorted by
Tagged with
0
votes
2answers
15 views

How to avoid redundancy/save data in EF Core many-to-many relationships?

Can someone please answer me how to properly add and insert data into a join table/many-to-many relationship with Entity Framework Core, without saving data multiple times? My Database Context looks ...
0
votes
0answers
21 views

Displaying Data in ASP.net To a cshtml page

Simply put, I can't work this out. I have a class (is that the right word?), at the moment, which captures all the data from the database I need. You can find that in this question. The only main ...
-1
votes
0answers
14 views

How to check if file exists via md5 hash in Google Drive ASP.net

I have a ASP.Net program that accepts files, download and delete files from Google Drive. I would like to check the hash value of a file first before being uploaded. If there is already an existing ...
0
votes
0answers
12 views

Web Page Authentication ASP.net current opinion

I am a novice (but learning) developer in C# and have several public websites. I now have one that needs to implement a user login. I have read the tutorials and blogs and watched several YouTube ...
0
votes
0answers
14 views

Custom Middleware is causing Blazor Server-side page to stop working

My custom middleware appears to be causing some sort of conflict with my blazor server-side page. The sample middleware in short checks for a bool status and if true redirects to the counter page ...
1
vote
1answer
33 views

Return id of record when insert or update or delete record

When I insert or update or delete an entity with Dapper, I need to return the id of entity. I am using this code : var role = await roleConnection.ExecuteAsync("UPDATE Role SET IsDelete = @...
0
votes
0answers
25 views

ASP.net API response, doesnt return json

I wrote a react-native app with an express.js backend. Now I wanted to create an asp.net (WebApi) backend for this app. Both have the same endpoints, but the response from the asp.net backend doesnt ...
-1
votes
0answers
13 views

I want to print a crystal report for a specific query that contains session variables

I want to print a crystal report that contains values for the session user. I specified the datasource for the report as a data set that contains this query: select f.flight_number as 'Flight Number',...
-1
votes
0answers
16 views

ApplicationDbContext and dependency injection problem

I have a problem with ApplicationDbContext, when I use the _context variable to access the database inside the CustomLogger class or in the createLogger method the application crashes and doesn't work....
0
votes
0answers
11 views

Submitting “complex” ASP.net forms using cURL&PHP

I'm trying to create a bot to submit a ASP.net form using cURL and PHP. I'm able to do this with simple forms but I got stuck with one email form that uses a grid. Looking the network traffic when ...
0
votes
1answer
40 views

Inside for loop if condition not working?

I am trying to get Data from database to text box on select index changed. I am getting an output, but I'm using simple if statement inside my loop but its not working where am I doing wrong Please ...
0
votes
0answers
20 views

How can I iterate over a databound value of an asp.net repeater? (C#)

I'd like to iterate over the value of each entry in a c# dictionary within my asp.net repeater. My IDictionary is nothing special - Just key-value pairs of data, and the values are arrays of strings. ...
0
votes
1answer
15 views

How many Garbage collector instances are created in ASP.Net when multiple applications are running on single OS?

Is there a single GC for an OS for Asp.Net Or there is single per CLR/Process running? And if its not single for an OS then how individual GCs decide whether to ask more memory from OS or to throw ...
0
votes
0answers
20 views

Problem in downloading csv file, I have create it but not able to download in asp.net

protected void LnkExcelDownload_Click(object sender, EventArgs e) { try { string sqlConnectionString = ConfigurationManager.ConnectionStrings["ConString"].ConnectionString; ...
0
votes
0answers
19 views

Pass two value with two parameters in c# into sqlcommand and read value to disable button?

I am trying to get this method to read values from the database as well as to get values from an asp.net webform. I have tried the code below but never worked public void CheckLikedEvents() ...
0
votes
0answers
24 views

Upload button C# check for MD5 hash before uploading file

I have a block of code which would upload the file into the Google Drive. My main issue here is that when the user clicks on the upload button, the MD5 hash of the file will be checked and compared ...
-2
votes
0answers
18 views

How To make Video as UnDownloadable in website [on hold]

I am Working on our website but I need a video player that unable to download video from our website But it's also unDownloadable from the video source
0
votes
0answers
12 views

Tcp/Udp winForm connection with javascript websocket of web application

my task is to connect two application, one is desktop application and other is web application. web application send message and it will be receive by desktop app if it is open. i was thinking to ...
-1
votes
0answers
13 views

Report With Horizontal and vertical columns

hi have generate report like here report format how does this achieve with database and my database format is my database format
0
votes
0answers
13 views

I want to not accept the vacancy. Only take the value EmailBody Send email only

I want to not accept the vacancy. Only take the value EmailBody Send email only string username = "[email protected]"; string password = "abc"; SmtpClient smtpclient = new SmtpClient("smtp.gmail.com")...
-1
votes
2answers
36 views

I want to enable the textbox if the value of the radiobtnlist is 1

// I have this code to disable the textbox if the value of RadioButtonList is //zero. But it is not working //I do not know why. <script type="text/javascript"> $(function () { ...
0
votes
0answers
13 views

Handling cookies based on route in a single request lifecycle in ASP.NET MVC?

I'm writing a route that will allow the user to set a cookie with the version of some JSON object that the application will use to set client-side configurations. It is a fairly large JSON object that ...
2
votes
2answers
129 views

Node.js framework with a meta programming capability [on hold]

Im looking for a Node.js framework with a meta programming capability. I have 8+ years in asp.net framework and very happy with its reflection library. I did a lot metaprogramming on my projects to ...
1
vote
2answers
30 views

It is possible to send a message to a specific user using SignalR?

I am new to SignalR, recently I am examining and learning how the following code works. Link: https://docs.microsoft.com/en-us/aspnet/signalr/overview/getting-started/tutorial-getting-started-with-...
-1
votes
0answers
13 views

Logical check for data populating grid view

I have about 200 tables I'm loading data into my website depending on what the user enters. I'm doing a logical check for what the user has filtered, however I'm getting a 404 error when I add the ...
0
votes
0answers
32 views

Display User's Infomation in MVC using @Model.xxxx

I have a login page and registration page all are working fine. I have a users table i created in sql server database with the column Username, FullName, School, Course. I want to display all the user ...
0
votes
2answers
20 views

Set Table Attribute Dynamically [duplicate]

I am trying to set the TableAttribute for my view like so: [Table(LSODatabase.databaseString)] However the following error is thrown: An attribute argument must be a constant expression, typeof ...
1
vote
0answers
16 views

Inconsistent redirection to root page(Search page)

I am trying to troubleshoot an existing .Net application which I did not code. The application runs on a split config windows server 2016 server(DB is on another server) running .NET version 4.7.2. ...
1
vote
1answer
16 views

Why is the “last_read” property zero for a 1:1 DM between a user and an app bot with message history?

I'm setting up a Slack App to post messages via the Web API and using a bot OAuth token from an ASP.NET web app, and one of the requirements is for the Slack app to be able to return a relevant value ...
0
votes
0answers
23 views

Closing a DIV on an ASP.NET page with a Master page using a button in the div, where JQuery was used to show the div

I have this DIV on my page (which has a Master page) <div id="whatsNew" runat="server" style="position:absolute;left:-500px;top:500px;background-color:aliceblue;"> <button id="...
0
votes
0answers
8 views

Trying to rename outlook draft attachment in asp.net mvc controller

I am trying to build a simple controller that will open an outlook draft email with a PDF attachment. The attachment is a report that gets generated on the fly using SSRS. I grab the pdf via a SSRS ...
0
votes
1answer
17 views

Asp.net Web Api Multiple Custom Objects through Query String

I'm working on an api and I wanted to try and get sort filter and pagination objects through my query string in json form. Currently I'm calling my api with this: baseUrl/reviews?sort={"direction":"...
0
votes
2answers
20 views

Scrapper problems with ASP.NET locating objects - Selenium

Im new into python, and im trying to make a scrapper into a ASPX website. I got two types of results in this page, the empty ones and the results, My code can get the empty ones but i cant get the ...
-1
votes
1answer
28 views

AuthorizeAttribute doesn't work when refresh the page

I have some problem with authorization: The AuthorizeWebForm codes work when loading the page, I am not in the admin group so I don't have the access, which is great. But when I refresh the page, I ...
0
votes
0answers
15 views

How could I reuse powershell scripts in a sharepoint on prem solution?

I have been administrating the SharePoint on-prem versions with PowerShell commands and scripts easily. Now, I don't have direct access to the server, but I have the database rights. I am trying to ...
0
votes
1answer
25 views

Saved PDF file is corrupt after download if user visits my asp.net site from email link, but is not corrupt after manual login?

My apologies if I've missed any applicable answers during my search. My asp.net website sends user A an email with a link. Trustwave adds some wrapper information around the link before delivering ...
0
votes
1answer
14 views

Prevent output cache when the result is null

In my project I use the OutputCache attribute so my web server doesn't have to keep downloading the same files, but rarely there are some issues where for unknown reasons it returns null. So If the ...
0
votes
0answers
15 views

Different size of pages on gridview [on hold]

I have a grid view with page indexing , but I want to know if there´s a way to have different PageSize for every page .
1
vote
1answer
30 views

ASP.NET web form: display value coming from c# code-behind

I am working with Visual Studio 2019, where I am creating a web form. My code-behind pulls data from a database using a sql script. I have to display some of these fields in the web form. For ...
0
votes
0answers
13 views

Needed changes when migrating a Classic Asp.net project to a Asp.Net MVC

I'm trying to migrate an old project written in Classic Asp.net to Asp.net MVC ,and I'm havingg quite difficulties trying to move the files in the MVC project, like these: Where to put the App_Code_ ...
0
votes
0answers
18 views

How to use static currency values for all users in asp.net

I am trying to use currency values for calculation in asp.net. I just wonder to know if we get currency data from sql server than how to keep static data in asp.net? Are we need to use static dataset ...
0
votes
4answers
58 views

Convert object {object[]} to string[]

I have received data of type object {System.Collections.Generic.Dictionary<string, object>}. Parsing this is pretty straightforward: Dictionary<string, object> parsedData = data as ...
0
votes
0answers
10 views

How to post data from rich text editor from angular 8 to sql server using asp.net framework?

i have used ckeditor in Angular 8 and have created a Database in which I have to post the data from my front-end to the sql server using ASP.NET framework
0
votes
0answers
18 views

pass and read gridview values and compare with another table

I have query my table in gridview. I want to get value in each row in the gridview and check with another table DefectType. But this table contains 50 columns with Defectname1,Defectname2,Defectname3.....
-3
votes
1answer
17 views

Live Search Data In asp.net MVC with AJAX and Jquery [on hold]

I want to add live search features in my asp.net MVC page. I have Product category table in my database with category name and category image. And i have displayed all this record in a view form ...
-2
votes
0answers
25 views

how to use delegates in web application in c# asp.net

I tried in internet using delegates but i didn't found about delegates in web-application can anyone help? how to use delegates in backend programming of asp.net web application
0
votes
0answers
10 views

Change Webservice Request Envelope

I have a web service .asmx using .Net, How can I change the request from:<soap:Envelope xmlns="xxx"... to <soapenv:Envelope xmlns="xxx"... [SoapElement(NameTable= "abc") ] [WebService(...
0
votes
1answer
21 views

Spotify Redirect adds character before parameters

Problem I am currently creating a ASP.NET application that has the user login to Spotify before use using the Spotify Web API. Upon calling the API you specify a response_type, client_id, scope, ...
0
votes
0answers
15 views

Method is getting invoked with out calling

I am getting following Error when trying to convert the report data into PDF. For the first time it's working fine, but while clicking the PDF button second time I'm getting following error while ...
0
votes
1answer
31 views

How do I disable LinkButton in gridview based on a value from another column?

I have a status column which includes approved, rejected or cancelled. I have another Actions column which contain link buttons approve and reject. Now if the status is Cancelled, I want the link ...