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
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
D

Darkness84

@Darkness84
About
Posts
28
Topics
14
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • Exception has been thrown by the target of an invocation
    D Darkness84

    I have narrowed it down to an "Overflow or underflow in the arithmetic operation." but I still don't know why.

    C# graphics question

  • Exception has been thrown by the target of an invocation
    D Darkness84

    Sorry forgot to mention I am using Visual Studio 2003 with .NET Framework 1.1

    C# graphics question

  • Exception has been thrown by the target of an invocation
    D Darkness84

    The following line of code: this.lblImportFile.Font = new System.Drawing.Font("Tahoma", 8.25F); is throwing the following exception: {"Exception has been thrown by the target of an invocation." } and I have no idea why. does anybody have any ideas?

    C# graphics question

  • Searching through an ArrayList
    D Darkness84

    Thanks for your help guys. The hash table is the way I'm going to have to go as the application I'm developing is on Framework 1.1 so I can't use a Dictionary.

    C# algorithms tutorial

  • Searching through an ArrayList
    D Darkness84

    I have an arraylist that contains objects who themselves contain multiple properties. I would like to know is there are faster way than using a for loop to search through an arraylist to find the object whose certain property matches what I am looking for. An example of what I am currently doing is listed below. for(int p = 0; p < SupplierItemDataStore.Count; p++) { if(stock.Code == ((XMLDefs.SupplierItem.SupplierItem)SupplierItemDataStore[p]).StockCode) { { //Do stuff here } } } where stock is the object that is passed in and SupplierItemDataStore contains over 31,000 items.

    C# algorithms tutorial

  • Events
    D Darkness84

    I see what I am doing wrong now. Thanks for your help.

    C# question

  • Events
    D Darkness84

    This is the code: protected void btnNext_Clicked(object sender, EventArgs e) { switch (m_teststage) { case "STEP1": hidMode.Value = "STEP2"; break; case "STEP2": hidMode.Value = "STEP3"; break; } m_teststage = hidMode.Value; FormatPageChange(); } private void FormatPageChange() { if (m_teststage == "STEP2") InitialiseDMRGrid(); if (m_teststage == "STEP3") InitialiseTestGrid(); SetPanelVisibility(); SetButtonVisibility(); SetValidatorsEnabled(); } private void InitialiseDMRGrid() { WebGridHelper m_webgridhelperDMR = new WebGridHelper(wgDMR, "", "ID"); wgDMR.PrepareDataBinding += new DataSourceEventHandler(wgDMR_PrepareDataBinding); wgDMR.InitializeDataSource += new DataSourceEventHandler(wgDMR_InitializeDataSource); m_webgridhelperDMR.SortColumns += new SortColumnsEventHandler(m_webgridhelperDMR_SortColumns); wgDMR.InitializePostBack += new PostBackEventHandler(wgDMR_InitializePostBack); } If I click the Next button the event fires but when it gets to the InitialiseDMRGrid method it goes in but does not fire the events inside.

    C# question

  • Events
    D Darkness84

    Is there anything special you have to do to get this to work because the event inside the executing event is not firing?

    C# question

  • Events
    D Darkness84

    Can you fire an event inside of an event that is already executing?

    C# question

  • SqlDependency and Release Build
    D Darkness84

    I've figured out this problem is a result of timing. I have put in some simple for loops just to create delays and the problem has gone away. Now to implement a better solution.....

    C# database debugging help question announcement

  • SqlDependency and Release Build
    D Darkness84

    I have a problem with a windows service i have created. I am using SqlDependency to notify my service of changes in a table in a database. When I compile this in Debug mode everything works fine. However when I compile in Release mode I am getting problems. The service runs fine until the table in the database changes and then the service just hangs. Does anyone have any ideas on why this might be occuring in the release build but not the debug build?

    C# database debugging help question announcement

  • SqlDependency
    D Darkness84

    I am having an issue with SqlDependency. SqlDependency is working fine until the connection to the database is closed. I have a check in my code that re-opens the connection if it closes but when this happens the SqlDepenency no longer works. Before the connection is re-established I call SqlDependency.Stop(connectionString) followed by SqlDependency.Start(connectionString) but this doesn't help. Any ideas on why this might be?

    C# help database question

  • SQL Database Connection
    D Darkness84

    Not sure, but I'll have a read. Thanks.

    C# database question

  • SQL Database Connection
    D Darkness84

    I am using SqlDependency so that my application will respond immediately to changes in the database and thus i need the connection to be open.

    C# database question

  • SQL Database Connection
    D Darkness84

    I am working on an application that maintains an open connection to an sql database. I also have a timer that checks to see if the connection has closed and if so, it tries to re-opens the connection. This is working fine at the moment as my application and the database are running on the same computer. However this application will eventually run on a different computer to where the database will be. What I would like to know is if for some reason the connection from the computer running the application and the computer with the database were to become disconnected, would my application view this as the connection being closed?

    C# database question

  • sp_who2
    D Darkness84

    I thought of that but if one computer is running the service and crashes the service's state would still be set to running in the table and then no other computer would be able to run that service until the state was manually reset in the database.

    Database database csharp sharepoint help question

  • sp_who2
    D Darkness84

    I have written a service (in C#) that reads and writes to an SQL database. At the begining of the service I execute sp_who2 to see if another computer connected to the same database is already running the service and if it is I stop the service. My problem is that the service is not showing up in the results of sp_who2. Do you have to initialise anything either in the database or my service for it to be displayed by sp_who2?

    Database database csharp sharepoint help question

  • Service Detection [modified]
    D Darkness84

    Thank you very much. Your post was most helpful. I created a table in the database that has one column called Running which I set to N. When the service first starts up it queries this table. If N is returned the service sets it to Y and it can start. If Y i returned the service cannot start. When the service which is running stops, it sets the row back to N.

    C# sysadmin question

  • Database contention
    D Darkness84

    SQL Server 2005

    Database csharp database question

  • Service Detection [modified]
    D Darkness84

    I have written a service that will be run on mutiple computers connected to the same network. However if the service is already running on one computer I don't want it to run on the other computers. Does anybody know if this is possible? -- modified at 18:34 Wednesday 7th March, 2007

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