我可以以某种方式密码保护导入前的CSV文件吗? [英] Can I somehow password-protect pre-import CSV files?

查看:88
本文介绍了我可以以某种方式密码保护导入前的CSV文件吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我写了一个简单的VB.NET应用程序来导入和编辑CSV文件。


现在我想要一个??锁定?原始(预导入)CSV文件因此不能单独打开
。它不是高敏感数据,我只是不想让人们在文件中查看。


因此不需要耗费时间的加密,只需一个简单的

密码即可打开,我可以在我的应用程序中编程,这样它在内部打开

导入的CSV文件将是完美的,但我可以把它做完。实际上它很难以任何方式密码保护CSV文件。


预导入的CSVa ??以ZIPa形式发送? s,所以我想到了

密码保护ZIP文件,并在我的

程序中导入和解压缩这些,但这似乎更具挑战性(如果可能的话)

特别是像我这样没有经验的程序员。


任何提示,指示,想法都非常感谢。谢谢!

I wrote a simple VB.NET application that imports and edits CSV files.

Now Ia??d like to a??locka?? the raw (pre-import) CSV files so these cannot be
opened separately. It is not high-sensitive data, I just dona??t want folks to
peek in the files.

So time-consuming encryption is not necessary, just a simple
password-to-open that I can program in my application so it internally opens
the imported CSV file would be perfect, but I cana??t get it done. In fact it
seems difficult to password-protect a CSV file in any way.

The pre-import CSVa??s are delivered as ZIPa??s, so I thought about
password-protecting the ZIP files and importing and unzipping these within my
program, but this would seem much more challenging (if at all possible)
especially for an inexperienced programmer like me.

Any tips, pointers, ideas are highly appreciated. Thanks!

推荐答案

一个简单的解决方案是保存为excel文件,密码保护它,删除csv

文件。当您需要csv文件时,打开excel文件并保存为csv文件。

" jonigr" < jo **** @ discuss.microsoft.com写信息

新闻:FB ************************ ********** @ microsof t.com ...
one easy solution is to save as excel file, password protect it, delete csv
file. When you need the csv file, open the excel file and save as csv file.
"jonigr" <jo****@discussions.microsoft.comwrote in message
news:FB**********************************@microsof t.com...

>我写了一个简单的VB.NET应用程序,用于导入和编辑CSV文件。


现在我想锁定原始(预导入)CSV文件因此不能单独打开
。这不是高敏感度的数据,我只是不想要人们来这些文件。


所以不需要耗时的加密,只需要一个简单的

密码即可打开,我可以在我的应用程序中编程,这样它就可以在内部打开
打开

导入的CSV文件将是完美的,但我无法完成它。实际上



似乎很难以任何方式密码保护CSV文件。


预导入CSV'这是以ZIP的形式发送的,所以我想到了

密码保护ZIP文件并导入和解压缩这些内容

我的

程序,但这似乎更具挑战性(如果可能的话)

特别是像我这样没有经验的程序员。


任何提示,指示,想法非常感谢。谢谢!
>I wrote a simple VB.NET application that imports and edits CSV files.

Now I''d like to "lock" the raw (pre-import) CSV files so these cannot be
opened separately. It is not high-sensitive data, I just don''t want folks
to
peek in the files.

So time-consuming encryption is not necessary, just a simple
password-to-open that I can program in my application so it internally
opens
the imported CSV file would be perfect, but I can''t get it done. In fact
it
seems difficult to password-protect a CSV file in any way.

The pre-import CSV''s are delivered as ZIP''s, so I thought about
password-protecting the ZIP files and importing and unzipping these within
my
program, but this would seem much more challenging (if at all possible)
especially for an inexperienced programmer like me.

Any tips, pointers, ideas are highly appreciated. Thanks!



比尔,这似乎是一个好主意,但我刚刚保存了一个295 kB的CSV文件作为1451

kB XLS文件:看起来文件大小增加了近5倍。这是一个严肃的

支付的价格。


感谢您的建议,但仍然向其他人保持开放

文件大小的检查。谢谢。


-joni


" Bill Voorhees"写道:
Bill, that seemed a great idea but I just saved a 295 kB CSV file as a 1451
kB XLS file: it appears the filesize increases almost 5X. That''s a serious
price to pay.

Appreciate your suggestion, but still open to others that may keep the
filesize in check. Thanks.

-joni

"Bill Voorhees" wrote:

一个简单的解决方案是保存为excel文件,密码保护它,删除csv

文件。当您需要csv文件时,打开excel文件并保存为csv文件。


" jonigr" < jo **** @ discuss.microsoft.com写信息

新闻:FB ************************ ********** @ microsof t.com ...
one easy solution is to save as excel file, password protect it, delete csv
file. When you need the csv file, open the excel file and save as csv file.
"jonigr" <jo****@discussions.microsoft.comwrote in message
news:FB**********************************@microsof t.com...

我写了一个简单的VB.NET应用程序,用于导入和编辑CSV文件。 br />

现在我想锁定原始(预导入)CSV文件因此不能单独打开
。这不是高敏感度的数据,我只是不想要人们来这些文件。


所以不需要耗时的加密,只需要一个简单的

密码即可打开,我可以在我的应用程序中编程,这样它就可以在内部打开
打开

导入的CSV文件将是完美的,但我无法完成它。实际上



似乎很难以任何方式密码保护CSV文件。


预导入CSV'这是以ZIP的形式发送的,所以我想到了

密码保护ZIP文件并导入和解压缩这些内容

我的

程序,但这似乎更具挑战性(如果可能的话)

特别是像我这样没有经验的程序员。


任何提示,指示,想法非常感谢。谢谢!
I wrote a simple VB.NET application that imports and edits CSV files.

Now I''d like to "lock" the raw (pre-import) CSV files so these cannot be
opened separately. It is not high-sensitive data, I just don''t want folks
to
peek in the files.

So time-consuming encryption is not necessary, just a simple
password-to-open that I can program in my application so it internally
opens
the imported CSV file would be perfect, but I can''t get it done. In fact
it
seems difficult to password-protect a CSV file in any way.

The pre-import CSV''s are delivered as ZIP''s, so I thought about
password-protecting the ZIP files and importing and unzipping these within
my
program, but this would seem much more challenging (if at all possible)
especially for an inexperienced programmer like me.

Any tips, pointers, ideas are highly appreciated. Thanks!






您无法用密码保护CSV文件的原因是因为

定义没有地方存储密码。这是一个

逗号分隔值的文件。为了让任何程序都能识别出来,我不能随意在某个地方声明密码。


你有两个标准的解决方案。一种是创建自己的文件格式

,其中包含一个密码字段plus。一个csv文件。你的应用程序会知道

密码是什么,并且可以检查它,并且它会知道CSV开始的偏移量

。请记住,虽然这可能会阻止新手它

不会阻止任何具有相对普通技能的人,他们可能会用记事本打开

文件,并注意到一个非常好的CSV文件几个字节到

看起来像密码的权利。


另一个解决方案(正如你所提到的)是加密文件将

阻止大多数人,因为你的应用程序是唯一可以解密它的人。它b / b
并不一定非常耗时,但显然需要一些时间。

也许不会比提示用户输入密码更长

当然用户不会将密码粘贴在他们的显示器上的贴子(bm)上。


" jonigr" < jo **** @ discuss.microsoft.com写信息

新闻:FB ************************ ********** @ microsof t.com ...
The reason that you cannot password protect a CSV file is because by
definition there is no place to store the password. It''s a file of
"comma-separated values" for that to be recognized by any program one can''t
arbitrarily declare a password is inside it somewhere.

You have two standard solutions. One is to create your own file format
which consists of a password field "plus" a csv file. Your app would know
where the password is and can check it and it would know the offset where
the CSV begins. Keep in mind that while this may stop the novice it
wouldn''t stop anybody with relatively ordinary skills who might open the
file with say Notepad and notice a perfectly good CSV file a few bytes to
the right of something that looks like a password.

The other solution (as you mentioned) is to encrypt the file which would
stop most people as your app would the only one that could decrypt it. It
doesn''t have to be time-consuming but obviously it would take some time.
Perhaps not much longer than it would to prompt the user for a password and
of course the users wouldn''t stick the password on a post-it (tm) note on
their monitor.

"jonigr" <jo****@discussions.microsoft.comwrote in message
news:FB**********************************@microsof t.com...

>我写了一个简单的VB.NET应用程序,用于导入和编辑CSV文件。


现在我想锁定原始(预导入)CSV文件因此不能单独打开
。这不是高敏感度的数据,我只是不想要人们来这些文件。


所以不需要耗时的加密,只需要一个简单的

密码即可打开,我可以在我的应用程序中编程,这样它就可以在内部打开
打开

导入的CSV文件将是完美的,但我无法完成它。实际上



似乎很难以任何方式密码保护CSV文件。


预导入CSV'这是以ZIP的形式发送的,所以我想到了

密码保护ZIP文件并导入和解压缩这些内容

我的

程序,但这似乎更具挑战性(如果可能的话)

特别是像我这样没有经验的程序员。


任何提示,指示,想法非常感谢。谢谢!
>I wrote a simple VB.NET application that imports and edits CSV files.

Now I''d like to "lock" the raw (pre-import) CSV files so these cannot be
opened separately. It is not high-sensitive data, I just don''t want folks
to
peek in the files.

So time-consuming encryption is not necessary, just a simple
password-to-open that I can program in my application so it internally
opens
the imported CSV file would be perfect, but I can''t get it done. In fact
it
seems difficult to password-protect a CSV file in any way.

The pre-import CSV''s are delivered as ZIP''s, so I thought about
password-protecting the ZIP files and importing and unzipping these within
my
program, but this would seem much more challenging (if at all possible)
especially for an inexperienced programmer like me.

Any tips, pointers, ideas are highly appreciated. Thanks!



这篇关于我可以以某种方式密码保护导入前的CSV文件吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆