View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0002567 | JEDI VCL | 00 JVCL Components | public | 2005-01-28 13:47 | 2005-02-15 17:47 |
Reporter | ivan_ra | Assigned To | jfudickar | ||
Priority | normal | Severity | tweak | Reproducibility | always |
Status | resolved | Resolution | fixed | ||
Product Version | 3.00 BETA 2 | ||||
Target Version | Fixed in Version | 3.00 | |||
Summary | 0002567: TjvFormStorage: OnSavePacement doesnt save StoredValues | ||||
Description | TjvFormStorage has 2 events useful for restore and save StoredValues. For example: procedure TForm1.JvFormStorage1RestorePlacement(Sender: TObject); begin ComboBox1.ItemIndex:=JvFormStorage1.StoredValue['CB1']; ComboBox2.ItemIndex:=JvFormStorage1.StoredValue['CB2']; end; procedure TForm1.JvFormStorage1SavePlacement(Sender: TObject); begin JvFormStorage1.StoredValue['CB1']:=ComboBox1.ItemIndex; JvFormStorage1.StoredValue['CB2']:=ComboBox1.ItemIndex; end; But 2'nd procedure doesnt work - file values of 'CB1' and 'CB2' are empty. To store it I wrote 3rd operator: JvFormStorage1.StoredValues.SaveValues; Why I must save values manually? Maybe there is wrong sequence in SaveFormPlacement: procedure TJvFormPlacement.SaveFormPlacement; begin if Assigned(AppStorage) then begin WriteInteger(siVersion, FVersion); SavePlacement; Save; FSaved := True; end; end; "Save" invoke OnSavePlacement event handler, but JvFormStorage writes stored values into file(reg, db, etc..) in SavePlacement method (before it). So, I must call SaveValues again. Maybe more correct sequence will be next: Save; SavePlacement; Look at example Storage.zip | ||||
Tags | No tags attached. | ||||
2005-01-28 13:47
|
Storage.zip (1,488 bytes) |
|
Changed as suggested |
|
Please tell is if it works. If we don't get any answers from you in the next 7 days, we will consider this issue as resolved |
|
No further comments -> fixed |
Date Modified | Username | Field | Change |
---|---|---|---|
2005-01-28 13:47 | ivan_ra | New Issue | |
2005-01-28 13:47 | ivan_ra | File Added: Storage.zip | |
2005-01-28 15:01 | jfudickar | Status | new => assigned |
2005-01-28 15:01 | jfudickar | Assigned To | => jfudickar |
2005-01-28 15:43 | jfudickar | Note Added: 0006306 | |
2005-01-28 15:43 | jfudickar | Status | assigned => feedback |
2005-02-04 01:59 | obones | Note Added: 0006384 | |
2005-02-15 17:41 | jfudickar | Status | feedback => resolved |
2005-02-15 17:41 | jfudickar | Resolution | open => fixed |
2005-02-15 17:41 | jfudickar | Note Added: 0006502 | |
2005-02-15 17:47 | jfudickar | Status | resolved => feedback |
2005-02-15 17:47 | jfudickar | Resolution | fixed => reopened |
2005-02-15 17:47 | jfudickar | Status | feedback => resolved |
2005-02-15 17:47 | jfudickar | Fixed in Version | => 3.00 |
2005-02-15 17:47 | jfudickar | Resolution | reopened => fixed |