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
G

Gavin Coates

@Gavin Coates
About
Posts
10
Topics
4
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • C# Integrating With Skype
    G Gavin Coates

    Except no-where on that page does it tell me how to integrate a C# application with skype. I don't want to create a bot, accept payments, conduct interviews or add call links to my web app. I want to detect incoming calls on skype, and flash up additional data on the users screen. And to clarify, I'm talking *desktop* application, not mobile.

    C# csharp business sales json question

  • C# Integrating With Skype
    G Gavin Coates

    I am in the process of creating an intranet system for a local business. This system will contain a custom CRM, as well as various other components essential to the customers business. They will shortly be switching their phone system to Skype. We would like to develop a C# desktop app that talks with the skype application to detect when a phone call comes in, then flashes up various information for the user - such as customer name and account status. Is there an API that will allow us to do this?

    C# csharp business sales json question

  • Code First, do you like it?
    G Gavin Coates

    But how many times has someone updated one, and forgot to update the other? At least with auto-generation, you're one click away from regenerating. With code first, you need to sit down and verify every recent change to ensure it has been incorporated.

    The Lounge database question

  • Website And Service Using Real Time Data Feed
    G Gavin Coates

    I am about to start developing a new website, and I am a little stuck as to the correct architecture to use to achieve what I need. I have been given access to a data feed, which provides me with live, real time data. I need to cache this data and do some processing on it, and I can only create one connection to this service - it will block any subsequent attempts from the same IP. Therefore directly connecting via a website is not going to be feasible. It looks like I will need to create two separate parts to this project - a back end service that retrieves the data and performs any processing required, then a separate website that accesses the processed data. As the data is real time - the ability to update the web page in real time would also be desirable. As well as this, I also anticipate adding a few mobile apps in future, which will also need to connect to the back end system. Does anyone have any suggestions on what technologies to use? Obviously Json would be ideal for the inter-process communications, but what kind of back end technologies can I use that easily supports json while still allowing a persistent service that can maintain a permanent connection to the data source? Anyway, i'm rambling a bit. I hope it's clear, and I look forward to people's advice.

    Design and Architecture json architecture help question announcement

  • Win7 No PingCompletedCallback on timeout?
    G Gavin Coates

    Hey guys, I wrote a network scanning tool a few years ago, which pings a list of IP addresses. I recently moved to Windows 7, and have noticed some strange behaviour in the program. My ping code is as follows:

    public void pingIP(int IP)
    {
    AutoResetEvent waiter = new AutoResetEvent (false);
    string IPaddress = IPpart1.Value.ToString() + "." + IPpart2.Value.ToString() + "." + IPpart3.Value.ToString() + "." + IP;
    IPAddress IPa = IPAddress.Parse(IPaddress);

            Debug.WriteLine("Pinging " + IP.ToString());
            
            Ping ping = new Ping();
            ping.PingCompleted += new PingCompletedEventHandler(PingCompletedCallback);
    
            ping.SendAsync(IPa, waiter);
            
        }
    

    This then calls PingCompletedCallback when it recieves a response:

    public void PingCompletedCallback(object sender, PingCompletedEventArgs e)
    {

            PingReply reply = e.Reply;
                // get the IP that was pinged
                string IP = reply.Address.ToString();
                
                if(IP != "0.0.0.0")
                {
                    string\[\] IParray = IP.Split('.');
                    int iIP = Int32.Parse(IParray\[3\]);
                    if (reply.Status == IPStatus.Success)
                        pingResult\[iIP\] = reply.RoundtripTime.ToString();
                    else
                        pingResult\[iIP\] = "X";
                
                    Debug.WriteLine("Ping Reply From " + IP.ToString() + " Time: " + pingResult\[iIP\]);
    
                    // check if the last ping (255) has been reveived and mark the ping complete flag if so
                    if (iIP == 255)
                    {
                        pingComplete = true;
                        lblStatus.Text = "Ping Complete";
                    }
                }
                
                
                
            ((AutoResetEvent)e.UserState).Set();
        }
    

    Now, under Windows XP this worked fine, PingCompletedCallback was called for every ping I sent - either with a response, or with a timeout. I could then set the value as required. However, under Win7, PingCompletedCallback only seems to be called when a successful response is received. I have also noticed I recieve a lot of replies from "0.0.0.0", as well as multiple replies from the IP the machine is running on (10.0.0.4) I have a second screen for doing a detailed ping on a single IP, which doesnt use a call

    C# sysadmin debugging question

  • XML Serializer Help
    G Gavin Coates

    Sorry, forgot to tell it not to treat barckets as HTML. Here is the actual XML that is recieved by the client: 2 1 1

    C# help sysadmin xml question

  • Listbox deleting items
    G Gavin Coates

    ggthanks thomasa. I tried the code above, but again i get exactly the same results! I can delete any item in the listbox no problems, but when i try to delete the first item, it deletes, but causes an IndexOutOfRangeException!! I tried creating a whole new project with just a listbox, textbox add and delete button, and it worked perfectly, no errors at all. It just causes problems in my current project!!! Please help!

    C# help question

  • Listbox deleting items
    G Gavin Coates

    error is: "Index was outside the bounds of the array"

    C# help question

  • Listbox deleting items
    G Gavin Coates

    i just get an "IndexOutOfRangeException" occuring. Im using Borland C# if thats any help?

    C# help question

  • Listbox deleting items
    G Gavin Coates

    I seem to be encountering difficulty while trying to delete an item from a listbox. The user selects an item from the listbox, then clicks a delete button. The button code is as follows: try { listBox1.Items.Remove(listBox1.SelectedItem); } catch(IndexOutOfRangeException ex) { MessageBox.Show("Could not delete the selected item", "Error", MessageBoxButtons.OK); } Now, if I select the first item in the list, and press delete, the exception IndexOutOfRange occurs, however the item is then successfully deleted. If I select any other item in the list and try to delete it, it works fine, no exception Why does deleting the first item cause an exception

    C# 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