[Gambas-user] How to remove the marquee of a list (ie the highlighted line color)
richard terry
rterry at ...1822...
Tue Apr 1 05:59:07 CEST 2008
On Tue, 1 Apr 2008 01:21:17 pm you wrote:
Stiill can't get this to work - I get an overflow error the minute I introduce
any of the code (commented out in the example below):
> Alle 01:16, martedì 1 aprile 2008, richard terry ha scritto:
> > On Sun, 30 Mar 2008 08:20:15 pm you wrote:
> > > On 3/29/08, richard terry <rterry at ...1822...> wrote:
> > > > I've two lists one above the other. When the second list is clicked
> > > > on, I want
> > > > to remove the marquee from the first one.
> > > >
> > > > I've tried. list.item.selected = False and it dosn't seem to do
> > > > anything.
> > > >
> > > > Any help appreciated.
> > >
> > > Hi, I assume you use ListView.
> >
> > Using a column view, tried the same code and got a 'stack overflow'
> > message, maybe you could try and see if you get the same.
>
> With ColumnView this remove the marquee of a list:
>
> ColumnView1.Current.Selected = FALSE
Public Sub ProblemLists_Select()
'--------------------------------------------------------------------------------
'when user clicks on either active or inactive problem list
'set the value of iProblemKey, to that of the selected item
'hence PH[sProblemKey] becomes the selected problem
'--------------------------------------------------------------------------------
Select Case Last.tag
Case "active problems"
cvwProblemsActive.MoveCurrent
cvwProblemsActive.Item.Selected = True
sProblemKey = cvwProblemsActive.Item.key
---- I tried this first:
' cvwProblemsInActive.Current.Selected = False
--- then this next
' If cvwProblemsInActive.count Then
' cvwProblemsInActive.Current.Selected = False
' End If
-- then this next
' If cvwProblemsInActive.count And cvwProblemsInActive.Current.Selected
Then
' cvwProblemsInActive.Current.Selected = False
' End If
And they all give 'overflow errors'
Take any of that code out and the routine works normally, albeit without
removing the marquee. I'll try and do a mini-project tonight with just the
listview on it and see what happens and report back
Case "inactive problems"
cvwProblemsInActive.MoveCurrent
cvwProblemsInActive.Item.Selected = True
sProblemKey = cvwProblemsInActive.Item.key
' If cvwProblemsActive.count And cvwProblemsActive.Current.Selected Then
' cvwProblemsActive.Current.Selected = False
' End If
' If cvwProblemsActive.count Then
' cvwProblemsActive.Current.Selected = False
' End If
End Select
End
Public Sub EditArea_Problem_Display()
'----------------------------------------------------------
'Place the contents of currentProblem into the editing area
'When this data is placed into the textboxes and checkboxes
'the change event in those controls will also be triggered
'so must set bExit to true whilst loading the data
'----------------------------------------------------------
EditArea_Clear
bExit = True
bEditing = True
'PRINT " SR: EditArea_Problem_Display -Cleared the edit area, value now
is", bexit
currentProblem = PH[sProblemKey]
Print "---------------------------------" ""
Print "in displaying, the key is ", sProblemKey
Print "---------------------------------" ""
currentProblem = frmClinical.currentPatient.past_history[sProblemKey]
' PH_Copy = currentProblem
txtCondition.text = currentProblem.description
'PRINT "changed problem , value now is", bexit
Select Case currentProblem.fk_laterality
Case 1
chkLateralityLeft.value = gvar.LateralityLeft
Case 2
chkLateralityRight.value = gvar.LateralityRight
Case 3
chkLateralityBoth.value = gvar.LateralityBoth
End Select
txtNotes.text = currentProblem.notes
txtAgeOnset.text = currentProblem.age_onset
txtYearOnset.text = currentProblem.year_onset
chkYearOnsetUncertain.value = currentProblem.year_onset_uncertain
chkActive.Value = currentProblem.active
chkSignificant.Value = currentProblem.significant
chkOperation.Value = currentProblem.operation
chkConfidential.Value = currentProblem.confidential
chkCauseOfDeath.Value = currentProblem.cause_of_death
bExit = False
End
Public Sub Problem_Refresh_Lists()
'-----------------------------------------------
'Refreshes the active and inactive problem lists
'-----------------------------------------------
modTemp.pasthistory_refresh_display(cvwProblemsActive, cvwProblemsInActive,
PH)
End
Public Sub ProblemLists_LostFocus()
'FIXME - HOW TO REMOVE THE MAQUEE
'PRINT "lost focus"
Select Case Last.tag
Case "active problems"
cvwProblemsActive.MoveFirst
cvwProblemsActive.MoveAbove
'cvwProblemsActive.Item.Selected = False
Case "iInactive problems"
cvwProblemsInActive.Item.Selected = False
End Select
End
Public Sub ProblemLists_Click()
'-----------------------------------------------------------
'The user has clicked on either the active or inactive lists
'so display this problem in the editing area
'------------------------------------------------------------
'PRINT "before display, value of bExit is", bExit
EditArea_Problem_Display
'PRINT "after display, value of bExit is", bExit
End
>
>
> Stefano
>
> > > NB: I'm using gambas3 svn, retrieved 2 days ago.
> >
> > -------------------------------------------------------------------------
> > Check out the new SourceForge.net Marketplace.
> > It's the best place to buy or sell services for
> > just about anything Open Source.
> > http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketpl
> >ac e _______________________________________________
> > Gambas-user mailing list
> > Gambas-user at lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/gambas-user
-------------- next part --------------
A non-text attachment was scrubbed...
Name: two_lists_past_history.png
Type: image/png
Size: 13108 bytes
Desc: not available
URL: <http://lists.gambas-basic.org/pipermail/user/attachments/20080401/5aa009d4/attachment.png>
More information about the User
mailing list