sendmessage

In this category you can exchange your programming questions and solutions.
Post Reply
guy
Posts: 1
Joined: Sat Apr 06, 2013 1:14 am

sendmessage

Post: # 1083Post guy
Sun Jun 02, 2013 5:47 pm

i see no sendmessage in this language i want to use scintilla in an editor i`m working on. I use rapidq. In rapidq sendmessage is use a lot. can someone help me. 

Angel
Posts: 87
Joined: Sat Nov 19, 2011 9:34 am

sendmessage

Post: # 1084Post Angel
Mon Jun 03, 2013 6:32 pm

I put an example.
`Code
Const EM_SETMARGINS=&HD3
Const EC_LEFTMARGIN=&H1
Const EC_RIGHTMARGIN=&H2
Declare SendMessageAPI As "SendMessageA" of "user32"
  Hwnd As Long
  wMsg As Long
  wParam As Long
  lParam As Long
  Result As Long
End Declare
Object frmForm as Form
  Caption="Form"
  Width=640
  Height=480
  Center
  `Other objects
  Object rchEditor as Richedit
    Top=10
    left=10
    Width=600
    Height=400
    Plaintext=True
    Wordwrap=False
    WantTabs=True
    Scrollbars=ssBoth
  End Object
  `End other objects
  Onshow=frmForm_Onshow
End Object
frmForm.Showmodal
Sub frmForm_Onshow
  `Set margins
   With SendMessageAPI
    Hwnd=rchEditor.Hwnd
    wMsg=EM_SETMARGINS
    wParam=EC_LEFTMARGIN Or EC_RIGHTMARGIN
    lParam=20+20*&H10000
    Execute
  End With
End Sub
`End code


Post Reply