Microsoft Visual Studio

Microsoft Visual Studio is an integrated development environment (IDE) from Microsoft. It is used to develop computer programs for Microsoft Windows, as well as web sites, web applications and web services. Visual Studio uses Microsoft software development platforms such as Windows API, Windows Forms, Windows Presentation Foundation, Windows Store and Microsoft Silverlight. It can produce both native code and managed code.

Share tech news, updates, or what's on your mind.

Sign up to Post

When I try to run a web application in Visual Studio 2019 I get the following error.  How do I fix this once and for all?

Unable to connect to the configured development Web server.

Output from IIS Express:
Failed to register URL "http://localhost:1789/
Error description:  The process cannot access the file because it is being used by another process. (0x80070020)

Is there an alternative to using IIS Express?
0
Exploring ASP.NET Core: Fundamentals
LVL 13
Exploring ASP.NET Core: Fundamentals

Learn to build web apps and services, IoT apps, and mobile backends by covering the fundamentals of ASP.NET Core and  exploring the core foundations for app libraries.

Hello Experts,
I have this piece of code in Visual CS

            System.Diagnostics.Process process = new System.Diagnostics.Process();
            System.Diagnostics.ProcessStartInfo startInfo = new System.Diagnostics.ProcessStartInfo();
            startInfo.WindowStyle = System.Diagnostics.ProcessWindowStyle.Hidden;
            startInfo.FileName = "cmd.exe";
            startInfo.Arguments = "/C NET USER" ;
            process.StartInfo = startInfo;
            process.Start();

            startInfo.Arguments = "/C copy " + (char)34 + "D:\\_ms2\\02 FamBZP\\Lalita\\DNI_LALITA_29325453.jpg" + (char)34 + " " + (char)34 + "C:\\tmp\\ftp\\aaaaaaa.jpg" + (char)34;
            startInfo.Arguments = "/C copy " + (char)34 + "D:\\_ms2\\02 FamBZP\\Lalita\\DNI_LALITA_29325453.jpg" + (char)34 + " " + (char)34 + "C:\\tmp\\ftp\\BBBBBBB.jpg" + (char)34;
            process.StartInfo = startInfo;
            process.Start();

            System.Diagnostics.Process.Start("CMD.EXE", "/C D:&cd \\temp&dir& pause");

How can I verify if each dos command was executed successfully?

The code works just fine, I would like to programmatically verify the success / errorlevel / output
Regards,
0
My HiddentFields are getting document.getElementById are not working as expected inside javascript in asp.net. Everytime I tried set a value for hidden field I get the following error

Uncaught TypeError : Cannot ready property 'value" of null


In the below code there is a javascript function loadfile().
This is the line where i am getting the error : document.getElementById("hAction").value = "";
if I move past that error the next step where i have to read/update value for a variable I am getting the above mentioned error. So looks like somewhere the variables are not getting set correctly

Here is my aspx code :

<%@ Page Language="C#"  MasterPageFile="~/MasterPage2.master" AutoEventWireup="true" CodeBehind="A.aspx.cs" Inherits="A" %>
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>

<%@ MasterType VirtualPath="~/MasterPage2.master" %>

<asp:Content ID="Content2" ContentPlaceHolderID="CP1" runat="Server">


<meta http-equiv="Pragma" content="nocache">
<meta http-equiv="Expires" content="-1">
<title>Account Exception Upload</title>
<%--<script type="text/javascript" src="ccr_scripts.js"></script>--%>
<script type="text/javascript" src="/apps/jfunctions.js"></script>
<script type="text/javascript" src="/apps/jquery-1.11.1.min.js"></script>
<link rel="stylesheet" type="text/css" href="/apps/commonStyles.css" />

<script type="text/javascript">

var timerID = -1;

function cancelProcessing()
{
	if (confirm("Are you 

Open in new window

0
I am trying to integrate crysta reports into my c#  Application

I have visual studio 17 installed  and i have downloaded crystal reports  from SAP site and i am trying to follow

the instructions below:

EDIT: " To add Crystal Reports to Visual Studio you will first need to download the runtime from SAP. Most commom runtimes can be found here. Then you will have to add the CR to your toolbox in VS by choosing Tools -> choose Toolbox items. Make sure the .NET Frameworks Components tab is selected and scroll to the CrystalReport items. Check the items you want to add (CrystalReportViewer for sure) and click OK. After that the CR Viewer should be available to you in the Reporting section of your toolbox."

I just can not find where to add  Crystal Report Item ( in particular CrystalReportViewer  )

Below please find the screen where I am surpposed  to be adding CrystalReportViewer  from

Screen to Bring CrystalReportViewer into my ToolBox
It is  not Listed

How do i get CrystalReportViewer into my Visual Studio 17

Thanks

Olukay
0
How do I use Windows PowerShell to kill IIS Express 10.0?  Is this doable?
0
I have a 2008DC that I need to decommission.  I shut it down just to make sure it wouldn't cause any problems when I remove it and when I did that I had one developer that had issues logging in to any of the servers he normally accesses with his credentials.  He also couldn't access any of his mappings for Microsoft Visual Studio.  I'm not really sure where to start troubleshooting this issue
0
I followed the instructions to create an offline network installer for Visual Studio 2019 Enterprise.  I have tried everything I can think of to get it to install from that cache, but it just keeps using the downloader.  The command I am running is:

vs_enterprise__142530824.1536088995.exe --all --quiet --wait --norestart

The instructions mentioned something about using the layout, but the install layout command doesn't actually seem to have an installer which is super odd.  Just looks the same as the command to create the offline cache.  Any assistance would be greatly appreciated so I can stop downloading 50gb of data for each client install.  Thank you!
0
I am trying to fill a combo Box with a list of items from a SQLite DB.
have been using/following with this https://docs.microsoft.com/en-us/windows/uwp/data-access/sqlite-databases#choose-an-abstraction-layer

SO in my
DataAcsess.cs Class i have
 public static List<String> ProductList()
        {

            List<String> entries = new List<string>();

            using (SqliteConnection db =
                new SqliteConnection("Filename=DataStorage.db"))
            {
                db.Open();

                SqliteCommand selectCommand = new SqliteCommand
                    ("SELECT DOTProductname from QPL", db);

                SqliteDataReader reader = selectCommand.ExecuteReader();

                while (reader.Read())
                {
                    entries.Add(reader.GetString(0));
                }
            
                db.Close();             
              
            }

            return entries;
        }

Open in new window



(which I am not sure what it is doing)

then i have a

I have my XAML:
                    <ComboBox  x:Name="PName" HorizontalContentAlignment="Center" MinWidth="140" ItemsSource="{Binding}">

                    </ComboBox>
           

Open in new window


(not sure how i get the item source to work)

and finally my

XAML.CS code:
            
  private void ProductList(object sender, RoutedEventArgs e)
        {
          ComboBox.ItemsSource = DataAccess.ProductList();
        }

Open in new window


Which is throwing some errors because i am not understanding what is required.

How is the standard method to get the query convert it to a item
and then put a foreach item loop to add to my combo box or similar?
appreciate your help in advance.
0
I'm programming in c under windows with Microsoft's Visual Studio Code.
I have Codeblock installed as well, and have it's gcc command included in windows path.
Long story short, what I do meantime to execute programs is:
Ctrl+F5 which gives a long message that goes like this:
& 'c:\Users\Anwar\.vscode\extensions\ms-vscode.cpptools-0.25.0\debugAdapters\bin\WindowsDebugLauncher.exe' '--stdin=Microsoft-MIEngine-In-witzbclx.4c0' '--stdout=Microsoft-MIEngine-Out-yg1o05v5.ghu' '--stderr=Microsoft-MIEngine-Error-x2zlssey.ouy' '--pid=Microsoft-MIEngine-Pid-i0pwaoju.tda' '--dbgExe=C://Program Files (x86)//CodeBlocks//MinGW//bin//gdb32.exe' '--interpreter=mi'
Then I type in shell terminal:
gcc main.c
.\main
and the program runs.

I'm looking for how to update launch.json or which ever file to make the whole process automatic like a normal programming environment.
Meaning, I need t ohit Ctrl+F5 for the program to simply run in the terminal, like I once had.


Thank you for your help.
0
I get the following error:
'd3' is undefined
The Visual Studio 2017 debugger stops on the file, nv.d3.min.js on this segment:
e.dispatch=d3.dispatch("render_start","render_end")

Open in new window

The error occurs right after this line of code in my _Layout.cshtml file:
 @RenderSection("scripts", required: false)

Open in new window

The d3 files referenced on the _Layout.cshtml file were these:
<script src="https://rawgit.com/mbostock/d3/master/d3.min.js"></script>
<script src="https://rawgit.com/novus/nvd3/v1.1.15-beta/nv.d3.min.js"></script>
<script src="https://rawgit.com/krispo/angular-nvd3/v0.1.1/dist/angular-nvd3.js"></script>

Open in new window

I noticed that one of them was a beta version so I changed it to this:
    <script src="https://cdnjs.cloudflare.com/ajax/libs/d3/1.29.5/d3.js"></script>
    <script src="https://cdnjs.cloudflare.com/ajax/libs/d3/1.29.5/d3.min.js"></script>
    <script src="https://cdnjs.cloudflare.com/ajax/libs/angular-nvd3/1.0.9/angular-nvd3.min.js"></script>

Open in new window

But then I started getting bootstrap errors like this one in my angular.js [dynamic] file :
Unhandled exception at line 1290, column 7 in https://ajax.googleapis.com/ajax/libs/angularjs/1.2.8/angular.js
0x800a139e - JavaScript runtime error: [ng:btstrpd] App Already Bootstrapped with this Element '<div class="col-lg-12 ng-scope" ng-controller="summaryCtrl" ng-app="surveyApp">'
http://errors.angularjs.org/1.2.8/ng/btstrpd?p0=%3Cdiv%20class%3D%22col-lg-12%20ng-scope%22%20ng-controller%3D%22summaryCtrl%22%20ng-app%3D%22surveyApp%22%3E occurred
That happens in this area of code:
function bootstrap(element, modules) {
  var doBootstrap = function() {
    element = jqLite(element);

    if (element.injector()) {
      var tag = (element[0] === document) ? 'document' : startingTag(element);
      throw ngMinErr('btstrpd', "App Already Bootstrapped with this Element '{0}'", tag);
    }

Open in new window

I'm not sure if changing the CDN source of the d3.js files caused that because of incompatibility or if there is a different reason. I think that at this point, since I don't know what I'm doing, the more I try to fix it, the more I'm going to break it.
I did not create this app. I inherited it from a programmer that is no longer available.
0
Should you be charging more for IT Services?
Should you be charging more for IT Services?

Do you wonder if your IT business is truly profitable or if you should raise your prices? Learn how to calculate your overhead burden using our free interactive tool and use it to determine the right price for your IT services. Start calculating Now!

Hi EE,

This question is more of a query looking for approaches to resolve the following issue:

The user has an SSRS 2016 report and filters the datasets efficiently with filters they have been given.

However, the user wants to save specific rows within the report to key the data into another system e.g Desktop application. Exporting initial the result set data to XML result is a simple task. My question is can you have a button on the SSRS which launches a subform that asks what rows /columns specifically do you want to save from the resultset in XML format.  Completing the necessary criteria on the subform, SSRS exports the data to the user via a download.  

Is this possible in SSRS if so are there examples out there?

Any links or tips, advice are welcome.

Thank you.
0
THis is a duplicate question that i asked on a reddit subforum.
but without much response.
https://www.reddit.com/r/UWP/comments/cth82z/is_it_just_me_or_is_there_not_1_single_good_guide/

Iv been looking for weeks to find a comparable guide on using a UWP app with SQLite. All the guides i find are either out of date or using nugget packages that no longer exist. or provide super complex methods.

Im using VS 2019 Community

with this: https://www.nuget.org/packages/Microsoft.EntityFrameworkCore.Sqlite/

Trying to connect to a local .DB file

Maybe i am just not googling the correct words?

Does anyone know of a good resource that demonstrates how to connect to a local .DB file submit entry's and retrieve entry's?
0
I've been following this guide: https://blogs.msdn.microsoft.com/appconsult/2018/05/06/using-the-navigationview-in-your-uwp-applications/

I have my Menu items together and they act great!
However when I open the app I am having trouble setting the default view I have made a homepage when the app opens I would like the homepage to display. When using the code line in the guide it throws an exception. Screenshot:Screenshot--57-.pngHere is the code in the guide:
   
       if (item is NavigationViewItem && item.Tag.ToString() == "Home_Page")
          {
                nvTopLevelNav.SelectedItem = item;
                break;
          }
      }

Open in new window


hopefully its something simple i am doing wrong. my homepage location is Views.HomePage

Screenshot of landing page.
Screenshot--71-.png
Full code (abit messy i know):
 MainPage.xaml

<Page
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="using:RussMenu"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    xmlns:Custom="using:Microsoft.Toolkit.Uwp.UI.Controls"
    x:Class="RussMenu.MainPage"
    mc:Ignorable="d"
    Background="{ThemeResource ApplicationPageBackgroundThemeBrush}">

    <Grid>
        <NavigationView x:Name="nvTopLevelNav"
                Loaded="nvTopLevelNav_Loaded"
                

Open in new window

0
Have problem running the integration test on ASP Core 3.0 on my project. Any idea ?

TEST
0
Hi:

I really hate that someone has made it very difficult to create or edit a SQL Reporting Services (SSRS) Report.  In the old days, when I worked with SSRS everyday, I simply used the Business Intelligence Development Studio (BIDS).

Now, you cannot find anything like BIDS in the newer versions of SSRS.  I hate Report Builder and refuse to use it.

Last week, I followed instructions found online and installed Visual Studio Tools.  And, I asked the IT department to reboot the SQL box late at night.  This was all in an effort to find the latest equivalent of BIDS.

But, I cannot find this.

What in the world do I use and how do I find it?

Please help!  I can't believe that this tool has been buried, in the newer version of SSRS.  

Thank you!  Much appreciated!

John
0
Warning! Installation of Microsoft Visual C++ 2013 (x64) runtime failed due to error 1603.
This message appeared during the installation of Adobe Acrobat DC  version 2015.
I already ran SFC /scannow and a number of issues were found but were never resolved.

The DISM command did not find any issues.
Windows 10 version 1809
My next course of action is to run SFC /scannow  in Safe Mode
 Any suggestion?
0
Hi Experts,

We have an EDM in our c# app, and we use FileStream/FileTable technology to store documents (Word, PDF, etc.).  We have a database with only 2 filetable tables to make the job. (other data are stored in a second classical db).

One of our db in production was in "Recovery pending status" today, we see a lot of reasons and workaround to fix it.

For this time, we need to detach an reattach it, but it is not satisfactory for us, we want to know why and avoid this issue.

For information and for different reasons, our application needs to open an Office doc (word / excel) from c# and we use the Filetable share directory like \\serveur\instance\FS for that.
A strong constraint is that the user can open the document and save it transparently.

Our questions are:
1. At the moment where the db is in "Recovery pending status", are there any tools or SQL statement to help us to understand the reason?
2. Is there a daily check to be done regularly on the databases to prevent these issues?
3. Of course, this db contains about 50GB to 300GB and important documents, is there a risk of losing the data?
4. What are the usual tools to repair, for example: if we detach the db and we cannot reattach it, what to do?

Thanks a lot for your Help.

With kind regards
Herve
0
Hello Experts,
I would like to be able to send emails from my own application
not depending from google gmail or nothing...
just my app sending the email

Is this possible, and if there is an example?
Right now using visual studio basic and visual c#
But we could use anything you suggest.
 As long as it gives us the control and we do not depend on third party services.

the thing is gmail automatically block itself if not used constantly and also present different challenges that change constantly.
Regards!

Just wanted to add that right now our apps send emails programatically using gmail services,
so we want to get rid of that dependance...
Thank you
0
I am opening excel workbooks using visual studio 2015. encountered this error during runtime.error-0x80029C4A.png
0
C++ 11 Fundamentals
LVL 13
C++ 11 Fundamentals

This course will introduce you to C++ 11 and teach you about syntax fundamentals.

I have downloaded Visual Studio 2017 community edition and want to download visual studio 2019.
Should I uninstall VS 2017 first?
0
Hi

The object of my exercise is to learn Entity Framework most of the time I will have created a Database already

I'm using Visual Studio 2019 the tutorials I've found are based on 2017

I've given up trying to connect to an SQLite database as steps  outlined here suggest SQLite isn't compatible with VS 2019


So I  dumped the Database to an SQL file this has both table structure  and data but no database creation

Can someone tell me how to create a Microsoft Server Database and import this SQL file

I then would like to know how to create a DB connection class s  I can use it in different applications
0
Hi,

When, in Visual Studio Code, I need to run a PS1, I obviously need to go (in the VSCode Powershell console) to the path of the file first.
F.e. path is c:\whateverfolder\folder\folder\anotherfolder\scripts\main.ps1
What I do is, select file, right mouse, "copy path", then copy path, paste it into the console remove the filename, and cd to it
=> cd c:\whateverfolder\folder\folder\anotherfolder\scripts\

There has to be an easier way right? Isn't there an option to "go to parent path of file"?
GoToParentPath.png
Please advise,
J
0
Within Visual Studio 2019 where do you set the icon to be displayed next to the app name in Apps & Features?
0
Hi
I'm using MS Visual Studio 2019!

working through 20483-Programming-in-C-Sharp training course I'm at Module 7: Accessing a Database
and looking at the demo from here

@step 9 "Add New Item – FourthCoffee.Employees dialog box click ADO.NET Entity Data Model, "  I don't see this  searching "ADO" or "Entity" finds ZERO

I thought I might need a Nuget package   so Search for ADO and installed EntityFramework 6.2.0  resulting in Errors

Severity      Code      Description      Project      File      Line      Suppression State
Message      IDE0060      Remove unused parameter 'args'      FourthCoffee.Employees      E:\VB\20483-Programming-in-C-Sharp-master\Allfiles\Mod07\Democode\Demo1\Starter\FourthCoffee.Employees\FourthCoffee.Employees\Program.cs      7      Active
AND

Severity      Code      Description      Project      File      Line      Suppression State
Warning      NU1701      Package 'EntityFramework 6.2.0' was restored using '.NETFramework,Version=v4.6.1' instead of the project target framework '.NETCoreApp,Version=v2.1'. This package may not be fully compatible with your project.      FourthCoffee.Employees      E:\VB\20483-Programming-in-C-Sharp-master\Allfiles\Mod07\Democode\Demo1\Starter\FourthCoffee.Employees\FourthCoffee.Employees\FourthCoffee.Employees.csproj      1      

Any suggestion where to find ADO.NET Entity Data Model as I can't proceed to the course exercise as this is doing similar

BTW: If you attempt this @  1 copy the FourthCoffee.sql file to "C:\Users\User.Name" before running SetupFourthCoffeeDB.cmd.
0
I am using Visual Studio 2019 to develop an ASP.Net web API. In an API controller that provides data to user, I used HttpContext.Current.Application.Contents to work as data cache between different requests and different routes. The motivation of using HttpContext.Current.Application.Contents is to cache the data fetch/computed in previously incoming request. In most of the requests the API will just get data from HttpContext.Current.Application.Contents instead of fetching them from back-end, but in some requests the cache data will be cleaned up or initialized. Because multiple requests can be handled at the same time, how can I avoid race condition on using HttpContext.Current.Application.Contents?

Thank you!
0

Microsoft Visual Studio

Microsoft Visual Studio is an integrated development environment (IDE) from Microsoft. It is used to develop computer programs for Microsoft Windows, as well as web sites, web applications and web services. Visual Studio uses Microsoft software development platforms such as Windows API, Windows Forms, Windows Presentation Foundation, Windows Store and Microsoft Silverlight. It can produce both native code and managed code.