Results 1 to 11 of 11

Thread: Extra Info Storer User Control

Threaded View

  1. #11
    PowerPoster Elroy's Avatar
    Join Date
    Jun 2014
    Location
    Near Nashville TN
    Posts
    10,918

    Re: Extra Info Storer User Control

    Quote Originally Posted by LaVolpe View Post
    @Elroy, persistence is not an issue with a collection or array in this case is it?

    I see little difference adding such a control on a form or adding a collection/array to a form and populating it at runtime, other than unneeded overhead. In fact, I kinda see the control as less resource friendly than the other options. The control is using 20 variants & longs, an hWnd unless made to be windowless, along with all the other properties associated with a control. Then the information is stored in a property bag which uses even more bytes.

    The above observations is just that. I would not create a control that simply replicates a simple collection/array and has less flexibility for runtime expansion.
    Yeah, I agree. There's not really a solution to much of anything here. In my post #2, I just suggested that a collection could do everything that his control could do, and that wasn't quite true. His control had the advantage of design-time persistence. In my post #4, I pointed out that a Constant Enumeration does have design-time persistence.

    However, I just got it in my head that a user-control should have unlimited properties, with persistence. So, I hauled off and made it so.

    Also, in the process, I learned a bit more about property-bags. I've done quite a bit with them, but I hadn't really pushed their limits. Something important I learned was that: Apparently, they can only handle Byte arrays. They can't deal with any other type of array. Since many things can be stuffed into a Byte array, this provides a great deal of flexibility. But it does make us work for it.

    Best Regards,
    Elroy

    EDIT1: Also, I wasn't really thinking about efficiency or the use of resources when I did any of that. Clearly, a series of constants would be FAR more efficient.

    EDIT2: Also, with my language, I've sort of confounded Constant Enumerations as opposed to a series of Constants. But I believe you get the gist of what I'm saying.
    Last edited by Elroy; Aug 25th, 2017 at 01:07 PM.
    Any software I post in these forums written by me is provided "AS IS" without warranty of any kind, expressed or implied, and permission is hereby granted, free of charge and without restriction, to any person obtaining a copy. To all, peace and happiness.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width