Click here to Skip to main content
15,911,039 members
Home / Discussions / WPF
   

WPF

 
QuestionWrapping a WPF GUI component to use it with a HID different than mouse? Pin
Member 367304824-Jun-08 7:07
Member 367304824-Jun-08 7:07 
QuestionMaking Refresh on Viewport3D Pin
sondos0123-Jun-08 23:46
sondos0123-Jun-08 23:46 
QuestionLoading DWF/DXF/DWG file Pin
Member 384581521-Jun-08 0:15
Member 384581521-Jun-08 0:15 
AnswerRe: Loading DWF/DXF/DWG file Pin
Pete O'Hanlon21-Jun-08 0:51
mvePete O'Hanlon21-Jun-08 0:51 
AnswerRe: Loading DWF/DXF/DWG file Pin
wout de zeeuw1-May-11 10:37
wout de zeeuw1-May-11 10:37 
QuestionSingleInstance Application Pin
Jammer20-Jun-08 9:21
Jammer20-Jun-08 9:21 
AnswerRe: SingleInstance Application Pin
Pete O'Hanlon20-Jun-08 9:44
mvePete O'Hanlon20-Jun-08 9:44 
QuestionRe: SingleInstance Application [modified] Pin
Jammer20-Jun-08 12:25
Jammer20-Jun-08 12:25 
Hi Pete,

Thanks for this. I just popped off and made a StartUpObject.cs file and popped this code in there, then I changed the properties as you describe and the rest of my Presentation Layer UI stuff is blowing up. Popping this code into the App.xaml.cs is telling me that there is already a Main with the same parameter types. Should I be using the 'normal' App.xaml.cs or should I be creating a XAML file to go with my new StartUpObject.cs file?

EDIT:

Ok, I found some more info on the net and have done this but i'm now seeing binding errors so this isn't a good solution either:

Removed the StartUpUri="" from App.xaml and added this to my App.xaml.cs:

public partial class App : Application
{
    private static bool mutexIsNew;

    public App() : base()
    {
        using (Mutex m = new Mutex(true, "MyApp", out mutexIsNew))
        {
            if (mutexIsNew)
            {
                AppMainWindow mainwindow = new AppMainWindow();
                mainwindow.Show();
            }
            else
            {
                App.Current.Shutdown();
            }
        }
    }
}


Sorry for not getting this yet pete ...

Cheers,

Jammer

Going where everyone here has gone before! Smile | :)
My Blog

modified on Friday, June 20, 2008 6:37 PM

AnswerRe: SingleInstance Application Pin
Pete O'Hanlon21-Jun-08 0:49
mvePete O'Hanlon21-Jun-08 0:49 
GeneralRe: SingleInstance Application Pin
Jammer21-Jun-08 7:06
Jammer21-Jun-08 7:06 
GeneralRe: SingleInstance Application Pin
Pete O'Hanlon22-Jun-08 8:39
mvePete O'Hanlon22-Jun-08 8:39 
GeneralRe: SingleInstance Application Pin
Jammer22-Jun-08 23:43
Jammer22-Jun-08 23:43 
GeneralRe: SingleInstance Application Pin
Pete O'Hanlon23-Jun-08 0:02
mvePete O'Hanlon23-Jun-08 0:02 
GeneralRe: SingleInstance Application Pin
Jammer23-Jun-08 0:41
Jammer23-Jun-08 0:41 
GeneralRe: SingleInstance Application Pin
Jammer20-Jun-08 13:20
Jammer20-Jun-08 13:20 
AnswerRe: SingleInstance Application Pin
RNEELY27-Jun-08 7:43
RNEELY27-Jun-08 7:43 
QuestionBrain hits wall - WPF Help Please Pin
Rei Roldan19-Jun-08 7:54
Rei Roldan19-Jun-08 7:54 
AnswerRe: Brain hits wall - WPF Help Please Pin
Gideon Engelberth19-Jun-08 10:12
Gideon Engelberth19-Jun-08 10:12 
GeneralRe: Brain hits wall - WPF Help Please Pin
Rei Roldan19-Jun-08 10:21
Rei Roldan19-Jun-08 10:21 
GeneralRe: Brain hits wall - WPF Help Please Pin
Paul Conrad21-Jun-08 4:05
professionalPaul Conrad21-Jun-08 4:05 
QuestionWPF Navigation Pin
BlitzPackage18-Jun-08 8:44
BlitzPackage18-Jun-08 8:44 
AnswerRe: WPF Navigation Pin
Pete O'Hanlon18-Jun-08 8:52
mvePete O'Hanlon18-Jun-08 8:52 
GeneralRe: WPF Navigation Pin
BlitzPackage18-Jun-08 9:00
BlitzPackage18-Jun-08 9:00 
GeneralRe: WPF Navigation Pin
Pete O'Hanlon18-Jun-08 9:11
mvePete O'Hanlon18-Jun-08 9:11 
GeneralRe: WPF Navigation Pin
BlitzPackage19-Jun-08 11:59
BlitzPackage19-Jun-08 11:59 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.