General information
Category:
ActiveX controls in VFP
If OnComm is not firing at all check to see that you have your RThreshold set correctly. If you have it set to 0 OnComm doesn't fire for input.
>Hey Folks,
>
>I'm flailing with both these controls and getting nowhere. Any tips would be appreciated.
>
>I'm using VFp 6.0 and Mere Mortals 6.0a on Win98 for this test but I'm not using the mmf ActiveX
>wrapper class.
>
>I'm not able to retrieve a selected date or time from the DT Picker. I've put up a simple modal form,
>dropped an OLE Control, Inserted the DT Picker as described in the VFp docs (as far as I can tell)
>and named it axDate. I've also dropped a simple textbox to display the value selected in the DT Picker.
>The form and controls load and the DT Picker allows the selection of a date both by using the calendar
>and keyboard entry. But I'm unable to retrieve the selected date even to display in the text box.
>Through endless flails, I've tried referring to the selected date as everything from
>ThisForm.axDate.Value (silly me) to the separate components of ..Month, ..Day,
>..Year and have tried to use the ReadExpression method as a 'Get' as in:
>
> ThisForm.axDate.ReadExpression(ThisForm.axDate.Value)
>
>A couple of variations on 'property Value not found' are thrown but that's the basic message. There
>certainly seems to be a 'Value' property on the DT Picker Properties sheet. By the way, I am selecting
>the axDate control from the context menu Object List to be sure I've got a correct reference.
>
>I'm sure it seems silly that if I can't even get the date out of an ActiveX control that I'd even try to
>use MSComm but that's me. Stop me if you've heard this but things that I've done for years
>procedurally (gasp) border on the impossible now that everything's been made so simple.
>
>I'm using an WDS RF TriCoder and have revised Worthington's VB demo code into
>several successful versions of data collection and posting but can't transfer that capability to
>VFp. I've checked the ut knowledge base and looked at the readme that accompanied Waleed Hasan's
>download on the subject among others. My code is fundamentally very similar (famous last words) to his
>'interrupt driven' example which is the technique that I've used successfully in VB. Frankly, it seems
>that once the port is open in VB, the control manages communication and the code I put
>in the OnComm() method executes fine. In VFp, I'm able to initialize and open the port and get
>'444' as a CommID but my OnComm code is not executing. I know that there are a zillion things
>I may have done wrong in translating the VB code to VFp but any general comments you may
>have would be appreciated. My outer condition checks are for This.CommEvent = 2 and
>This.InBufferCount > 0 but neither of those conditions seem ever to be met. CommEvent = -1.
>
>I'll have to go back to VB to get my current project done but I sure would like to work in VFp with
>the MMF.
>
>Anyway, if you all could just help me get the date out of the ActiveX DT Picker, that would be a start.
>
>Thanks.
>
>Mike Holland
Previous
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only