Results 1 to 2 of 2

Thread: ActiveX Custom Control

  1. #1

    Thread Starter
    New Member
    Join Date
    Jul 2001
    Posts
    2

    ActiveX Custom Control

    I created a Control to custom display and format phone numbers to my liking.

    On the control are two textboxs:

    1) txtPhoneNumberDisplay - For formatted display of the phone number eg. (818) 555-1212

    2) txtPhoneNumber - A Data bound textbox to contain only the numeric data. eg. 8185551212

    My goal is to be able to put the custom control on my form, and to be able to specify the DataSource, and DataField to bind to in design mode. I can get the DataSource with no problem, but I cannot get the DataField to appear as an extender object. I reference the Microsoft Data Source Interfaces Type Lib so that it knows what a type DataSource is. Any suggestions??? Yes, I know its like the masked edit box, but I need it to be custom

    Thanks!

    -gary

  2. #2
    Addicted Member ZanM's Avatar
    Join Date
    Oct 1999
    Location
    The here and now.
    Posts
    191

    ...

    on the activeX's properties mark it as a dataconsumer i.e. true
    vb does the rest I belive you may need to superclass the dataconsumer propties of the textboxes i.e. expose them as part of the activeX
    Magiaus
    Visual Basic 6.0 SP5
    Visual C++ 6.0 SP5


    The only sovereign you can allow to rule you is reason.

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