isar / isar/hive

How to get the value of an index in hive flutter?

Open
#278 5 comments 1 reaction 0 assignees View on GitHub
question
Dominant language
Dart
Stars
4.4k
Forks
449
PR merge metrics
No merged PRs in 30d

Description

**Question**
I have created a dynamic database using hive in flutter. how can I get the value in a certain index? I need to get the value of totalSec in the index I'm going to delete so I can subtract it's total time but I don't know how. please help. here is a sample of my code snippet below:

**Code sample**
```dart
`child: new InkWell(
borderRadius: BorderRadius.circular(1000.0),
onTap: () {
newRoutineList.removeAt(index);
rtnConfigBox.deleteAt(index);
_rtnTotalSec = _rtnTotalSec - rtnConfigBox.getAt(index.totalSec);
setState(() {});
},
`

```

**Version**
- Platform: iOS, Android, Mac, Windows, Linux, Web
- Flutter version: [e.g. 1.5.4]
- Hive version: [e.g. 0.5.0]

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.