Syntactical compiler error

Re: Syntactical compiler error

Postby nageswaragunupudi » Sat Jul 30, 2011 7:48 pm

Code: Select all  Expand view
function OSendMulti( o, cMsg, uVal )

   local aMsg  := HB_ATokens( cMsg, ":" )
   local n     := Len( aMsg ) - If( uVal == nil, 0, 1 )
   local p

   AEval( aMsg, { |c| o := OSendEx( o, c ) }, 1, n )
   if uVal != nil
      o        := OSend( o, "_" + ATail( aMsg ), uVal )
   endif

return o

function OSendEx( o, c )

   c        := StrTran( StrTran( c, '[', '(' ), ']', ')' )
   if '(' $ c
      c     := '"' + StrTran( StrTran( c, '(', '",' ), ')', '' )
      o     := HB_ExecFromArray( "OSend", { o, &c } )
   else
      o     := OSend( o, c )
   endif

return o

 

This code works with multiple parameters like "oSheet:Cells( 99, 9 ):Value" also. I think it should work with embedded "-" also, though I could not test that case here. Please test and let me know.

Tested on latest Harbour and xHarbour
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10308
Joined: Sun Nov 19, 2006 5:22 am
Location: India

Re: Syntactical compiler error

Postby Rick Lipkin » Sun Jul 31, 2011 4:25 pm

Rao

It WORKS in all situations ... :Click() :item(0) and in the case of a hyphen "-" in the Dom string ..

Thank you !!
Rick Lipkin
User avatar
Rick Lipkin
 
Posts: 2634
Joined: Fri Oct 07, 2005 1:50 pm
Location: Columbia, South Carolina USA

Previous

Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 41 guests