Everybody! This is important. In a few days, these forums will be moving over to using the totally sweet Discourse platform. To ensure this migration happens smoothly with no loss of content, these forums are currently in a read-only mode. I do apologize for the inconvenience.

There is never a good time to turn the forums off for an extended period of time, but I promise the new forums will be a billion times better. I'm pretty sure of it.

See you all on the other side in a few days, and if you have any (non-technical) questions, please e-mail me at kirupa@kirupa.com. For technical questions, try to find a tutorial that corresponds to what you are looking for and post in the comments section of that page.

Cheers,
Kirupa

Results 1 to 10 of 10

Thread: Blend and C#

  1. #1

    Blend and C#

    I dont know if this is possible, but is there a way to create GUIs for programs that i write in Visual C# Express 2008?

    Say i write a program that does bank transactions. I know you can create GUIs using C# System.Forms and stuff, but i just want to know if you can create GUI in Blend and apply it to C# programs. It would be much quicker and look cooler if this is possible.

    Thanks

  2. #2
    Yep - it is definitely possible, but you need to make sure you are creating a WPF application. WinForms is a different (older) UI technology, and Blend only works with the UI (loose XAML files) created in WPF.

    So, you can create a new WPF project in Visual C# 2008 and open (and edit) the same project in Blend, and everything will still work. The way I have my system setup, I have the same project open in both VS and Blend, and I use VS for editing the *.cs file and I use Blend for editing the *.xaml file

    Great, now even Kirupa is { facebooking | twittering }

  3. #3
    I get an error if I create a WPF project in VS C# 2008 and open with Blend :/
    Web Design and Web Development blog
    Designer Notice: Browser List for design compatibility

  4. #4
    Quote Originally Posted by kirupa View Post
    Yep - it is definitely possible, but you need to make sure you are creating a WPF application. WinForms is a different (older) UI technology, and Blend only works with the UI (loose XAML files) created in WPF.

    So, you can create a new WPF project in Visual C# 2008 and open (and edit) the same project in Blend, and everything will still work. The way I have my system setup, I have the same project open in both VS and Blend, and I use VS for editing the *.cs file and I use Blend for editing the *.xaml file
    When i try to open the csproj file, it says "imported project "C:\Microsoft.CSharp.targets" was not found."

    I tried to open the xaml separately, but different error occurs. Any ideas?

  5. #5
    That's weird. If you do the exact opposite where you create a new project in Blend and then open that project in VS/VC#, does it work then?

  6. #6
    Mm hmm. Creating project in blend and i can open the .cs file. Just to make sure, I edit the App.xaml.cs no the AssemblyInfo.cs to write my program right?

  7. #7
    You edit the Window1.xaml.cs in VS

    This tutorial should help you out: http://www.kirupa.com/net/creating_s...ui_app_pg1.htm

    Great, now even Kirupa is { facebooking | twittering }

  8. #8
    So you don't open the project just the .cs?
    Web Design and Web Development blog
    Designer Notice: Browser List for design compatibility

  9. #9
    Yup, you just open the Windows1.xaml.cs file. I just finished that tutorial. It gives u a start.

  10. #10
    You can always right click on a .CS file in Blend and select "Edit Externally", and that will launch Visual C# automatically.

    Great, now even Kirupa is { facebooking | twittering }

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

Home About kirupa.com Meet the Moderators Advertise

 Link to Us

 Credits

Copyright 1999 - 2012