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
Q

quilkin

@quilkin
About
Posts
34
Topics
15
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • Your First Development Machine?
    Q quilkin

    Basic on Sinclair ZX-81 in 1982 (it was released a year late). IK of Ram. Later bought a 16K dongle that kept falling off and losing my work.

    The Lounge com help question learning

  • enum problems with C++
    Q quilkin

    I've been using C# for the last few years but now I have to work with an embedded C++ compiler and am having problems with enum types, since they can't apparently be used in a different class. class Message { public: enum Index { Length,ID1,ID2,ID3,Type,From,To,SourceX,SourceY,Var,Routing,MaxIndex=255 }; .... .... .... } ... ... ... bool Sensor::SendMessage(Message msg) { char message[Message.MaxIndex]; message[Message.ID1] = 'X'; ... ... } This sort of thing works fine in C# but the C++ compiler gives an error when 'Message.MaxIndex' etc is used - it says 'type names cannot be used' (or similar depending on the compiler). Do I really have to make all my enum's global (e.g. 'Message_MaxIndex') or is there a better way?

    C / C++ / MFC csharp c++ database hardware iot

  • finding an SQL server
    Q quilkin

    Many thanks Luis. This looks perfect. And it seems I need to keep up with the times, Google is getting good for this sort of thing.

    Database csharp database sql-server sysadmin question

  • finding an SQL server
    Q quilkin

    Does anyone know of a programmatic way of finding which server(s) may be running, so a new client installation can be provided with a drop-down list of where the data may be held? There will be a defined instance in each case, so all servers to be found will be of the form "machinename\myinstance" - I just need to find possible values for 'machinename'. (pretty much like the facility in Enterprise Manager for finding a new server registration). We are using C# (.NET 2003) but I can translate from other methods if required.

    Database csharp database sql-server sysadmin question

  • Graphics - removing a line
    Q quilkin

    ControlPaint.DrawReversibleLine works fine. A whole new class I didn't know about. Thanks to all.:)

    C# graphics question

  • Graphics - removing a line
    Q quilkin

    David, Is double buffering relevant? In MFC, I used CDC::SetROP2 to get a whole range of options about combining pixels. I'm trying to find the equivalent in .NET. Thanks for replying.

    C# graphics question

  • Graphics - removing a line
    Q quilkin

    Can anyone explain how I can draw a line over an existing image, then later remove it (by redrawing it in some clever way) without having to invalidate and redraw the original image?

    C# graphics question

  • DateTime
    Q quilkin

    We use time.ToString("G", DateTimeFormatInfo.InvariantInfo); and you should also consider using time.ToUniversalTime(); before storing times in the database, to avoid problems with daylight saving.

    C# question

  • TcpClient - waiting for connection
    Q quilkin

    Stefan, Thanks but I think this will only be OK if there is a domain name server to provide a name. This system needs to work on LANs where there may not be one. I guess I'll need to use the asynch StartConnect() method but I need a decent sample to see how to use it.

    C# question

  • TcpClient - waiting for connection
    Q quilkin

    Jeff, I have set both SendTimeout and ReceiveTimeout (to 6000 ms) but they have no effect on starting the connection, only presumably on send/receive data.

    C# question

  • TcpClient - waiting for connection
    Q quilkin

    I am using TcpClient.Connect(ipaddress, portnumber) but the app must 'scan' a few possible IPs before finding the 'active' one. However if 'ipaddress' does not respond, the Connect() function hangs for nearly 60 seconds before raising an exception. Is there any way I can test for an IP quickly (e.g. a 'ping() command) before calling 'Connect()? I don't really want to get into starting separate threads for each possible IP address to search.

    C# question

  • TabPage OnClick
    Q quilkin

    This must have a really easy answer. I have created a tabcontrol and added five pages to it. I added an 'click' event handler to each page. But the event only fires when I click on the main part of the page, not on the tabs (labels) themselves! (The graphical representation of the tabs changes with each click, but my Click handler is never called). Since most of each page is covered with other controls this makes it almost impossible to use. What am I doing wrong? Is there a different click event for the labels?

    C# question

  • Request a new login
    Q quilkin

    Thanks, OK, but is there a way to force the screensaver to come up immediately? I just want to ensure that, when someone presses a 'save' button that changes a database, they immediately get a request for credentials. I don't want to create a new form to capture credentials since there is no way to check the Windows NT password.

    C# csharp

  • Request a new login
    Q quilkin

    I need to programatically bring up the Windows logon dialog. I don't want to find any usernames or passwords, just force the user to re-enter his credentials - this is to prevent unauthorised users from changing settings in the application if the authorised user has walked away from his desk for a few minutes. There must be a simple c# method that does this!

    C# csharp

  • Icon design
    Q quilkin

    What am I doing wrong in creating icons for my app? When a 16x16 icon apppears in the icon tray it appears corrupted (lots of grey splodges) yet the same icon is fine when it appears in a form (or dialog). Are there any tools available for icon design that are better than the Visual Studio tools?

    IT & Infrastructure csharp visual-studio design tools question

  • Updating text in a form while other tasks are happening
    Q quilkin

    Thanks 'Condor', this is a bit top-heavy in terms of code size (compared with what I was expecting!) but I have to admit the result is very nice. I'll use it.

    C# database beta-testing code-review

  • Updating text in a form while other tasks are happening
    Q quilkin

    When my app starts up it needs to spend a few seconds getting data from a database, and structuring tables etc. The user needs to know something is going on while this happens so I made a simple form that gives some feedback e.g."xxx is now loading". Trouble is, the app is so busy loading the data that it never gets the chance to write the text in the form. The title is there, but little else (until the data has finished loading, when the form is not required any more anyway!) - just empty 'holes' which let the underlying screen show through. There must be a simple solution to this but it eludes me.

    C# database beta-testing code-review

  • Vertical text in a DataGrid column header
    Q quilkin

    Is it possible to use a vertical font in the header of a data grid? When the column titles ae longer than the contents of the cells, it seems such a waste of screen space to have wide columns (and not user-friendly to hide most of the titles by having narrow columns). Any ideas welcome!

    C# css question

  • serial port
    Q quilkin

    I agree with Dave, what you're trying to do is pretty impossible. Better to get hold of a development kit for a simple microcontroller (e.g. a Arizona Micro PIC device) that has an on-baord UART and talk to that via your PC serial port. The PIC can be programmed to generate your pulses, etc, depending on the instructions it gets via the serial port.

    C# question csharp html com

  • Help with Windows services
    Q quilkin

    :doh: Of course, I need to 'OpenSubKey()' with write permission. Anyway, could you confirn that the 'CurrentControlSet' is the correct key, and not 'ControlSet001' or 'ControlSet003'. What are these? Having got the service working as I want it, I now cannot stop it programatically.

    System.ServiceProcess.ServiceController sc = new System.ServiceProcess.ServiceController("SpyFive");
    try
    {
    sc.Stop();
    }
    catch
    {
    ....

    there is nothing caught, the service goes into 'stopping' mode and then nothing can be done with it (even from MMC). Any ideas?

    C# csharp help tutorial 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