为什么要创建我的文件夹/子文件夹,但是我的文件没有放在正确的文件夹中?

时间:2019-02-07 18:27:39

标签: vba

我正在创建文件夹和子文件夹,但是保存到该路径的文件不是正确的文件。我需要在import React, { Component } from 'react'; import { Text, View, TouchableOpacity, ScrollView } from 'react-native'; import style from './Styles/styleNew'; import PouchDB from 'pouchdb-react-native'; PouchDB.plugin(require('pouchdb-find')); const gThis = null; const db = new PouchDB('X') export default class Recipes extends Component { constructor(props) { super(props); gThis = this; this.state = { setRecipes: this.props.setRecipes, id: this.props.id, recipeID: null, options: [ ], }; } getRecipes() { let data = [] db.find({ selector: { type: { "$eq": this.state.id, }, owner: { "$in": ['user'] }, }, }).then(function (recipes) { recipes = recipes.docs for (let i = 0; i < recipes.length; i++) { recipe = recipes[i] let current = { id: recipe._id, name: recipe.name, recipe: recipe, } data.push(current) } gThis.setState({ options: data }) }).catch(function (err) { console.warn(err.toString()) }); } componentDidMount() { this.getRecipes() } handleBackPress = () => { this.props.navigation.goBack(); } defineRecipe(recipe, index) { this.setState({ recipeID: recipe._id }); this.state.setRecipes(recipe) } render() { return ( <View style={{ flex: 1 }}> <Text style={style.listText}>RECIPES {this.state.id} </Text> <ScrollView style={style.listScroll}> {this.state.options.length >0 && this.state.options.map((item, index) => { key = index + '-' + this.state.id //key = new Date().toISOString() console.log(key) return ( <TouchableOpacity style={this.state.recipeID === item.id ? style.listOptionSelected : style.listOption} onPress={() => { this.defineRecipe(item.recipe, index);}} key={key} > <Text style={style.listOptionText}>{item.name}</Text> </TouchableOpacity> ); }) } </ScrollView> </View> ); } } 行中进行更改吗?

wb.SaveCopyAs

这些是将文件保存到文件夹中的代码块,但是当我打开员工 Last = Data(i, 1) Mgr = Data(i, 2) strNewPath = BASEPATH & Mgr & "\" If Len(Dir(strNewPath, vbDirectory)) = 0 Then MkDir strNewPath End If strNewPath = strNewPath & Last & "\" If Len(Dir(strNewPath, vbDirectory)) = 0 Then MkDir strNewPath End If 文件夹时,其中的评估错误。

这是其余的代码:

Last

0 个答案:

没有答案