Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Rtf ole control - positioning
Message
De
09/02/2006 17:44:14
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Programmation Orientée Object
Divers
Thread ID:
01095180
Message ID:
01095296
Vues:
17
This message has been marked as the solution to the initial question of the thread.
>How does one get the handle for the RichTextControl?
>

Hi Geoff,
RichTextControl already has a hWnd property. You can use it directly

Update:
BTW, try this code:
** Click Event
#Define EM_LINESCROLL            0xB6
#Define EM_GETFIRSTVISIBLELINE   0xCE

Declare Long SendMessage in User32 ;
   Long nhWnd, Long uMsg, Long wParam, Long lParam
Declare Long PostMessage in User32 ;
   Long nhWnd, Long uMsg, Long wParam, Long lParam

With ThisForm.oRTF
   nLine = .GetLineFromChar( .SelStart )
   If (nLineNo > 0)
      nLineNo = nLineNo - SendMessage( .hWnd, EM_GETFIRSTVISIBLELINE, 0, 0 )
      If (nLineNo > 0)
         PostMessage( .hWnd, EM_LINESCROLL, 0, nLineNo )
      endif
   endif
EndWith
Regards
Herman
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform