在MFC 8.0中创建打开和保存对话框 [英] Creating Open and save dialog box in MFC 8.0

查看:80
本文介绍了在MFC 8.0中创建打开和保存对话框的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

HI,
我在mfc8.0(Visual Studio 2005)中为二进制文件创建了一个打开并保存对话框,要求提供文件指针来访问该文件.打开文件后,需要获取该文件的副本(应为该文件分配大约20kb的内存)以进行编辑,然后进行更新(保存).除了使用malloc之外,还有其他在MFC中分配内存的替代方法吗?请帮助我的代码.....
请在文件指针"上输入一些信息,这是软件领域的新手. 文件指针"表示不指向内存中分配的文件.了解也许指向CFile对象的指针.

请在不断发展的职业中向每个人展示您要讨论的代码.


即使在MFC项目中分配内存的方式也独立于MFC(换句话说,框架与MFC无关)内存分配).因此,您的问题没有多大意义.使用malloc/free或new/delete有什么问题?

也许您需要澄清您的问题,并发布一些适用的代码以帮助我们了解您面临的问题.


HI,
I created a open and save dialog box for a binary file in mfc8.0(visual studio 2005),requires to provide file pointers to access the same. After opening a file, required to get a copy of that (should allocate a memory for the file approx 20kb )for editing and then updated(Save). Is thier any alternate way of allocating memory in MFC other than using malloc? Please Help me out with the code.....
Please give some inputs on File pointers , i''m new to software field.

解决方案

you are misunderstanded it. "File pointers" means not to point to allocated files in memory. Instand that maybe pointers to CFile-objects.

Please show EVERYTIME in your progreamming career the code you want to discuss.


The way you allocate memory even within MFC projects is independent of MFC (in another words, the framework has nothing to do with memory allocation). So your question doesn''t make that much sense. What''s wrong with using malloc/free or new/delete?

Maybe you need to clarify your question, and post some applicable code to help us understand the issue you are facing.


这篇关于在MFC 8.0中创建打开和保存对话框的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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