admin管理员组

文章数量:1609530

在项目开发制作中经常回读取excel表格数据,其实有多种实现方式,FlexReader是比较方便快捷读取Excel文件内容,支持CSV,XLSX等格式。支持所以平台上运行。

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using System.IO;
using FlexFramework.Excel;
using UnityEngine.Networking;
using System.Linq;

public class Test : MonoBehaviour
{
    // Start is called before the first frame update
    void Start()
    {
        //开始读取表格数据
       // LoadExcel();
    }

    // Update is called once per frame
    void Update()
    {
        if (Input.GetMouseButtonDown(0))
        {
            LoadExcel();
            print("load");
            
        }
    }
 
    public delegate void DownloadHandler(byte[] bytes);
    //加载excel
    public  void LoadExcel()
    {
            // StreamingAssets
        
            StartCoroutine(LoadFileAsync("checkdata.xlsx", bytes =>
            {
            

本文标签: 表格数据UnityExcel