E-book Thanks... Looking for a simple template for Ebook I need to have a template for pubblish my books. No extern files,please, all inside the .exe I need only one .exe file. I need: - a window :-) - a simple menu (each voice for each chapter of book and Exit) Like this: FirstMenu MENU { POPUP "&Title of Book" { MENUITEM "&Capitolo I" MENUITEM "&Capitolo II" MENUITEM SEPARATOR MENUITEM "E&xit" } } - an edit control (read only) Please, don't tell me to read #12 tutorial of Iczelion. :-) I don't need to open file and save it. I need only one file. When the window open there should just be there the Introduction of Book. And then I may change and go to desidered chapter by menu. Thanks a lot g.
Posted on 2001-01-24 05:00:00 by giorgio
giorgio, I think the going rate for writing software to order is about $150.00 US per hour, you may be stuck with having to learn how to write your own template if you wish to publish programming technical data. Regards, hutch@pbq.com.au
Posted on 2001-01-24 06:19:00 by Steve Hutchesson
I'd do it for $135.00 per hour :)
Posted on 2001-01-24 07:20:00 by JimmyClif
To Steve Hutchesson Thanks a lot... :-) First: I'm not a programmer... and I dont't have to pubblish programming technical data. But my books about my research. Second: I don't ask a template only for me... but for everyone that need it open, free, call as you like... If you can help me ...thanks Thanks for your works about Masm32 Thanks a lot ...about the compiler g.
Posted on 2001-01-24 07:21:00 by Giorgio
I think the theme of this board (though I may be wrong) is a "if you want it, you do it" kind of thing, but with the added "if you have a problem, if no one else can help, if you can find them maybe you can ask - the people at the Win32asm message board!" So if you want to try programming it yourself, and you run into trouble, don't hesitate to ask! But asking us to do it for you, is a no-no, I for one am usually too busy drinking Gin for this programming stuff ;) Mirno
Posted on 2001-01-24 08:32:00 by Mirno
Besides, if we write something that goes into an ebook, do we get royalties, credits, billable time, et al? You see, it would be no different than if SAMS(r) publishing told me, "hey, we're publishing a book on assembly language programming, but we need you to submit some samples for us"... I would say, "Sure, $180/hr plus credits. Possibly royalties if that's not pushing it. It would then ask why the author is writing a book that he is not able to come up with his own info, and I would probly avoid buying it for that reason. You see, nothing is free. Shawn doesn't do homework, and I don't to "freebies", either. =P
Posted on 2001-01-24 14:40:00 by _Shawn
Please... listen me... I don't have to publish an ebook about assembly! I'm looking for a template for do an ebook made by assembly language. Simple and small. A template with an simple edit control, not a rich edit one... ok... May anyone help me? Thanks... g.
Posted on 2001-01-25 00:12:00 by giorgio
hm hm, nothing to do yet... so... ->don't know exactly what you want but try this... note: you must have the resource definition file and a icon ("icon.ico" see rsrc.rc!) to run this! ---code.asm--- .386 .model flat, stdcall option casemap :none include \masm32\include\windows.inc include \masm32\include\user32.inc include \masm32\include\kernel32.inc includelib \masm32\lib\user32.lib includelib \masm32\lib\kernel32.lib DlgProc PROTO :DWORD,:DWORD,:DWORD,:DWORD .DATA DlgName db "MyDialog",0 MenuName db "MyMenu",0 text0 db "introduction" db 13,10,"bla",13,10 db "bla bla bla" db 13,10,"bla",13,10 db "bla" db 13,10,"bla",13,10 db "bla" db 13,10,"bla",13,10,0 text1 db "capter 1",0 text2 db "capter 2",0 .DATA? hInstance dd ? .CONST IDM_C1 equ 1 IDM_C2 equ 2 IDM_EXIT equ 3 IDC_EDIT equ 3000 .CODE start: invoke GetModuleHandle, NULL mov hInstance,eax invoke DialogBoxParam, hInstance, ADDR DlgName,NULL,addr DlgProc,NULL invoke ExitProcess,eax DlgProc PROC hWnd:DWORD, uMsg:DWORD, wParam:DWORD, lParam:DWORD .IF uMsg == WM_INITDIALOG invoke SetDlgItemText,hWnd,IDC_EDIT,addr text0 .ELSEIF uMsg == WM_CLOSE invoke EndDialog, hWnd,NULL .ELSEIF uMsg == WM_COMMAND mov eax,wParam .IF ax == IDM_C1 invoke SetDlgItemText,hWnd,IDC_EDIT,addr text1 .ELSEIF ax == IDM_C2 invoke SetDlgItemText,hWnd,IDC_EDIT,addr text2 .ELSEIF ax == IDM_EXIT invoke SendMessage,hWnd,WM_CLOSE,NULL,NULL .ENDIF .ELSE mov eax,FALSE ret .ENDIF mov eax,TRUE ret DlgProc endp END start ---rsrc.rc--- #include "resource.h" #define IDM_C1 1 #define IDM_C2 2 #define IDM_EXIT 3 #define IDC_EDIT 3000 MyIcon ICON "ICON.ICO" MyDialog DIALOG 64, 93, 129, 39 STYLE DS_MODALFRAME | 0x804L | WS_OVERLAPPED | WS_VISIBLE | WS_CAPTION | WS_SYSMENU | WS_MINIMIZEBOX CAPTION "ebook" MENU MyMenu FONT 8, "MS Sans Serif" { CONTROL "", IDC_EDIT, "EDIT", ES_LEFT | ES_MULTILINE | ES_AUTOVSCROLL | ES_READONLY | WS_CHILD | WS_VISIBLE | WS_BORDER | WS_VSCROLL | WS_TABSTOP, 10, 10, 110, 70 } MyMenu MENU { POPUP "&Title of ook" { MENUITEM "&Captitolo I", IDM_C1 MENUITEM "C&apitolo II", IDM_C2 MENUITEM SEPARATOR MENUITEM "E&xit", IDM_EXIT } }
Posted on 2001-01-25 02:46:00 by drcmda
Thanks...:-) May anyone help me to learn how can use findresource, loadresource, blockresource how may I define a text (long text) resources in .rc file how may call it inside edit control Sendmessage... anyone may explain me, please? Thanks... g. This is my today work for template: asm code: .386 .model flat,stdcall option casemap:none WinMain proto :DWORD,:DWORD,:DWORD,:DWORD include \masm32\include\windows.inc include \masm32\include\user32.inc include \masm32\include\kernel32.inc include \masm32\include\comdlg32.inc includelib \masm32\lib\user32.lib includelib \masm32\lib\kernel32.lib includelib \masm32\lib\comdlg32.lib .const IDM_CHAP1 equ 1 IDM_CHAP2 equ 2 IDM_CHAP3 equ 3 IDM_CHAP4 equ 4 IDM_CHAP5 equ 5 IDM_NAME equ 6 IDM_EXIT equ 7 MAXSIZE equ 260 MEMSIZE equ 65535 EditID equ 1 .data ClassName db "Win32ASMEditClass",0 AppName db "Title of E-Book and Name of Author",0 EditClass db "edit",0 MenuName db "FirstMenu",0 ofn OPENFILENAME <> FilterString db "All Files",0,"*.*",0 db "Text Files",0,"*.txt",0,0 buffer db MAXSIZE dup(0) .data? hInstance HINSTANCE ? CommandLine LPSTR ? hwndEdit HWND ? hFile HANDLE ? hMemory HANDLE ? pMemory DWORD ? SizeReadWrite DWORD ? .code start: invoke GetModuleHandle, NULL mov hInstance,eax invoke GetCommandLine invoke WinMain, hInstance,NULL,CommandLine, SW_SHOWDEFAULT invoke ExitProcess,eax WinMain proc hInst:HINSTANCE,hPrevInst:HINSTANCE,CmdLine:LPSTR,CmdShow:DWORD LOCAL wc:WNDCLASSEX LOCAL msg:MSG LOCAL hwnd:HWND mov wc.cbSize,SIZEOF WNDCLASSEX mov wc.style, CS_HREDRAW or CS_VREDRAW mov wc.lpfnWndProc, OFFSET WndProc mov wc.cbClsExtra,NULL mov wc.cbWndExtra,NULL push hInst pop wc.hInstance mov wc.hbrBackground,COLOR_WINDOW+1 mov wc.lpszMenuName,OFFSET MenuName mov wc.lpszClassName,OFFSET ClassName invoke LoadIcon,NULL,IDI_APPLICATION mov wc.hIcon,eax mov wc.hIconSm,eax invoke LoadCursor,NULL,IDC_ARROW mov wc.hCursor,eax invoke RegisterClassEx, addr wc INVOKE CreateWindowEx,WS_EX_CLIENTEDGE,ADDR ClassName,ADDR AppName,\ WS_OVERLAPPEDWINDOW,CW_USEDEFAULT,\ CW_USEDEFAULT,500,400,NULL,NULL,\ hInst,NULL mov hwnd,eax INVOKE ShowWindow, hwnd,SW_SHOWNORMAL INVOKE UpdateWindow, hwnd .WHILE TRUE INVOKE GetMessage, ADDR msg,NULL,0,0 .BREAK .IF (!eax) INVOKE TranslateMessage, ADDR msg INVOKE DispatchMessage, ADDR msg .ENDW mov eax,msg.wParam ret WinMain endp WndProc proc uses ebx hWnd:HWND, uMsg:UINT, wParam:WPARAM, lParam:LPARAM .IF uMsg==WM_CREATE INVOKE CreateWindowEx,NULL,ADDR EditClass,NULL,\ WS_VISIBLE or WS_CHILD or ES_LEFT or ES_MULTILINE or\ ES_AUTOHSCROLL or ES_AUTOVSCROLL,0,\ 0,0,0,hWnd,EditID,\ hInstance,NULL mov hwndEdit,eax invoke SetFocus,hwndEdit mov ofn.lStructSize,SIZEOF ofn push hWnd pop ofn.hWndOwner push hInstance pop ofn.hInstance mov ofn.lpstrFilter, OFFSET FilterString mov ofn.lpstrFile, OFFSET buffer mov ofn.nMaxFile,MAXSIZE .ELSEIF uMsg==WM_SIZE mov eax,lParam mov edx,eax shr edx,16 and eax,0ffffh invoke MoveWindow,hwndEdit,0,0,eax,edx,TRUE .ELSEIF uMsg==WM_DESTROY invoke PostQuitMessage,NULL .ELSEIF uMsg==WM_COMMAND mov eax,wParam .if lParam==0 .if ax==IDM_CHAP1 mov ofn.Flags, OFN_FILEMUSTEXIST or \ OFN_PATHMUSTEXIST or OFN_LONGNAMES or\ OFN_EXPLORER or OFN_HIDEREADONLY invoke GetOpenFileName, ADDR ofn .if eax==TRUE invoke CreateFile,ADDR buffer,\ GENERIC_READ or GENERIC_WRITE ,\ FILE_SHARE_READ or FILE_SHARE_WRITE,\ NULL,OPEN_EXISTING,FILE_ATTRIBUTE_ARCHIVE,\
Posted on 2001-01-25 11:39:00 by giorgio