Skip to content
  • Win Forms, WPF, WinUI 3

    C# question csharp delphi wpf winforms
    3
    0 Votes
    3 Posts
    0 Views
    R
    I started programming before OWL existed (my first IDE was Turbo Pascal for CP/M on an Apple //e back in the early 80's). I went through Pascal (OWL), C++ (MFC), and then C# (WinForms, and currently WPF). I refuse to code for WinUI, simply because I have no desire to learn it. It took me a while to accept WPF (and I fought it HARD), but I find it easy to do (easier than WinForms in a lot of ways). I do all of my design work in the XAML editor (you can drag from the Toolbox pane to the XAML to get a new control on the page, and intellisense guides you when you start changing properties in the XAML, so it's not TOO bad). After two years away from desktop apps, I spent the last weekend doing a WPF version (proof of concept) of our web app from work, and the hardest part was making the app allow the user to adjust font size with Ctrl+ and Ctrl- like a web browser (we have to comply with Section 508 by allowing the font in an application to be increased by up to 200%). A few years ago, I wrote a custom message box library that allows the developer to specify text size and custom colors (among other features), and with a little tweaking, my message boxes use the increased font size. ".45 ACP - because shooting twice is just silly" - JSOP, 2010 ----- You can never have too much ammo - unless you're swimming, or on fire. - JSOP, 2010 ----- When you pry the gun from my cold dead hands, be careful - the barrel will be very hot. - JSOP, 2013
  • Com port c#, windows form

    C# help csharp winforms com
    7
    0 Votes
    7 Posts
    0 Views
    J
    thank you Gerry regards John
  • 0 Votes
    9 Posts
    0 Views
    B
    Graeme_Grant wrote: C1 is still a beta. Not as described by ReSharper :omg: But, I concede this one to you on points since you may be dealing with implanted memories. cheers, bill «The mind is not a vessel to be filled but a fire to be kindled» Plutarch
  • 0 Votes
    5 Posts
    0 Views
    J
    I'm beginning to realize that now. If it ain't broke don't fix it Discover my world at jkirkerx.com
  • web controls in windows forms

    C# csharp wpf html asp-net winforms
    11
    0 Votes
    11 Posts
    0 Views
    Graeme_GrantG
    I've just seen you post, so sorry for the late reply. The answer is yes, you can. Blazor WASM (Web Assembly) enables you to do just that. I have written an article recently that demonstrates this with WPF, however WinForms can do the same. Here is the article: Blazing.Mvvm - Blazor WASM & Blazor Hybrid using the Community Toolkit[^] - ignore the fact that the article focuses on MVVM. The key thing for you, in the article, is not only proof of concept, but also how you can interact with the Blazor part from within your WinForms app and vice versa. IT is made possible by the BlazorWebView control. Microsoft have an article that shows you how to host Blazor within WinForms: Build a Windows Forms Blazor app | Microsoft Learn[^]. Be aware though, to do this, you need to work with .Net 7.0+, not .Net Framework. However, if you need to move from .Net Framework to .Net, then your app will receive an immediate performance boost due to improvements made to .Net - no legacy support. Graeme "I fear not the man who has practiced ten thousand kicks one time, but I fear the man that has practiced one kick ten thousand times!" - Bruce Lee
  • 0 Votes
    6 Posts
    0 Views
    A
    You're welcome.
  • 0 Votes
    15 Posts
    0 Views
    A
    It happens. There have been times when I've made code changes to a wrong file (a copy of the file with the same name, at a backup location), recompiled the project, only to see that nothing has changed in the execution., then debugged for several hours; only to realize later that the file path is different. Must have happened to several members here.
  • VS broke project

    Visual Basic csharp visual-studio winforms question
    3
    0 Votes
    3 Posts
    0 Views
    M
    Hey Dave, You're a lifesaver :) VS had self-added (???) these to the main form: Imports MS.Internal Imports System.Windows.Forms.VisualStyles.VisualStyleElement Libraries in this haven't changed in two years, so I never thought to give this a look. Those two were responsible for all the errors. Where they came from? My only guess is that on Saturday, that computer was in 'update hell'; meaning it had downloaded an update but needed a reboot and I didn't notice it. For unrelated reasons, it runs 24/7. It took three times to get the update flag cleared, and I'm pretty sure I opened the project after the first update said it was done. I should have known better, since I know VS doesn't use the in-memory loaded libraries in update hell, but was doing a few different things on different computers so I missed it. Though in the past, I've never seen it add libraries on its own; it normally throws "missing" errors. Thanks again for the clue. Mike
  • Where did my pictures go?

    Article Writing csharp winforms com question lounge
    7
    0 Votes
    7 Posts
    0 Views
    S
    I always drop all images in the Drop files here box. Sometimes they all publish perfectly. Sometimes they don't. Thanks, Sean Ewington CodeProject
  • closing serialport1 form 1 and form 2

    Windows Forms winforms
    4
    0 Votes
    4 Posts
    5 Views
    Graeme_GrantG
    Your code presented as VB, so I replied in kind. C# works the same with minor variances. Graeme "I fear not the man who has practiced ten thousand kicks one time, but I fear the man that has practiced one kick ten thousand times!" - Bruce Lee
  • 0 Votes
    3 Posts
    0 Views
    O
    Elvis isn't dead. He just went home. - Men in Black
  • 0 Votes
    1 Posts
    0 Views
    No one has replied
  • NetSparkle

    The Lounge csharp dotnet asp-net wpf winforms
    6
    0 Votes
    6 Posts
    0 Views
    K
    Any documentation for this? If it's not broken, fix it until it is. Everything makes sense in someone's mind. Ya can't fix stupid.
  • 0 Votes
    2 Posts
    0 Views
    N
    Kent Sharkey wrote: Fingers crossed that it breaks nothing and it doesn't get an update that breaks it later, once you are done :rolleyes: :laugh: M.D.V. ;) If something has a solution... Why do we have to worry about?. If it has no solution... For what reason do we have to worry about? Help me to understand what I'm saying, and I'll explain it better to you Rating helpful answers is nice, but saying thanks can be even nicer.
  • 0 Votes
    10 Posts
    0 Views
    J
    And some use to read the book and consider themselves an expert. And even more so they would write a book and then proclaim themselves and expert (and force their students to buy it.) The source of the knowledge doesn't matter as long as learning can take place.
  • 0 Votes
    2 Posts
    0 Views
    N
    Kent Sharkey wrote: One UI to rule them all, one UI to find them, one UI to bring them all, and in the darkness command-bind them I have a dejà vóu :rolleyes: :-D M.D.V. ;) If something has a solution... Why do we have to worry about?. If it has no solution... For what reason do we have to worry about? Help me to understand what I'm saying, and I'll explain it better to you Rating helpful answers is nice, but saying thanks can be even nicer.
  • 0 Votes
    5 Posts
    0 Views
    B
    thanks Gsry, Been a long time since i read sci-fi, but J.G. Ballard comes to mind. literary: Percy Shelley ... Ozymandias Borges: ,,, The Library of Babel, Asterion philosophy: the recurrent myth of a "lost paradise:" Rene Dubos"The Mirage of Heakth"cheers, bill history: Lisa Jardine, "Worldly Goods" the profound stimulus to the Renaissance that unique goods from China (silk, porcelain) had, as well as the assimilation of ancient Greek science, geometry, astronomy from the Arabs who had preserved it and developed it much further, «The mind is not a vessel to be filled but a fire to be kindled» Plutarch
  • 0 Votes
    5 Posts
    0 Views
    M
    After a test with loaded (I loaded them from a hdd-drive) 3000x3000 images (Same Datatype) it worked fast and without problems. Too much changes
  • Custom Flat-style Numeric UpDown Control

    The Lounge csharp dotnet winforms com
    13
    0 Votes
    13 Posts
    0 Views
    L
    It sounds complicated but it's just using an "acrylic" Brush (available in UWP) instead of a regular "solid color brush" for the background. The same facility can be added to WPF using the "community tool kit". Or you can fake it varying the opacity of the background of a control ... though the "acrylic" brush seems to be a bit more "glassy". "Before entering on an understanding, I have meditated for a long time, and have foreseen what might happen. It is not genius which reveals to me suddenly, secretly, what I have to say or to do in a circumstance unexpected by other people; it is reflection, it is meditation." - Napoleon I
  • 0 Votes
    3 Posts
    4 Views
    M
    thanks