Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
PageFrame fails to show refresh on Tabs
Message
De
24/08/2001 19:58:03
Nancy Folsom
Pixel Dust Industries
Washington, États-Unis
 
 
À
24/08/2001 19:45:13
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00549050
Message ID:
00549067
Vues:
21
Cecil-

Notes in bold below. Added < pre> tags to format code. You're storing the page captions to a table in the second form, and then reading those values from the table after the form (#2) is closed. Right?

>in the click event I have the following...
>
>object: [] cmdSetTabs procedure: Click
>LOCAL i, lcFile
>do FORM ..\forms\frmSetTabs   && Modal Form...
>* open file for headings
>* for each page in pgframe1
>lcFile = Alias()
>*
>if file("..\data\tabhdr.dbf")
>*   use ..\data\tabhdr in 0
>   select tabhdr
>   use                    && Added to close the file and re-open if in buffer
Okay. I was going to suggest maybe the changes weren't being reflected.
>   use ..\data\tabhdr in 0
>   GO TOP
>   cHeader = ""
>   i=0
    <b>SET STEP ON</b>

>   do while !eof()
>      i = recno()    && set i to equal the record number
>      cHeader = "thisform.pgFrame1.Page"+ltrim(str(i))
Step thru and check the following line to see if the values are what you expect.
>
      &cHeader..Caption = tabhdr.name
>      &cHeader..ToolTipText = tabhdr.tooltips
>      &cHeader..refresh()
>      thisform.pgFrame1.refresh()
>	  THISFORM.REFRESH           && above 2 below 3 lines will it work...
I don't understand this comment. Do you mean the refreshes work to make the captions refresh?
>	  THISFORM.ACTIVATE
>	  THISFORM.DEACTIVATE
>      skip
>   enddo
>   select JustFName(lcFile)
>else
>	messagebox("Tab Header file missing", 20)
>endif
>THISFORM.ACTIVATE
>THISFORM.REFRESH
>THISFORM.ACTIVATE
>THISFORM.REFRESH
>

The following isn't relevent to the issue, right? It's during the running of the form and the second form that's a problem?
>In the Init Method of the first form I load the tabs with this code...
>object: [] frmBldTree procedure: Click
>* Check to see if OCX installed and loaded.
>*local descript
>set talk off
>clear
>set deleted on
>local lcFile, i
>i=10
>IF TYPE("THIS.pgFrame1.Page1.oleTree1") # "O" OR ISNULL(THIS.pgFrame1.Page1.oleTree1)
>	RETURN .F.
>ENDIF
>public cString1
>public cDateTime1
>if type("LastSelected")<>"N"
>   public LastSelected
>   m.LastSelected = 0
>endif
>m.cString1 = "Passed nothing"
>m.cDateTime1 = Dtoc(Date())+ " " + time()
>*m.descript = space(240)
>lcFile = Alias()
>if empty(lcFile)
>*	use ..\data\notedata in 0 exclusive
>endif
>* open file for headings
>* for each page in pgframe1
>if file("..\data\tabhdr.dbf")
>   use ..\data\tabhdr in 0
>   if used('tabhdr')
>	   select tabhdr
>	   cHeader = ""
>	*   debug
>	   i=0
>	   do while !eof()
>	      i = recno()    && set i to equal the record number
>	      cHeader = "thisform.pgFrame1.Page"+ltrim(str(i))
>	      &cHeader..Caption = tabhdr.name
>	      &cHeader..ToolTipText = tabhdr.tooltips
>	      skip
>	   enddo
>   endif
>   select JustFName(lcFile)
>else
>   cPage = "Page "
>   cTool = "Tool Tip for Page "
>   cHeader = ""
>   for i = 1 to 10
>      cHeader = "thisform.pgFrame1.Page"+ltrim(str(i))
>      goto i
>      &cHeader..Caption = cPage+ltrim(str(i))
>      &cHeader..Tooltip = cTool+ltrim(str(i))
>   endfor
>endif
>* Force the loading of all files as if user pressed
>* the "Load DBF" button
>keyboard "{ALT+L}"
>return
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform