Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
B

Bekjong

@Bekjong
About
Posts
209
Topics
26
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • Overriding OnMouseWheel
    B Bekjong

    Was surprised to see a reply to a 4 year old question that I didn't remember I asked in my inbox :). Thanks for the answer. Perhaps the problem has been haunting my subconsciousness for 4 years and is finally at peace ;). More likely I found a way around it back then though. Still; others may find your answer very useful, thanks again.

    Standards are great! Everybody should have one!

    C# question

  • C# Button Click for UART
    B Bekjong

    John-EE wrote:

    I do not get any errors or warnings so I am thinking it should.

    It would be nice if not getting compile time errors or warnings meant that something would work. The code you provided here doesn't look like it'll send anything out of the serial port. If it did, it would use the SerialPort.Write method. Take a look at msdn for details and examples.

    Standards are great! Everybody should have one!

    C# csharp hardware workspace

  • Simulate keypress
    B Bekjong

    roguemat wrote:

    I also cannot bring that application to the foreground(voiding the use of sendkeys).

    Not sure if this is any help, but: Have you thought about bringing it to the foreground outside of the visible desktop area? You could bring the window up at -1000, -1000 (and make sure it's window size doesn't exceed that of course), use SendKey and put it back to its original position. May not be very elegant, but it should work.

    Standards are great! Everybody should have one!

    C# question

  • Managed and Unmanaged code
    B Bekjong

    This looks ok. Or you can just try Wikipedia and the references in the bottom of the page.

    Standards are great! Everybody should have one!

    C# question

  • Problem with AutoResetEvent Array and WaitHandle.WaitAll()
    B Bekjong

    Use Google. The first hit that comes up already provides a solution:

    private void WaitAll(WaitHandle[] waitHandles) {
    if (Thread.CurrentThread.ApartmentState == ApartmentState.STA) {
    // WaitAll for multiple handles on an STA thread is not supported.
    // ...so wait on each handle individually.
    foreach(WaitHandle myWaitHandle in waitHandles) {
    WaitHandle.WaitAny(new WaitHandle[]{myWaitHandle});
    }
    }
    else {
    WaitHandle.WaitAll(waitHandles);
    }
    }

    Standards are great! Everybody should have one!

    C# help data-structures

  • Keep from erasing working code in a project
    B Bekjong

    If you use a source control solution you'll be able to "commit" your working code. If you then decide to remove the "delete" button and change your mind on that, you can simply put back the old code using you source control program and the button will be there again. I have no idea what it is that you want to delete, but if you need to duplicate the function of your delete button you can just copy the code in the event handler for it's click event to the place you need it to be. If this concept is unclear you might want to pick up a book on c# as this is very very basic stuff.

    Standards are great! Everybody should have one!

    C# csharp question learning

  • a puzzle for timing method
    B Bekjong

    dragon_yue wrote:

    I got this question need to answer, it is simple, just something confused to me. hope anyone can help me. btw, what "The class should fit in more or less transparently with existing clients of the IncDec interface. " means?

    I suppose your teacher (this is homework, right?) means to give you a hint. If you create a new class that inherits MyIncDec and call the base classes methods, you can use this class instead of the orignal and have a place to put your performance timing code without disturbing MyIncDec's existing users.

    Standards are great! Everybody should have one!

    C# question css help

  • Rendering application in inverse (negative) colors
    B Bekjong
    1. Yes. Fortunately, there is more work to do. If this is something I can fix for this specific customer quickly I'll do it. If not, that's just a shame for this customer, who already bought product knowing this isn't a feature. Trying to fix it for the guy is just a matter of service. My employers won't make any money on it, they will if I work on something else. 1) No and no. You're assuming I wrote all this software myself and you're assuming this would be a reasonable software requirement for this product, which could hardly be less false. Please stop assuming.

    Standards are great! Everybody should have one!

    C# csharp winforms design sales question

  • Rendering application in inverse (negative) colors
    B Bekjong

    I don't think it will work by putting new controls over old ones, but you did bring me to an idea: I could use reflection to find all controls in my app, then find each field of type Color and invert it. That might do the trick. Think it will work? Thanks for the inspiration.

    Standards are great! Everybody should have one!

    C# csharp winforms design sales question

  • Rendering application in inverse (negative) colors
    B Bekjong

    Unfortunately, the good people who designed this application in all their wisdom thought it would be better to just set the colors from the designer. So no, I just have a bunch rgb values in doc file defining what colors should be used where.

    Standards are great! Everybody should have one!

    C# csharp winforms design sales question

  • Rendering application in inverse (negative) colors
    B Bekjong

    I did find these, but I don't see how this helps the overall contrast of my app, since (aside from window captions and border colors) these colors aren't used in my application. Besides, changing these colors means changing the windows overall color scheme, which is not something I want to do to my customers. Thanks again.

    Standards are great! Everybody should have one!

    C# csharp winforms design sales question

  • Rendering application in inverse (negative) colors
    B Bekjong

    It's Forms. Thanks again.

    Standards are great! Everybody should have one!

    C# csharp winforms design sales question

  • Rendering application in inverse (negative) colors
    B Bekjong

    Yep, I realize that, but as I said, that will be loads and loads of work for this app.

    Standards are great! Everybody should have one!

    C# csharp winforms design sales question

  • Rendering application in inverse (negative) colors
    B Bekjong

    Tried this, but this only influences the system color pallet, which means it won't work for my app (which uses a custom pallet). Thanks anyway.

    Standards are great! Everybody should have one!

    C# csharp winforms design sales question

  • Rendering application in inverse (negative) colors
    B Bekjong

    Thanks, but that's not really what I meant, I just wanted to set high contrast colors for a single app. Besides, I'm not using the default system color panel, so this won't work with my application.

    Standards are great! Everybody should have one!

    C# csharp winforms design sales question

  • Rendering application in inverse (negative) colors
    B Bekjong

    Hi all, I recently got the request from a customer to implement an inverse colored version of our winforms application to enhance contrast when using it outdoors. Since the application is quite large implementing this over the whole user interface would be a lot of work. Does anyone know if there's a general system setting I can use to make the application render everything in foto negative colors? I haven't been able to find one, probably because it doesn't exist, but maybe I'm missing something. Thanks in advance. Standards are great! Everybody should have one!

    C# csharp winforms design sales question

  • Executing delegate in a different thread
    B Bekjong

    That would work for a windows forms based API, and although I don't know the Autocad API either I wouldn't expect it to be Forms based. A better bet might be to implement a producer/consumer type of architecture[^].

    Standards are great! Everybody should have one!

    C# help question csharp sysadmin

  • StringBuilder ' escape sequence
    B Bekjong

    StringBuilder sb = new StringBuilder(@"LastName = 'O'Brien'");

    Standards are great! Everybody should have one!

    C# help question

  • Spontaneous application startup
    B Bekjong

    Nope, no exe files in my solution. Haven't been able to even find someone with the same problem on the net and have been searching all day. This must be the weirdest problem I ever had.

    Standards are great! Everybody should have one!

    C# csharp visual-studio debugging help question

  • Spontaneous application startup
    B Bekjong

    Hi, Hope this is the right place to ask, I have the following problem: I have a .Net 2.0 Forms/C# solution in visual studio 2005, running on windows Vista Ultimate (both fully up to date with patches). When I open up VS2005 and select the project from the VS Start page, weird stuff starts to happen: While loading the project, VS decides to spontaneously start up the application (without me having touched any buttons). I can't stop the program once it's running from the IDE: shift-F5 and the debug menu don't work. But as soon as I close my app manually, Visual Studio sometimes crashes immediately. This happens about a third of the times I open my Visual Studio project. But if it doesn't, there's always a chance of it happening at some random time while I'm happily coding about: My project will just start to run spontaneously: No compiling or anything, just running the version I last compiled. I've had this VS installation for over a year now, never had any problems with it. The problem only seems to occur with one specific solution: I don't have it with any other solutions I made. Any advice?

    Standards are great! Everybody should have one!

    C# csharp visual-studio debugging help question
  • Login

  • Don't have an account? Register

  • Login or register to search.
  • First post
    Last post
0
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups