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
O

occcy

@occcy
About
Posts
45
Topics
15
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • Problem with Display Scheme (Windows font size)
    O occcy

    Try the Form.AutoScaleMode property. Setting it to None should solve your problem.

    C# help question

  • Force ClearType Text Rendering for TextBox Control
    O occcy

    Hi! Is there any way to force ClearType text rendering (regardless of the current windows settings) for a System.Windows.Forms.TextBox control? Custom drawing of a textbox (OnPaint, Message Handling etc.) doesn't work. Thanks in advance!

    C# graphics question

  • Serialize/Deserialize data class from different assemblies
    O occcy

    A serialized class stores full names or your class and the properties of this class. If your server serializes a class of your Apiimpl.dll than this assembly name is stored within the full name of the class. So for deserialization this assembly must be present on your client. A common way is to use interfaces:

    // API.dll:

    public interface IDataClass {
    int DataField { get; set; }
    }

    // APIIMPL.dll:

    public class DataClass: IDataClass {
    private int dataField;

    public int DataField { get { return dataField; } set { dataField=value;} }
    }

    So on your client is no code from your server. This works the best. Try out the xml serialization to see and understand whats happened to your classes during serialization (search for XmlObjectSerializer in your msdn library). occcy

    C# help csharp algorithms testing business

  • queer error message
    O occcy

    Cool! A response after more than three years :-D I thought I am the only one who has this problem, so I've learned to live with this Bug. But now I will try this workaround. Many thanks! occcy

    C# csharp visual-studio design ai-coding json

  • context menu and it's (custom) position
    O occcy

    The contextmenustrip has a method Show with several overloads. Some of them take the screen coordinates of the top left corner of the context menu....

    C# csharp tutorial question

  • queer error message
    O occcy

    Hi! From time to time visual studio 2005 shows a queer error message: 'Code generation for property 'Cursor' failed. Error was: ''CursorConverter' is unable to convert 'System.Windows.Forms.Cursor' to 'System.ComponentModel.Design.Serialization.InstanceDescriptor'.' Maybe it happens because i use an own UserControl. But in fact this UserControl doesn't make anything with the property cursor ... :wtf: Is there anybody who knows this error message and can say what's wrong!?!? Thanks in advance! -- modified at 4:26 Tuesday 9th May, 2006

    C# csharp visual-studio design ai-coding json

  • events
    O occcy

    hi! is there a way to read out the assigned eventhandlers of one item and assing them to the event of another item?! i want to clone a menuitem and need the click eventhandlers to assign them to the cloned menutem too. thanks in advance!

    C# question

  • Retreiving and displaying strings...
    O occcy

    i don't know whether i understand your question right...?! but if your string is "\"Tic\",\"Tac\","\Toe\"" you could use the Split method. string s="\"Tic\",\"Tac\","\Toe\""; string[] fields=s.Split(new char[]{','});

    C# question help

  • Control inheritance problem
    O occcy

    Hello! I've an UserControl with a MenuStrip control on it. In a derived control I cannot add additional menu items to this menustrip (in the visual designer). Is there any advise to solve this problem!?

    C# oop help question

  • Trace Question
    O occcy

    hi! i've a question about Trace. i want to use the trace (System.Diagnostic nemaspace) mechanism to generate (on demand) error and/or state messages for the eventlog. but it's only possible to generate information messages (Type=Information), no warnings or errors?! or is it possible anyway? :confused: here's my code:TraceListener Listener=new EventLogTraceListener("myApp"); Trace.Listeners.Add(Listener); ... void doSometing() { try { //... do something } catch(Exception e) { //... handle exception and write message to eventlog... Trace.WriteLine(e.Message,"Error"); } }
    thanks in advance!

    C# question debugging help

  • String Size Problem
    O occcy

    use Graphics.MeasureCharacterRanges! it returns the exact size of your string.....

    C# help question

  • what is the differences by 'component' and 'windows form'?
    O occcy

    i don't think, that a component "makes" a form ;) a windows form is a container for different windows controls, whereas a component is a non visual component. for example a sqlConnection or a Timer is a component. components appear during design time on a seperate panel at the bottom of your windows forms designer. while execution components aren't visible - but they work invisible in the background of your application...

    C# question

  • Application.Run question
    O occcy

    private void Form1_Activated(object sender, System.EventArgs e) { this.Visible=false; }

    C# question

  • C# Text file to PDF
    O occcy

    There are no tools in the .net framework... But you can find various components to generate pdf's in the internet. Or, if you don't want to generate your pdf inside a program, you can find "pdf printer"...for example PDF Ghost. The pdf file format is an open file format, so you could implement your own pdf generator. References can be found in the internet too, for example here: http://partners.adobe.com/public/developer/pdf/index_reference.html#5

    C# csharp tutorial question

  • ListBox serialization wont work! :-(
    O occcy

    Green Fuze wrote: 1. is there anyway to serialize an object as is? I mean, list just serializing a listbox or a combobox, and all the infomation inside will be saved? Search for "Control.DataBindings Property" in your vs.net help or msdn. I think that's what you are looking for. Green Fuze wrote: 2. I don't get exactly what the Initialize() command in the array class is doing, or when should I use it... Search for "Array.Initialize Method" in your vs.net help or msdn too. Mostly you don't need to call this method. For example you have an array of string, the compiler sets all strings inside this array automatically to an empty string.....

    C# graphics docker json

  • ListBox serialization wont work! :-(
    O occcy

    hmmm?! it should work! perhaps you don't serialize/deserialize with the right type? try this: serialize: string[] items; ... info.AddValue("listbox",items,typeof(string[])); deserialize: string[] items; items=(string[])info.GetValue("listbox",typeof(string[]));

    C# graphics docker json

  • ListBox serialization wont work! :-(
    O occcy

    try this: string[] items; items=new string[listbox.Items.Count] for(int i=0;i<listbox.Items.Count;i++) { items[i]=(string)listbox.Items[i]; } info.AddValue("List",items);

    C# graphics docker json

  • Selecting a TreeView node programmatically?
    O occcy

    set the SelectedNode property of your treeview

    C# question help

  • ListBox serialization wont work! :-(
    O occcy

    it doesn't work because listbox doesn't implement the ISerializable interface... try to serialize the datasource of your listbox... if it is an array of string, it can be serialized without any problem.

    C# graphics docker json

  • Reflection ... Call Method. Parameter question
    O occcy

    System.Reflection.MethodInfo mi = this.oSender.GetType().GetMethod("btnGetInfo_Click", ???); the overload list for GetMethod provides several possible parameterlists. if there is only one method btnGetInfo_Click inside your form, you can call GetMethod only with your methodname. otherwise you have to pass the types of your parameters: System.Reflection.MethodInfo mi = this.oSender.GetType().GetMethod("btnGetInfo_Click"); or System.Reflection.MethodInfo mi = this.oSender.GetType().GetMethod("btnGetInfo_Click", **new Type[]{typeof(object),typeof(EventArgs)}**); mi.Invoke(oSender, System.Reflection.BindingFlags.InvokeMethod, null, null???, null); the forth parameter needs an array of parameters for "sender" and "e". mi.Invoke(oSender, System.Reflection.BindingFlags.InvokeMethod, null, **new object[]{null,null}**, null);

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