Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9198747
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T22:21:38+00:00 2026-06-17T22:21:38+00:00

Stupidly, I deleted my App.xml and App.xml.cs files by mistake. I am able to

  • 0

Stupidly, I deleted my App.xml and App.xml.cs files by mistake.

I am able to recreate these files as I use source control (a bit out of date, regrettably), however when I recreate these files and add them back into my project, VS cannot build the project because I’m informed I don’t have an entry point.

My workaround is to create a loading class with a ‘Main’ keyword for application entry and associate is with the project, however what is the correct procedure for recreating and re-associating my App.xml and App.xml.cs files in VS in my project.

Many thanks.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-17T22:21:39+00:00Added an answer on June 17, 2026 at 10:21 pm

    Your question intrigued me, so I created a new project and blew away the App.xaml and App.xaml.cs files. I then added a window to the project and changed its Build Action in the File Properties editor to ApplicationDefinition from Page, I then changed the xaml and the xaml.cs files to the Application Class. After which it worked correctly.

    i.e.

    App.xaml

    <Application x:Class="WpfApplication1.App"
            xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
            xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
            StartupUri="MainWindow.xaml">
        <Application.Resources>
    
        </Application.Resources>
    </Application>
    

    App.xaml.cs

    using System;
    using System.Collections.Generic;
    using System.Configuration;
    using System.Data;
    using System.Linq;
    using System.Windows;
    
    
    namespace WpfApplication1
    {
        /// <summary>
        /// Interaction logic for App.xaml
        /// </summary>
        public partial class App : Application 
        {
    
        }
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

this may be stupidly simple but I'm trying to figure out a way to
My OOB app was working fine. I stupidly renamed all my namespaces and my
This seems so stupidly simple, but I can't figure it out. I'd like to
Python rather stupidly has a pragma directive in its include files that forces a
I've just launched a new iPhone app and stupidly built it for 3.1.3 only
Stupidly, I have sent out a newsletter without checking the links. One of which
I rather stupidly removed an app on iTunes Connect, thinking I could re-create it
I just had my app rejected, stupidly i uploaded a new version before I
I wanted to use a switch function in my app from a string. When
Ok this is how stupidly i am keeping my date as string 23.12.2012 21:24:31

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.