Join us in building a kind, collaborative learning community via our updated Code of Conduct.

Questions tagged [.net]

The .NET framework is a software framework designed mainly for the Microsoft Windows operating system. It includes an implementation of the Base Class Library, Common Language Runtime (commonly referred to as CLR), Common Type System (commonly referred to as CTS) and Dynamic Language Runtime. It ...

1
vote
0answers
21 views

Converting cURL command to RestSharp

I am trying to convert this curl command to RestSharp. curl -k -insecure "https://accounts.google.com/_/signin/sl/lookup?hl=tr^&_reqid=66671^&rt=j" -H "cookie: __utmx=173272373.NsRgTn8iQf-...
1
vote
0answers
12 views

Cross Process (and machine) Synchronization (Semaphores)

Background: My WCF application has to call a service that does not have any concurrency checking in it. It is a service created by a third party and getting them to add concurrency checking may not ...
0
votes
0answers
7 views

Ignore all nested subdirectories in .tfignore

I have a folder structure like so: -root -Proj1 -Addedthings -Tables TableFiles -Proj2 -Addedthings -Tables TableFiles -Proj3 TableFiles ....
-6
votes
1answer
49 views

Getting a list of classes that inherit a specific interface?

I'm using dependency injection in my project and wondered if it would be easier to just register all 30+ of my classes that inherit a certain interface using a for each, that way it works dynamically. ...
0
votes
1answer
19 views

Web API WorkBook download

I have a Workbook using Microsoft.Office.Interop.Excel. My problem is this will be a API call and currently it works but saves to the server. Is there a way to have it download straight to the client ...
0
votes
0answers
6 views

How can I create a CATIA RIB in C# from a 2D Sketch and a 3D Spline?

The problem in C# is, the method ShapeFactory.AddNewRib will only accept a Sketch object (with a 2D Spline in it). In CATIA I create a 3D extrusion "RIB" from a 2D Sketch and a 3D Spline​. CATIA ...
-1
votes
2answers
21 views

Editable combobox not working properly

I have made a Editable Combobox which does filtering of items. If i type A it shows me items which start with A. But problem is that it works for only one time. Then again i have to reopen program ...
2
votes
3answers
32 views

Is there an OCP-friendly way to dynamically choose which collection in a DbContext to access?

I'm working on a method to retrieve a collection of records from a database. The records are stored in separate tables based on an aspect of the data they contain. Suppose it looks like this. public ...
-1
votes
0answers
10 views

Unit Test for asmx web services in visual studio 2008

I created an unit test for asmx web service devolped in visual basic. net, in visual studio 2008. But i get this error: "The Web request 'http://localhost:9120/' completed successfully without ...
0
votes
0answers
10 views

Apart from Owin, anything else do exist for authentication work as middle ware?

I have a problem with Owin. It's old and not much appreciated anymore. Moreover, it's really not work able in ISS when combined with .NET Remoting. I really need to know Is there any other security ...
-1
votes
0answers
13 views

Create icon container beside my map in vs

I have got a gis map using vs and c#. Is it possible to create next to the map an ICON BOX so that I drag and drop icons into the map from this box that will contain many icons??
0
votes
0answers
12 views

Entity Framework with Web Api 2 - Performance issue

First of all, I want to say that I’m a beginner in .NET and I'm a beginner in english. :( I have the following code in my controller: The intention is to send the data set to the clients. I need to ...
-1
votes
0answers
12 views

A first chance exception of type 'System.NullReferenceException' on linkButton press [duplicate]

Lost on this issue. I'm using a repeater, and this method works on other things. Code behind: protected void rpt_TL_Menu_ItemCommand(object source, RepeaterCommandEventArgs e) { ...
-1
votes
0answers
9 views

NPOI does not recognize CellStyle

Hi i have to use VB (old project) and i wonder why NPOI does not recognize the Cellstyles, the bluecell cellstyle results in grey dots, and the redcell Style results in no background, whereas the ...
0
votes
0answers
20 views

Cant access dynamic object properties out of Dapper query response

I'm using Dapper to execute a stored procedure and get a single row response. My code is the following: public async Task<Provider> GetProvider(int id) { try { ...
1
vote
1answer
17 views

Is there a way to make the MoveNext() part of foreach loop retry the operation when applied to result of Azure Storage Library ListBlobs()?

I have code using Azure Storage Library that goes like this: CloudBlobContainer container = obtainContainer(); var blobList = container.ListBlobs(options:OptionsWithLinearRetry); foreach (var ...
0
votes
1answer
24 views

Grab element from a Collection by reference in a foreach [duplicate]

This is a followup to this question: How to replace an element in a Collection There I found a workaround for the particular issue of replacing something in a collection. However, that doesn't make ...
1
vote
2answers
46 views

can I have .NET automatically write the exception message to the event log when an uncaught exception is thrown?

I have a non-interactive application where I need to load some string fields before a log file is instantiated. There is a method that reads the contents of a text file into a field. If the path does ...
1
vote
0answers
15 views

create your own packages installer

Good afternoon, I recently encountered a problem, I use the UVP and created my application installer. But applications on some computers are not installed for some reason. I use a "PackageManager" ...
0
votes
1answer
12 views

OxyPlot - MouseDown event does not fire on line series

On my OxyPlot I have a DelegatePlotCommand bound to the PlotController.MouseDown event: var commandLeft = new DelegatePlotCommand<OxyMouseDownEventArgs>((v, c, a) => { ...
1
vote
3answers
71 views

How to replace an element in a Collection

The thing I wanna do would appear really simple - I want to find an element in an ICollection<T> that satisfies a given predicate and replace it with another. In C++ I would write this like: ...
0
votes
0answers
6 views

Do the BeforeFeature and AfterFeature hooks need to be thread-safe when running SpecFlow scenarios in parallel?

I'm looking into running SpecFlow scenarios in parallel using NUnit and would like some clarification on BeforeFeature and AfterFeature hooks. The SpecFlow doc states these hooks may run multiple ...
-2
votes
0answers
30 views

Create an Installation programm for C# Application [on hold]

I found old Threads where different tools are droped. But with what Technologie do you create 2018 Installation programms for your C# Application ? Did anyone still use WixToolset or SharpSetup ? ...
0
votes
1answer
88 views

Replace multiple method calls using if statement with ternary operator in C#

I need to replace multiple if calls with ternary operators. I am currently using the if conditions to call the same method with different parameters based on the if condition. I am currently calling ...
0
votes
1answer
30 views

How can ASP.NET MVC takes more than 10 Seconds to load (for the first time) a blank Controller?

I'm managing an ASP.NET MVC application which use (basically) .NET MVC and Entity Framework. I notice that every time I Publish the website, it takes very long time (around 10-15 seconds) every time I ...
1
vote
0answers
35 views

ASP.NET Core targeting .NET Framework 4.6.1 missing some assemblies available in ASP.NET Core targeting .NET Core 2.1?

I begin my first ASP.NET Core project targeting .net core 2.1 and while i advance in the project i see that i need some nuget package that ar not available on .NET Core so after i decide to create a ...
1
vote
1answer
18 views

Nuget - Declare NuGet PackageSource in packages.config

Is there any way to declare in the file packages.config the private feed URL where to download the packages instead of using the %AppData%\Roaming\NuGet\NuGet.Config? What is the best practice to ...
-1
votes
0answers
18 views

Why is the application cache not cleared?

Could someone please explain how the Application Pool actually is cleared in .NET? The reason I'm asking is because I am seeing a lot of unmanaged memory when running dotMemory on our WebApp (close ...
0
votes
0answers
15 views

ADOMD.Net Query Result Is Not Correct

I'm trying to use the MSSQL Analysis Server. I'm trying to execute a DMX query however the readers result is not in correspondence with the SQL Server Management Studios as the reader throws index out ...
1
vote
1answer
7 views

How to configure ServiceStack.Text to use EnumMember when serializing to csv or jsv?

This is a follow up question to my earlier question about ServiceStack.Text and deserializing json to .Net enums. The answer to that question resolves how to get ServiceStack.Text to use .Net ...
0
votes
0answers
11 views

Jenkins can't restore .net core project

I set up Jenkins to download a .net core project from a git repository and then execute the command dotnet publish When I run the command outside Jenkins, in the same machine, it works. When I let ...
-1
votes
0answers
21 views

Error regarding different .NET Frameworks for referenced libraries

There is an ASP.Net website created. It uses the .NET Framework 4.5.2. In that website, one class library is referenced, which uses .NET framework 4.6.1. There is an error (out of scope of this ...
0
votes
2answers
21 views

How to make query parameters required for complex type in ASP.NET Web API

I have a controller with the following action: public class MyController { public IHttpActionResult GetSomething([FromUri] int param1, [FromUri] int param2 = 2) { // some code... }...
-1
votes
0answers
18 views

Prevent/Disable the generation of satellite assemblies

I have a windows service (.NET 4.6.1) application without any RESX file. There is absolutely no need for localization. To keep the build and deployment as small as possible, I'd like to kick out ...
1
vote
0answers
13 views

How to justify text in textfield in editable PDF using C# itextsharp?

I am using iTextSharp to fill PDF. I have textfield and I am inserting 4-5 lines of text in textfield programmatically. Text lines are not properly aligned. I kept it as left aligned as textfield has ...
0
votes
0answers
10 views

UserControl Label AssociatedControlID Issue

I have created two user controls, each using intrinsic ASP.NET elements (i.e. no HTML controls)... DataTextBox <%@ Control Language="C#" AutoEventWireup="true" CodeBehind="DataTextBox.ascx.cs" ...
0
votes
1answer
25 views

Disable mixing of colors in LinearGradientBrush in WPF

I have a chart application where I show frequency distribution of certain entities based on their values. I am displaying the chart in BarSeries(Telerik). I am using LinearGradientBrush as coloring ...
1
vote
2answers
26 views

Get 'excelcnv.exe' location

I am working with 'excelcnv.exe' to convert '.xls' files to '.xlsx' version. I can do this by referring 'excelcnv.exe' location directly in machine where I am working now. In my current machine, ...
-1
votes
0answers
13 views

How to use System.Resources.Tools.StronglyTypedResourceBuilder 15.0

Where can I find and how can I use System.Resources.Tools.StronglyTypedResourceBuilder version 15? I generate my resx.Designer.cs files myself. If I use the ResourceBuilder of System.Design.dll it is ...
0
votes
0answers
21 views

Protecting Local API calls Dotnet Core

I've been working a bit with Dotnet core recently, and I was wondering if I wanted to make a local API that only gets used from the sites pages and not for external use. Would the standard [...
0
votes
0answers
8 views

Space in bootstrap-select live-search

My problem is quite simple. In fact when I do a search in my dropdonw list when I type a space the dropdown disappears. I have correctly configured the bootstrap-select live-search but that does not ...
0
votes
1answer
25 views

MVC crud operations with paging and retaining the same page after the record on 2,3..nth page is being updated

(using another view for editing) [not partial view]. After clicking on save ...the same page should open which consists the record that has beenupdated not the first page. INDEX METHOD IN CONTROLLER ...
0
votes
0answers
5 views

How to configure AWS ElasticBeanstalk to install AppDynamics .NET Agents?

I have not configure any ElasticBeanstalk EC2 instances before. Now i have to configure EC2 instances for AppDynamics .NET Agents installation. Can you please help me understanding the feasibility of ...
0
votes
0answers
25 views

Why does a .net program use more VirtualMemorySize64 when the computer has more ram

I've created a simple test application which allocates 100mb using binary arrays. using System; using System.Collections.Generic; using System.Diagnostics; using System.Text; namespace ...
1
vote
1answer
54 views

Must adhere to an interface that doesn't return Task - must use async library

We are using Biztalk. And in order to implement a disassembler component we must implement a specific interface (IDisassemblerComponent) that of course does not use Task as return type. On the other ...
0
votes
0answers
50 views

How to call async method from Getter and Setter?

I am trying to call async method from property. my code is private Command _forgotCommand; public Command ForgotCommand { get { return _forgotCommand ?? (_forgotCommand = new ...
0
votes
1answer
40 views

How to add multiple textBox values in a text file (.txt) in c#?

I have used this code, but it is only saving the value for the textBox1. The other two values are not saving. Please check the input and output scenario. Input: Name: aaa College: bbb Roll: 111 ...
0
votes
2answers
24 views

Link ASP.Net Identity table to a user detail table

I am trying to link my Identity user table to a user detail table I have created to track other user information. That user detail table is called UserProfile. I came across this link but it is not ...
-2
votes
1answer
32 views

How to run and/or debug a large .NET Framework project

I have a large .NET Framework web project (many files and pages, it accesses SQL Server database) that I need to run, debug, and understand in Visual Studio 2015. I'm new to VS and the framework. I ...
0
votes
1answer
28 views

Passing object of class defined in assembly1 to assembly2, without changing assembly1

I am trying to create tools for a game to learn, as well as improve my own playing experience. The primary .NET assembly, csass.dll, that controls the client is heavily obfuscated, and I have no ...