Windows azure application developing step failed - c#

This is my first time trying to develop a windows azure application on my visual studio 2010.
what I have done so far is:
Open new project > C# > Cloud.
Downloaded the SDK.
Add new class with code that only displays my name and age.
try to run this code locally and failed!
My questions is:
am I able to run the application locally? if yes the how?
How can I deploy the application? (I already have an account)

Well for what I see your problem is not your windows azure sdk, the thing is that you are creating a WorkerRole project which is a Class Library type and that won't give you an output, for that you need to create a WebRole project.
here I let you this tutorial, it would show you how to create your first WebRole project.
http://www.dotnetcurry.com/ShowArticle.aspx?ID=801
And this one would show you how to deploy on the cloud
http://www.developerfusion.com/article/125435/deploying-an-azure-application

What type of application are you trying to build? Your error is because you are trying to run a class library, which isn't an executable.
There are primarily two types of applications that are hosted in Azure:
Website - These are just standard ASP.NET WebForms or MVC projects, hosted on Azure. These are the easiest to get going, and with the latest Azure release, require nothing special. Simply create a Web project, and git deploy to your Azure Web Site
Worker Role - Worker roles are usually for background tasks like performing computations, sending emails, distributing work, etc. These can effectively be thought of as console applications that never end.
For example:
while(true)
{
// do work here
Thread.Sleep(5000);
}
When developing Azure applications, you need to either create a website (WebForms, MVC, WebAPI), a WCF service, or a console application to run as a background worker. Once you've built the application locally, then you can add an Azure Cloud project, which will handle the actual deployments.

Yes, you can run your application locally: Select the Azure application project in the Solution Explorer, right click, "Set as StartupUp Project" and run
To Publish: goto https://manage.windowsazure.com/ . Create a new web role and download the publishing settings.

Related

C# windows service install with desktop application

I have a wpf desktop application (ERP) system
Application is using setup and deployment to create the .exe file
Now, i want to create a window service for my application to do some background check ups , synchronizations with my database etc.
I know how to create a service in.net and how manually to install it following the examples online.
My question is how i can install (or include let's say) this service within my .exe setup.
I don't want the user to be responsible to install the service.
Neither me to login every time someone pc to install the service
Not sure if i misunderstood the purpose of service but i found nothing online related to my question.
You can use Microsoft Visual Studio Installer Projects and include your service/main project at the same time
https://marketplace.visualstudio.com/items?itemName=VisualStudioClient.MicrosoftVisualStudio2017InstallerProjects

Azure with Xamarin.forms Name resolution Failure

Currently trying to executing Azure with forms TO DO sample application.
When I executing I facing some issues
When I trying to publish the service there is no option for Microsoft Azure App service instead of that I am getting Microsoft Azure web app
After run app (Emulator).when trying to add new record I am getting Name Resolution Failure error
Well... not a lot of details but I will give a try...
Go to your Azure Dashboard and look for your App Service to download the publish profile.
Now, import it on your Visual Studio Project:

How to create exe of a web application in asp.net

I have to create an exe of an website created in asp.net using visual studio 2010.
I don't known whether exe of web application can be created or not, but I want that my application with database will be able to run on another system where visual studio will or will not be there.And my code should not to be visible to the users using that exe or running that project.
How can I achieve it?!
you can't make a exe for web application but you can do one thing to solve your problem
1)make a window project in this project make a code for run iis and open browser with your web application url and make your window application form hide
2) now make exe of your window application project
You cannot create an executable file in asp.net.
All you can do is create a website using visual studio. once done, publish your website. Deploy it to IIS or host it to a paid web hosting company so you can have your domain. Once done, other users can see your beautiful and elegant website.
You don't create exe of a web application. It is hosted on IIS. So first of all you have to publish your website and then you can host it. For more information you can refer to this one:http://msdn.microsoft.com/en-us/library/20yh9f1b%28v=vs.100%29.aspx Or google for more articles.
Posting to an old thread, but I came across this situation and found the solution.
Following footsteps of Spring Boot and other containerized solutions, I believe now Microsoft also has added this feature.
My scenario: Created a basic REST based Web application and built it.
This created Debug and Release folder within \bin within the root directory of Web application.
It also creates an exe file.
You just need the necessary runtime dependencies (like .NetCore 3.1 etc in my case) to run this exe.
I copied the entire Web application folder to a Windows Server 2016. There were some issues initially, however later when I added the required dependencies (dotnet folder which was present in my earlier machine), it worked like a charm.

Transitioning a cloud service from being local to being hosted on Windows Azure

I'm trying to host a very simple database on Azure and going out of my mind doing so. I've managed to get a local service running and communicating with my WP7 app just fine :).
I got this far by following this tutorial:
http://breathingtech.com/2011/how-to-use-wcf-services-to-access-sql-azure-database-from-windows-phone-7-app-part-1/
The tutorial provides steps to publish the service to Azure but my version of Visual Studio (2010 Professional SP1) is different and I can't do the final bit (hosting it on Azure).
When I hit 'publish...' as per the tutorial I get this (what do I do next?):
Can anybody point me in the right direction please?
Well if you want to follow that tutorial, you should right click the project, but instead of choosing Publish you should choose Package. After packaging this will open up a new Explorer window with the 2 files (the package and the cscfg).
Then you can simply go ahead and follow the rest of the tutorial.
Alternatively, you could simply change the environment from Staging to Production in the screen which you display in your question and click publish. This packages the application and deploys it to the selected hosted service (in your case apprehensive3months). If you do this, you won't need to upload the files manually in the portal (as described in the tutorial).

How to determine the location of a Cloud WebRole on Harddisk?

After creating a Azure Project within my silverlight app and adding the existing service as a "Add Web Role Project in Solution" I can run my silverlight app hosted in the Cloud and run it successfully locally.
I would like to use the SDK Toolkit instead of Visual Studio to create a package from the webrole. But what is the correct path to the WebRole?
In order to create a package, you shouldn't need to know where your local role runs. You should only need the service definition file and the binaries/files.
See the cspack cmdline:
http://msdn.microsoft.com/en-us/library/windowsazure/gg433133.aspx
You can also use msbuild to create a package:
http://msdn.microsoft.com/en-us/library/windowsazure/hh301088.aspx
Also, this is a good starting point:
http://msdn.microsoft.com/en-us/library/windowsazure/gg433055.aspx
Let me know if I mis-understood what you're trying to ultimately accomplish.

Categories

Resources