Sep 6th, 2001, 11:57 PM
#1
Thread Starter
Fanatic Member
Editor in VC++
Hi everybody. This is a Text Editor made by me. It's not made in MFC.
Attached Files
Last edited by prog_tom; Sep 7th, 2001 at 02:48 AM .
prog_tom
JOIN THE REVOLUTION!!!! Dual T3 backedup science community.
http://physics.sviesoft.com/forum
Sep 7th, 2001, 05:48 AM
#2
Thread Starter
Fanatic Member
Suggestions?
Any Suggestions regarding this Text Editor? This will not be the Final Release of this Editor Series
prog_tom
JOIN THE REVOLUTION!!!! Dual T3 backedup science community.
http://physics.sviesoft.com/forum
Sep 7th, 2001, 05:55 AM
#3
I would next implement loading.
Then a proper file selection mechanism (common dialogs, it's easy)
Then maybe a menu.
All the buzzt
CornedBee
"Writing specifications is like writing a novel. Writing code is like writing poetry."
- Anonymous, published by Raymond Chen
Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.
Sep 7th, 2001, 06:05 AM
#4
Thread Starter
Fanatic Member
Commen Dialogs?
How to load a Common Dialog?
prog_tom
JOIN THE REVOLUTION!!!! Dual T3 backedup science community.
http://physics.sviesoft.com/forum
Sep 7th, 2001, 06:05 AM
#5
Also made without MFC (the MFC version took about 1/10 of the time, and has more features).
This program lets you search a word by number in a file. You supply the number (Bearbeiten->Set Highlight) and it will mark this word in the text.
I accidently posted a only half translated version.
Datei -> File
Bearbeiten -> Edit
Window -> Fenster
Attached Files
All the buzzt
CornedBee
"Writing specifications is like writing a novel. Writing code is like writing poetry."
- Anonymous, published by Raymond Chen
Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.
Sep 7th, 2001, 06:13 AM
#6
Thread Starter
Fanatic Member
Common Dialogs
Can you tell me how to load a Common Dialog in VC++ Win32 Programming, please?
prog_tom
JOIN THE REVOLUTION!!!! Dual T3 backedup science community.
http://physics.sviesoft.com/forum
Sep 7th, 2001, 06:21 AM
#7
the header is commdlg.h
You have to declare an OPENFILENAME structure and fill it's members (see MSDN)
And you call GetOpenFileName or GetSaveFileName
Then get the information you want from the now modified ofn
then proceed as usual
All the buzzt
CornedBee
"Writing specifications is like writing a novel. Writing code is like writing poetry."
- Anonymous, published by Raymond Chen
Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.
Sep 7th, 2001, 06:22 AM
#8
this is what I used in my app
not very elgant but effective
Attached Files
All the buzzt
CornedBee
"Writing specifications is like writing a novel. Writing code is like writing poetry."
- Anonymous, published by Raymond Chen
Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.
Sep 7th, 2001, 07:23 AM
#9
Monday Morning Lunatic
Code:
HeapFree(GetProcessHeap, 0, *ppszContent);
GetProcessHeap()
I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
-- Linus Torvalds
Sep 7th, 2001, 07:42 AM
#10
Thread Starter
Fanatic Member
Menu?
prog_tom
JOIN THE REVOLUTION!!!! Dual T3 backedup science community.
http://physics.sviesoft.com/forum
Sep 7th, 2001, 07:43 AM
#11
Monday Morning Lunatic
MSDN, and search for CreateMenu.
I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
-- Linus Torvalds
Sep 7th, 2001, 10:01 AM
#12
Thread Starter
Fanatic Member
Common Dialogs?
Sorry about this, I really got messed up... Would anyone place a code that only does the Common Dialogs part? Thanks
prog_tom
JOIN THE REVOLUTION!!!! Dual T3 backedup science community.
http://physics.sviesoft.com/forum
Sep 7th, 2001, 12:09 PM
#13
Frenzied Member
Here is a fregment from one of my apps.
PHP Code:
OPENFILENAME ofn ;
long retval ;
TCHAR * szFullPathName ;
szFullPathName = new TCHAR [ 512 ];
lstrcpy ( szFullPathName , "" );
memset (& ofn , 0 , sizeof ( OPENFILENAME ));
ofn . lStructSize = sizeof ( OPENFILENAME );
ofn . hwndOwner = hDlg ;
ofn . nFilterIndex = 1 ;
ofn . lpstrFile = szFullPathName ;
ofn . nMaxFile = 512 ;
ofn . lpstrInitialDir = "c:\\" ;
ofn . lpstrFilter = "Text Files(*.txt)\0*.txt\0All Files(*.*)\0*.*\0" ;
ofn . lpstrDefExt = "txt" ;
retval = GetSaveFileName (& ofn );
if( retval != 0 )
{
//do something
}
Sep 7th, 2001, 12:20 PM
#14
Monday Morning Lunatic
Originally posted by Vlatko
PHP Code:
ofn . lpstrInitialDir = "c:\\" ;
ofn . lpstrFilter = "Text Files(*.txt)\0*.txt\0All Files(*.*)\0*.*\0" ;
Looks like they got messed up by the parser.
ofn.lpstrInitialDir = "c:\\";
ofn.lpstrFilter = "Text Files(*.txt)\0*.txt\0All Files(*.*)\0*.*\0";
Code:
ofn.lpstrInitialDir = "c:\\";
ofn.lpstrFilter = "Text Files(*.txt)\0*.txt\0All Files(*.*)\0*.*\0";
Last edited by parksie; Sep 7th, 2001 at 03:04 PM .
I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
-- Linus Torvalds
Sep 7th, 2001, 03:01 PM
#15
Member
Re: Editor in VC++
Originally posted by prog_tom
Hi everybody. This is a Text Editor made by me. It's not made in MFC.
What a nice, sexy clean UI.
Sep 8th, 2001, 04:24 PM
#16
PowerPoster
Sep 12th, 2001, 11:48 PM
#17
Thread Starter
Fanatic Member
Ahh!!!
Come on guys. I'm waiting for my damn Flight(#NW070) from Northwest Airlines... Orgin: Shanghai, Destination: Little Rock. Connect in Detroit. So I can't mess around with you guys much. Damn. Can't believe they destroyed the great World Trade Center!!! And the Pentagon!@!!@$#
prog_tom
JOIN THE REVOLUTION!!!! Dual T3 backedup science community.
http://physics.sviesoft.com/forum
Sep 13th, 2001, 06:49 AM
#18
PowerPoster
Are you alone on the flight(without your parents)?
Sep 13th, 2001, 07:07 AM
#19
Thread Starter
Fanatic Member
Yeah
That's right All alone. Without my parents But due to the incident in the US. All planes to the US will be cancelled. Well they say it's going to be open on the 15th...
So I'm damn tired here in Shanghai.
prog_tom
JOIN THE REVOLUTION!!!! Dual T3 backedup science community.
http://physics.sviesoft.com/forum
Sep 13th, 2001, 07:55 AM
#20
PowerPoster
Sep 13th, 2001, 08:04 PM
#21
Thread Starter
Fanatic Member
Yes
You are kind of right Try this code:
VB Code:
Dim i as Long
Dim myname as String
Dim yours as String
Dim yourage as Long
Private Sub Form_Load()
i=13
myname="Tom Zhang"
yours="Abdul"
yourage="234078324"
MsgBox "Hi, I'm " & myname & " and you are " & yours & " you are " & yourage & " years old. and I'm " & i & " age old."
End Sub
Ha ha
Damn NWA!
prog_tom
JOIN THE REVOLUTION!!!! Dual T3 backedup science community.
http://physics.sviesoft.com/forum
Posting Permissions
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
Forum Rules
Click Here to Expand Forum to Full Width