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
K

kalkwarf

@kalkwarf
About
Posts
9
Topics
4
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • XSD.EXE array, would like list
    K kalkwarf

    I think you do not understand the question. The problem is that the tool (XSD.EXE) generates code that uses arrays. Arrays are limiting since it is difficult to add to or remove items from them. I was looking for another tool (that used a more appropriate collection) or an easy workaround. Perhaps I could have phrased my question better. The limitation I mentioned was intended to mean that the tool generated arrays, not that of arrays themselves. Even at this late stage, I appreciate your answer. However, I believe you misread the question.

    XML / XSL csharp database docker data-structures xml

  • XSD.EXE array, would like list
    K kalkwarf

    I am not sure what you mean by "replace it." Do you mean change the implementation of the class produced by XSD.EXE? My process is: - convert class array to List (ToList()) - make my changes (add, delete, modify) - assign back to class array (myList.ToArray)

    XML / XSL csharp database docker data-structures xml

  • XSD.EXE array, would like list
    K kalkwarf

    I used XSD.EXE to convert my schema to a C# class. The tool creates arrays to represent elements whose maxOccurs attribute is unbounded. Arrays are very limiting: you cannot add or delete items without a lot of shuffling. Has anyone found a way around this limitation of arrays? For simple cases, I have converted the array to a List and back to an array, but that is only useful in the simplest of cases. Perhaps there is another tool that can convert my schema and use a list or some other suitable container (?).

    XML / XSL csharp database docker data-structures xml

  • String index
    K kalkwarf

    No, I have not found a solution. I suspect it is buried in the container classes or iterators some place, but I haven't had time to look. It wasn't a high-priority issue for me, so I am currently doing without.

    .NET (Core and Framework) regex database help tutorial question

  • String index
    K kalkwarf

    I am enumerating through a collection where the index is a string. I would like to get my hands on that string. I am working with regular expression named groups, but the issue is the same for any collection indexed with strings. An example: Regex regEx = new Regex(@"^(?<name>\w+):(?<value>\w+)"); Match match = regEx.Match("abc:123"); GroupCollection groups = match.Groups; Console.WriteLine(groups["name"]); Console.WriteLine(groups["value"]); (Note that the sad face emoticon in the first line should be a colon followed by a left parenthesis. I could not turn this off.) The above writes the following to the Console: abc 123 I would like to also write the index so the output looks like: name = abc value = 123 Ideally, I would like to use a foreach to print all indexes and values in the collection. This would look something like: foreach (Group group in match.Groups) { Console.WriteLine(??? + " = " + group.Value); } I cannot figure out what "???" should be. Thanks.

    .NET (Core and Framework) regex database help tutorial question

  • storage of employee objects in a container
    K kalkwarf

    A multimap will allow you to have multiple values per key. Dave

    ATL / WTL / STL graphics docker data-structures json help

  • Can't change icon
    K kalkwarf

    Thank you, this solved most of my problems. I must say that all this is not very intuitive. Multiple icons in one file? Also, it would be nice if the IDE's Icon Editor displayed all the images in the file or gave you a hint that there may be more than one. Oh well. Another question: You mentioned that the icon plucked from the file depends on circumstances. Is there any way of extracting a specific icon from a file? For instance, I get the icon with: statusBarPanel.Icon = new Icon(this.GetType(), "MyIcon.ico"); This seems to look for the 16x16 icon. What if I had a circumstance where I wanted a specific size (color...) rather than the default? Thanks, Dave

    C# graphics hardware help question learning

  • Can't change icon
    K kalkwarf

    I am having trouble changing icons. I edit them with the resource editor, but when I display them they haven't changed. For instance, I'll add an icon to my assembly (Add New Item/Icon file). Then I change its Build Action Property to Embedded Resource. Then I edit the default to what I want. I retrieve the icon with: Icon icon = new Icon(this.GetType(), "MyIcon.ico"); Lastly, I assign this icon to the Icon property of a StatusBar panel. The problem is that the icon hasn't changed from the default image. No amount of saving, rebuilding, etc. seems to do anything. Viewing the image in the icon editor shows the changed icon. Viewing the file with a drawing program (e.g Paint) shows the changed icon. I just cannot get it to diaplsy on my form correctly. What am I doing wrong? Dave

    C# graphics hardware help question learning

  • Configuration, deploying...
    K kalkwarf

    I am writing software for a company that produces a box that collects data (data and purpose are unimportant). My software is an application for users to communicate with the box (upload configuration, download data...). I am trying to design the software such that I can account for changes to the box's embedded code by adding standalone components, but not changing my core application. I merely wish to deploy components that match the new embedded code and have them automatically recognized by my software. An example of a component is a UserControl that gathers configuration data specific for that embedded version. Does anyone have any hints on making this easy to do? How should I package my components? How do I create them programatically? I can certainly define a common place to look for all these components, but is there a better/slicker way to store and retrieve them? Any other hints on deployment of my components? Dave

    .NET (Core and Framework) question asp-net design sysadmin hardware
  • Login

  • Don't have an account? Register

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