Save all the MSFlexGrid?

samus535
09-05-2003, 04:20 PM
Hi everybody,
I would like you to help me because I tried to save the text that my Grid contain and it just save the last row that I modified.

Please Help Me.
It would Be appreciate.

Thinker
09-05-2003, 04:37 PM
Not unless you show us the code you are trying to use.

samus535
09-05-2003, 04:47 PM
Not unless you show us the code you are trying to use.

Here's my code

Private Sub Form_Unload(Cancel As Integer)
Open App.Path & "/ToDo.txt" For Output As #1
For I = 1 To intNumberRows - 1
Write #1, strTache, intPriorite, intNumberRows
Next I
Close #1
End Sub


Thanks

Thinker
09-05-2003, 04:51 PM
My guess is that intNumberRows isn't the same as the number of rows
in the Flexgrid. Try using the actual .Rows property.

lebb
09-05-2003, 04:52 PM
Well, neither strTache, intPriorite, nor intNumberRows change within that loop. You need to loop through both the rows and cells of your flexgrid to write it out. Have a look at the .TextMatrix property.

samus535
09-05-2003, 04:52 PM
My guess is that intNumberRows isn't the same as the number of rows
in the Flexgrid. Try using the actual .Rows property.
Yeah That's true.
But how can I save the owl list and not only the last modify rows?

Thanks

Thinker
09-05-2003, 04:57 PM
Laura has a very good point too. This would be closer.

Open App.Path & "/ToDo.txt" For Output As #1
With MSFlexGrid1
For I = 1 To .Rows - 1
Write #1, .TextMatrix(0, I), .TextMatrix(1, I), I
Next I
End With
Close #1

samus535
09-05-2003, 04:59 PM
Laura has a very good point too. This would be closer.

Open App.Path & "/ToDo.txt" For Output As #1
With MSFlexGrid1
For I = 1 To .Rows - 1
Write #1, .TextMatrix(0, I), .TextMatrix(1, I), I
Next I
End With
Close #1


Thanks Guy Your help Is very Appreciate

EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum