Talk About Network



Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > Clarion > replace some wo...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 1 of 1 Topic 9024 of 9097
Post > Topic >>

replace some work into other string (Messagebox)

by egp1962@[EMAIL PROTECTED] Jan 14, 2008 at 04:16 PM

I am new in clarion and I have a procedure ds_Message for using
Capesoft MessageBox
I need to modify this, searching into messagebox some word and
replacing it for other but it is not working, I been trying on
differents ways but I can not see the error.
this is my code
Plis could anybody help me!!!!

Data
Locate long
Code

   Loc:sOldMsgText = clip(LMBD:MessageText)

   strreplace = 'mynewword'
   strfind = 'myoldword'

   IF UPPER(strfind)<>UPPER(strreplace)
      LOOP
        Locate = INSTRING(UPPER(strfind), UPPER(Loc:sOldMsgText), 1,
Locate)
        IF ~Locate THEN break.
        Loc:sOldMsgText = SUB(Loc:sOldMsgText,1,Locate-1) & strreplace
& SUB(Loc:sOldMsgText,Locate+LEN(strfind), LEN(Loc:sOldMsgText))
      END
   END
    LMBD:MessageText = Clip(Loc:sOldMsgText)

thanks,




 1 Posts in Topic:
replace some work into other string (Messagebox)
egp1962@[EMAIL PROTECTED]  2008-01-14 16:16:52 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Tue May 13 14:47:39 CDT 2008.