NetTalk Central

Author Topic: Hide field once again too small  (Read 3457 times)

Johan van Zyl

  • Full Member
  • ***
  • Posts: 180
  • jvz
    • View Profile
    • Email
Hide field once again too small
« on: April 18, 2011, 02:17:33 AM »
Hide field is once again to small even with abbreviations

(p_web.GSV('LOG:TaskType')<>'RequestForStaff'
AND p_web.GSV('LOG:TaskType')<>'StaffAvailability'
AND p_web.GSV('LOG:TaskType')<>'Incidents'
AND p_web.GSV('LOG:TaskType')<>'StaffDevelopment' 
AND p_web.GSV('LOG:TaskType')<>'Registration')
AND p_web.GSV('LOG:TaskType')<>'EmployeePaymentQuery')

How about putting the lot in a local variable like loc:gsvstring (CSTRING(2001))
and plonking loc:gsvstring into th ehide field?

eg  loc:gsvstring =  p_web.GSV(''LOG:TaskType'')<>''RequestForStaff'' &'AND'& p_web.GSV(''LOG:TaskType'')<> ''StaffAvailability''
short version of the loooog string
But code does not work - with Customer waiting for update there is nothing like presure to make my mind blank.

Please help!




[attachment deleted by admin]
Johan van Zyl
Clarion 6.3 9058/C8 Gold/SQL/NetTalk WebServer

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11250
    • View Profile
Re: Hide field once again too small
« Reply #1 on: April 18, 2011, 03:06:49 AM »
you have lots of options here;

a) create a source procedure that calculates the result and resturns it.

b) create a local variable, containing true / false and put that here.
then search the generated code for where the variable is used, and put your long expression before it.

c) check out the INLIST Clarion command, and formulate your expression around that.

cheers
Bruce

Johan van Zyl

  • Full Member
  • ***
  • Posts: 180
  • jvz
    • View Profile
    • Email
Re: Hide field once again too small RESOLVED?
« Reply #2 on: April 18, 2011, 11:58:42 PM »
Put this code in After Generated Code of LOG:TaskType - is this the best place? - but it seems to work.

   lb:hideemployeesysid = 1         !jvz 20110418
   if INLIST(LOG:TaskType,'StaffAvailability','Incidents','StaffDevelopment','EmployeesPaymentQuery')
      lb:hideemployeesysid = 0
   else
      lb:hideemployeesysid = 1  !jvz 20110419 not required
   END
 
put lb:hideemployeesysid in hide field of EMP:EmplyoeeSysID
 
Johan van Zyl
Clarion 6.3 9058/C8 Gold/SQL/NetTalk WebServer

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11250
    • View Profile
Re: Hide field once again too small
« Reply #3 on: April 19, 2011, 01:02:25 AM »
to find the optimal embed point, follow the directions listed in ( b) in my earlier post.

cheers
Bruce