News:

Masm32 SDK description, downloads and other helpful links
Message to All Guests

Main Menu

Webserver assembles with nothing happens

Started by RonNYC, March 16, 2013, 04:01:10 AM

Previous topic - Next topic

RonNYC

I downloaded the Cinchy server:

http://www.piclist.com/techref/inet/win32asm/index.htm

fixed up the rc reference. Here's the RC file:

#include "c:\masm32\include\resource.h"

i ICON "s3.ico"

Form1 DIALOG 0,0,80,40
STYLE 0x0004 | DS_CENTER | WS_CAPTION | WS_OVERLAPPED | DS_MODALFRAME | DS_3DLOOK | WS_SYSMENU
CAPTION "Cinchy server"
CLASS "DLGCLASS"
BEGIN
    EDITTEXT,1000,0,0,80,10,ES_AUTOHSCROLL
    LISTBOX,1001,0,26,80,0,LBS_SORT
    CHECKBOX,"Dir enabled",1002,0,30,50,8,BS_AUTOCHECKBOX
    PUSHBUTTON,"Pick Dir",1003,50,28,30,12
    LTEXT,"",1004,0,10,80,8
    LTEXT,"",1005,0,18,80,8
END

YET, when I run the app, it runs (I can see it in the taskmgr) but nothing happens.

Any suggestions? (Not exactly new to masm but it's been a long, long time.)

RON

RonNYC


RonNYC

It runs, but when I try to do something (not even sure what I can do), I get a beep. The app comes up; I can select a directory but....that's it.

RON

dedndave

i had to do 2 things to get it to build:

1) in the cinchy.rc file
#include "\masm32\include\resource.h"
2) i had to add an icon to the project folder, as s3.ico was not available on the site
i tried to download the exe from the link above to use the icon from that, but got an error page

it seems to work fine
there are 2 ways to use it:

1) if you want to allow a directory view, check the "Dir enabled" box
2) otherwise, you must provide an index.html file in the public folder

to test it, you can open a browser on the same computer and go to http://192.168.1.100/
i might change that address, as it may conflict with a router - not sure   :P

i opened a browser on another computer on the same LAN
it says i should be able to open it with the computer name, but that didn't work
i probably need to enable sharing or something for that to work

i was, however, able to access the folder from the other computer via http://192.168.1.100/

i did not test it from outside the LAN
it says you should be able to just use the IP

dedndave

i found this thread in the old forum

http://www.masmforum.com/board/index.php?topic=2148.0

i have those attachments, if you are interested
but, the guys in that thread were saying that a FASTServer is a better way to go

dedndave

so, i searched for FASt Server a bit
it was a project by James Ladd that seems to have been dropped
however, there are a few remnants around

he has a site
www.jamesladdcode.com/category/assembly-language-programming/
the site seemed a little slow   :P

the project had a long thread in the old forum
http://www.masmforum.com/board/index.php?topic=431.0

the only thing i could find on the code was this
https://gist.github.com/jamesladd/720718
it builds as a console app, but i didn't take the time to figure out how to use it   :biggrin:

there was another project in the win32 forum that was based on FASt Server

japheth

Quote from: RonNYC on March 16, 2013, 05:02:19 AM
It runs, but when I try to do something (not even sure what I can do), I get a beep. The app comes up; I can select a directory but....that's it.

Yes, the directory that you choose will become the "root" directory of the web server. After that, the server program will just wait for someone trying to connect to it via port 80 (http).

To connect, the simplest way is to use a browser on the very same computer and enter: "http://localhost/". In this case, the directory that you have chosen must contain a file index.htm. If there is no such file in the directory, you'll have to explicitly tell the browser what file it is to display: "http://localhost/myfile.txt".

dedndave

if you check the "Dir enabled" box, you don't have to create an html   :P


RonNYC

Greatly appreciate these pointers, and tips. I did select a folder, both with dir enabled checked and unchecked and localhost, or http://localhost, or even http://localhost:80 all return 404.

I'll check out those links over the next few days.

THANKS!!!

RON
(trying to get back into asm)

Gunther

Hi RonNYC,

Quote from: RonNYC on March 17, 2013, 12:21:59 AM
THANKS!!!

RON
(trying to get back into asm)

and welcome to the forum.

Gunther
You have to know the facts before you can distort them.

RonNYC

THANKS!!! I hope my semi beginner's problems don't weight people down.

I reassembled the app; I changed some text, adding XX just to validate the code was properly being called. I added XX to the dialog box text and that appeared. BUT when I tried to go to 192.168.1.100 which is my IPv4 address I get a generic 404 web page, not one from cinchy b/c I added XX to it and that didn't appear.

RON

Gunther

Hi RonNYC,

Quote from: RonNYC on March 18, 2013, 02:09:46 AM
THANKS!!! I hope my semi beginner's problems don't weight people down.

No. It's a very helpful forum here with a good atmosphere.

Gunther
You have to know the facts before you can distort them.

RonNYC

Sorry, I meant the XX did appear; it all worked perfectly, just nothing happens. I mean, any web access returns 404 but not 404 from the app.

dedndave

perhaps you made a mistake of some sort
here is what i have

it is either the program, or the method, or both
this will eliminate one   :P

RonNYC

Well, it seems to be exactly what I have. When I run it, I can pick the dir where index.htm is located and I do. Then, in my browser, I type 192.168.1.100 and I get 404; doesn't matter it seems what I type. There doesn't seem to be a web server running while it is running...or am I missing something? or expecting the wrong thing?

RON