C转到C ++ [英] C going to C++

查看:60
本文介绍了C转到C ++的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经使用C一段时间了,我想把我的第一次飞跃

加入到C ++中。我应该警告你,我很少或没有使用Visual B / C $ C ++的经验,虽然我对不同的OOP语言有一些经验。


我使用的是Microsoft Visual C ++ 6.0。


我想创建一个非常简单的程序:


一个对话框,比如320x240,使用file->退出和帮助 - >关于菜单。

在框内将是一个输入字段,您可以在其中键入您的号码,并使用

按钮''去''。

在那将是另一个文本字段,如果它是一个数字,它将给你2 *你输入的内容

,否则它会弹出带错误框说

请在框中输入整数和小数


所以这就是我到目前为止所做的:

创建一个新的Win32应用程序项目名为thetest。

然后我创建一个新的C ++源文件。称为thesource并将其添加到

工作区" thetest" ;.

我去''插入 - >资源 - >菜单''并创建菜单

我将资源保存为''menu.rc''和''menu.rc''到''资源文件''
$ b $ ''文件视图'中的b文件夹'

这是我无法获得的教程或说明,以获得进一步的优惠。

我不知道如何从C ++源文件中获取我已包含在项目中的资源




如果有人可以通过一步一步跟进指令或可以运行我的URL

,那将非常方便。谢谢。


另外,如何从工作区中删除文件/资源​​?右键菜单中没有

''删除''项目!


谢谢。

解决方案

Kevin Torr写道:

我已经使用C一段时间了,我想把我的第一次飞跃进入C ++。我应该警告你,我很少或没有使用可视化C ++的经验,虽然我对不同的OOP语言有一些经验。

我使用的是Microsoft Visual C ++ 6.0。

我想创建一个非常简单的程序:

一个对话框,大小为320x240,文件 - >退出和帮助 - >关于菜单。 />在框内将是一个输入字段,您可以在其中键入您的号码,并在
按钮上显示Go。
在此下面将是另一个文本字段,它将为您提供2 *的内容如果它是一个数字,你之前输入
,否则会弹出一个错误框
说请在框中输入只有整数和小数。

所以这个是我到目前为止所做的:
创建一个新的Win32应用程序项目名为thetest。
然后我创建一个新的C ++源文件。称为thesource并将其添加到
工作区thetest。
我去''插入 - >资源 - >菜单''并创建菜单
我将资源保存为''menu.rc''和''menu.rc''到''文件视图'中的''资源文件''
文件夹''

这是我可以得到的没有教程或指示
让我更进一步。
我不知道如何访问我拥有的资源从C ++源文件中包含到项目中。

如果有人可以通过一步一步的说明或URL来跟进我,它会非常方便。谢谢。

另外,如何从工作区中删除文件/资源​​?右键菜单中没有
''删除''项目!

谢谢。




详细讨论使用任何特定的IDE都是这个

新闻组的禁忌。有一个非常有用的常见问题解答,你可以很好地阅读。

人们往往很难坚持所讨论的指导原则

。如果您有与C ++相关的问题,这是一个讨价还价的好地方。如果您有与VC ++相关的问题,我相信您可以在常见问题解答中找到

资源的链接。如果您对新手性质有疑问,请尝试在常见问题解答中找到答案,如果常见问题解答不清楚,或者无法解决

问题,然后发布问题。这是常见问题:

http: //www.parashift.com/c++-faq-lite/

在Stroustrup的网站上还有一个学习C ++新闻组的地方。
http://www.research.att.com/~ bs / C ++。html


我的经验是尝试学习C ++,简单的方法是行不通的。

即你,你单击图标和IDE中的菜单选项不会到达。

FAQ中列出了一些书籍。考虑获得一个或三个。

你也可以在微软的开发者网站上逛一逛。我,

个人,不做Windoze,但我知道他们有一些很好的资源。

我的建议是远离任何IDE特定的东西,直到你得到用C ++中的
接地。

-

p-> m ==(* p).m == p [0]。 m
http://www.kdevelop.org
http://www.suse.com
http://www.mozilla.org




Kevin Torr <柯******* @ hotmail.com>在留言中写道

news:40 *********************** @ news.syd.swiftdsl.c om.au .. 。

我已经使用C一段时间了,我想把我的第一次飞跃带到C ++中。我应该警告你,我很少或没有使用
visual C ++的经验,虽然我对不同的OOP语言有一些经验。


到目前为止一直很好。

我正在使用Microsoft Visual C ++ 6.0。


学习C ++并不是很相关。

我想创建一个非常简单的程序开始于:


好​​。

一个对话框,比如320x240,文件 - >退出和帮助 - >关于菜单。 />在框内将是一个输入字段,您可以在其中键入您的号码,并在
按钮上显示Go。


C ++没有对话框,或菜单或按钮。

在那个下面将是另一个文本字段,它会给你2 *你
如果它是一个数字,则先输入,否则会弹出一个错误框,说明
请在框中输入整数和小数。

这就是我所做的到目前为止:
创建了一个新的Win32应用程序项目名为thetest。
然后我创建一个新的C ++源文件。称为thesource并将其添加到
工作区thetest。
我去''插入 - >资源 - >菜单''并创建菜单
我将资源保存为''menu.rc''和''menu.rc''到''文件视图'中的''资源文件''
文件夹''

这是我可以得到的没有教程或指示
让我更进一步。
我不知道如何访问我拥有的资源从C ++源代码文件中包含到项目


如果有人可以通过这个步骤跟进任何指令或可以运行
的URL,它会非常方便。谢谢。

另外,如何从工作区中删除文件/资源​​?右键单击菜单中没有
删除项目!



您似乎对C ++和Visual C ++感到困惑。 Visual C ++是一个开发

环境,您的问题都是关于如何使用该工具的。因此

它们与C ++语言(或C语言

)无关。


学习C ++正在学习一门新语言,如果那是你想要做的话那么好,请在这里问你的C ++问题。另一方面,学习如何编程

Windows或如何使用Visual C ++并不需要你学习C ++(Visual

C ++是一个非常好的C编译器)。 br />

尝试新闻:microsoft.public.vc.ide_general以获取有关Visual C ++
开发工具的帮助(您可以在Microsoft的新闻服务器上找到它

news.Microsoft.com如果你的服务器没有携带它)。尝试使用

news:comp.os.ms-windows.programmer.win获取Windows编程问题。


john


>尝试新闻:comp.os.ms-windows.programmer.win用于Windows编程

问题。




应该是


新闻:comp.os.ms-windows.programmer.win32

john


I''ve been using C for some time now and I would like to take my first leap
into C++. I should warn you that I have little or no experience with visual
C++, though I do have some experience with different OOP languages.

I am using Microsoft Visual C++ 6.0.

I would like to create a very simple program to begin with:

A dialog box, say 320x240 in size, with file->exit and help->about menus.
Inside the box will be an input field where you type in your number, and a
button that says ''Go''.
Under that will be another text field which will give you 2* what you typed
previously if it''s a number, otherwise it pops up with an error box saying
"Please enter only integers and decimals into the box".

So this is what I have done so far:
Created a new "Win32 application" project called "thetest".
I then create a new "C++ Source File" called "thesource" and add it to the
workspace "thetest".
I go up to ''insert -> resource -> menu'' and create the menu
I save the resource as ''menu.rc'' and ''menu.rc'' to the ''Resource Files''
folder in the ''File View''

This is about as far as I can get without a tutorial or instructions to get
me further.
I''m not sure how to access the resources I have included to the project from
the C++ source file.

If someone could followup with either instructions or a URL that can run me
through this step-by-step, it would be very handy. Thanks.

Also, How do I remove files/resources from my workspace? There is no
''delete'' item in the right-click menu!

Thanks.

解决方案

Kevin Torr wrote:

I''ve been using C for some time now and I would like to take my first leap
into C++. I should warn you that I have little or no experience with
visual C++, though I do have some experience with different OOP languages.

I am using Microsoft Visual C++ 6.0.

I would like to create a very simple program to begin with:

A dialog box, say 320x240 in size, with file->exit and help->about menus.
Inside the box will be an input field where you type in your number, and a
button that says ''Go''.
Under that will be another text field which will give you 2* what you
typed previously if it''s a number, otherwise it pops up with an error box
saying "Please enter only integers and decimals into the box".

So this is what I have done so far:
Created a new "Win32 application" project called "thetest".
I then create a new "C++ Source File" called "thesource" and add it to the
workspace "thetest".
I go up to ''insert -> resource -> menu'' and create the menu
I save the resource as ''menu.rc'' and ''menu.rc'' to the ''Resource Files''
folder in the ''File View''

This is about as far as I can get without a tutorial or instructions to
get me further.
I''m not sure how to access the resources I have included to the project
from the C++ source file.

If someone could followup with either instructions or a URL that can run
me through this step-by-step, it would be very handy. Thanks.

Also, How do I remove files/resources from my workspace? There is no
''delete'' item in the right-click menu!

Thanks.



Detailed discussions of the use of any particular IDE are taboo in this
newsgroup. There''s a very helpful FAQ which you would do well to read.
People tend to be pretty tough about sticking to the guidelines discussed
therein. If you have C++ related questions, this is a good place to ask
them. If you have VC++ related questions, I believe you can find links to
resources in the FAQ. If you have questions of a newbie nature, try to
find the answer in the FAQ, if the FAQ isn''t clear, or doesn''t address the
question, then post the question. Here''s the FAQ:

http://www.parashift.com/c++-faq-lite/

There''s also a learning C++ newsgroup listed somewhere on Stroustrup''s site.
http://www.research.att.com/~bs/C++.html

My experience has been that trying to learn C++ the easy way doesn''t work.
I.e., you won''t get there by clicking icons, and menu selections in an IDE.
There are some books listed in the FAQ. Consider getting one or three.
You may do well to poke around on Microsoft''s developer''s site as well. I,
personally, don''t do Windoze, but I do know they have some good resources.
My advice is to stay away from anything IDE specific until you get grounded
in C++.
--
p->m == (*p).m == p[0].m
http://www.kdevelop.org
http://www.suse.com
http://www.mozilla.org



"Kevin Torr" <ke*******@hotmail.com> wrote in message
news:40***********************@news.syd.swiftdsl.c om.au...

I''ve been using C for some time now and I would like to take my first leap
into C++. I should warn you that I have little or no experience with visual C++, though I do have some experience with different OOP languages.

So far so good.
I am using Microsoft Visual C++ 6.0.

Not very relavent to learning C++.
I would like to create a very simple program to begin with:

Good.
A dialog box, say 320x240 in size, with file->exit and help->about menus.
Inside the box will be an input field where you type in your number, and a
button that says ''Go''.
C++ has no dialog boxes, or menus or buttons.
Under that will be another text field which will give you 2* what you typed previously if it''s a number, otherwise it pops up with an error box saying
"Please enter only integers and decimals into the box".

So this is what I have done so far:
Created a new "Win32 application" project called "thetest".
I then create a new "C++ Source File" called "thesource" and add it to the
workspace "thetest".
I go up to ''insert -> resource -> menu'' and create the menu
I save the resource as ''menu.rc'' and ''menu.rc'' to the ''Resource Files''
folder in the ''File View''

This is about as far as I can get without a tutorial or instructions to get me further.
I''m not sure how to access the resources I have included to the project from the C++ source file.

If someone could followup with either instructions or a URL that can run me through this step-by-step, it would be very handy. Thanks.

Also, How do I remove files/resources from my workspace? There is no
''delete'' item in the right-click menu!


You seem confused between C++ and Visual C++. Visual C++ is a development
environment and your questions are all about how to use that tool. As such
they have no relevance on a group about the C++ language (or C language
either).

Learning C++ is learning a new language, if that is what you want to do then
fine, ask your C++ questions here. On the other hand learning how to program
Windows or how to use Visual C++ does not require that you learn C++ (Visual
C++ is a perfectly good C compiler).

Try news:microsoft.public.vc.ide_general for help with the Visual C++
development tool (you can find this on Microsoft''s news server
news.Microsoft.com if your server doesn''t carry it). Try
news:comp.os.ms-windows.programmer.win for Windows programming questions.

john


> Try news:comp.os.ms-windows.programmer.win for Windows programming
questions.



Should be

news:comp.os.ms-windows.programmer.win32

john


这篇关于C转到C ++的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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