Language: ChineseGermanSpanishFrenchDutchItalianRussian
123 Flash Chat Forums

Go Back   TOPCMM Community > SWFKit > SWFKit Support

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 05-01-2003, 04:50 AM
Senior Member
 
Join Date: Feb 2003
Posts: 212
Default TCP/IP network

- I've build a program with swfkit that lets the user add and view data to a database. The program should be accessed by various users.

Now, i've stumbled to some problems.
I've installed the program on one pc of the network.
Is there a way to allow all the users of the network to have acces to the database.
When I tried it, I ve got the message theat the database could not be opened.
What am i doing wrong.

(I can't uses php, because, the program should also have to work on a standalone pc)
Reply With Quote
  #2 (permalink)  
Old 05-02-2003, 11:11 PM
Senior Member
 
Join Date: Jan 2001
Posts: 413
Default Re: TCP/IP network

If you want your users to connect your database directly, you'd better make sure all your users in your lan and all of them can be trusted,or else it's not secure.

Otherwise, you should make a server app and a client app, then distribute the client app to your users.
In this way, only the server app can access the database. If the client want to add or view data in a database, the client send a message to the server to make server app do it. The communication between the server app and client app is realized by socket object.It's a secure way.
Reply With Quote
  #3 (permalink)  
Old 05-03-2003, 03:09 AM
Senior Member
 
Join Date: Feb 2003
Posts: 212
Default Re: TCP/IP network

I've build in a script so that the user must have the right password before he can change anything.
But how can I let the user connect directly to the database through TCP/IP
Reply With Quote
  #4 (permalink)  
Old 05-04-2003, 03:11 AM
Senior Member
 
Join Date: Jan 2001
Posts: 413
Default Re: TCP/IP network

You can connect your database using ODBC or the database provider,tell me what kind of database u are using
oracle , mysql, sql server,or db2, or something else? I can give u some sample codes .
Reply With Quote
  #5 (permalink)  
Old 05-04-2003, 04:55 AM
Senior Member
 
Join Date: Feb 2003
Posts: 212
Default Re: TCP/IP network

I'm using an acces database.
And the connection works on a standalone pc.
But the error only occures when I trie to acces the database on another pc of the network from within my pc.

Maybe its better if I could tell you a little bit more about my application.
I'm a primary school teacher. And I've made a whole bunch of worksheets about several problems the children can have. I trie to organise these worksheets (pdf-files) like this:
Within my program, I can click on a difficulty, and then I get a list and preview of all the worksheets I have about that difficulty. I can also print out the worksheets directly.
I've build in a function so I can add a new worksheet and give comments about these worksheets.
The program then copies the pdf file to a directory in the application directory. All the comments, paths , .. are saved in an acces database. The program worked fine. And several colleges were very interested.
So they asked me to build a version that we could keep on one pc in the schools network, where every college could add their worksheets. All the worksheets would then be collected on the directory on that pc ( another problem on wich I don't have a solution yet.)
Now, every college should be able to acces and add worksheets to the program from within their pc. And thats where the error occures. I can't seem to acces the database on the other pc!
Hope this helps to capture the problem

Thanks
Kurt

Reply With Quote
  #6 (permalink)  
Old 05-06-2003, 11:02 AM
Senior Member
 
Join Date: Dec 2002
Posts: 2,015
Default Re: TCP/IP network

Hi,

I think all other computers must have privilege to access the pc your database placed in. And users should input the user name and password for the pc first. SWFKit does not provide any method to validate the pasaword for a Microsoft Network. But we can build an activex object for you if you really need it.

Providing your database is placed in pc "MYMDB", you can access the database like this,
Code:
var dbname = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=\\MYMDB\\mypath\\mymdb.mdb";
var conn = new ActiveXObject("ADODB.Connection");
conn.open(daname);
You can also copy a file to the pc like this,
Code:
ver f = new File("1.pdf");
f.copy("\\MYMDB\\mypath\\pdf\\1.pdf");
The program cannot access the database before you have logged onto the pc.


If you want your project to serve more and more users, perhaps a web based application is more suitable. Users can use your application via internet, on Windows, Linux or Unix. And they needn't have to download an exe file, they just need to open the Web browser and input the web address. You should construct a Web Server, either IIS or apache, migrate your FFish script codes to asp or php. FFish script is very similar with jscript, if you use asp.net, I think the migration might be very easy. To let users upload pfds, you can use an upload component. There are many free upload component.

SWFKit is more suitable for building standalone applications. You can create a home version of your project for your students by using SWFKit without network access.

Of course, if you haven't so many users in one network, SWFKit is enough
Reply With Quote
Reply

Was this information helpful?    Yes No



Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT. The time now is 05:56 AM.


Powered by vBulletin® Version 3.7.1
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.1.0 ©2007, Crawlability, Inc.