How can i open VB app in another computer? - vb.net

I am a begginer with visual basic. I made an app that contains pictures, 2 databases with sql server 2008 and a lot of controls. I'm trying to run that app in differente computers that are not connected, i am talking about over 15 computers. What files do i need to copy from my vb app and sql server so it can work in the other computers?

Is the app in Microsoft Access? If so all you have to do is copy that Access Database to all those computers and the SQL Server should just work with those separate copies seamlessly.
We run a few legacy apps in VBA/Access still with SQL Server backends. It's better than most people realize because of how easy it is to modify the only problem is they cant just refresh when you make updates, you have to re-copy the whole Access App to their computer everytime you update it.

Related

Deploying a Windows Form App in C# for multiple users with SQL Server. Alternatives for databases?

I'm working on a database driven program in Visual Studio 2015, in C#, Windows Form Application, and I'm using SQL Server 2014 for my databases, downloaded the most recent version from the MSDN site.
I've got it working well. But if I want other users on other computers and different versions of Windows, this would require them to have SQL Server installed, correct?
Basically the app is used for storing current medications, moods, a mood quiz, symptoms, etc.. and I store all the results in SQL Server databases. They can be edited, deleted, etc through the program's GUI. Do the users need SQL Server installed to use this app?
If so, is there an alternative to keeping databases without having to have the SQL Server connections, or is there a way to do this without the users having to have SQL Server installed? I don't want remote connections to me, I want it standalone.
Does this make any sense? If not, I can explain more. I know way back in the days of Visual Basic 4 I was making, reading and writing databases without SQL. But that was 16 years ago. So I'm wondering what the easiest solution to this is. Thanks!
In other words, you want a database that you can a) distribute to end users freely and b) that will 'connect' just to the copy of the database they have stored locally.
Here are a few options ---
SQLite over ODBC is as-easy-to-use as MSSQL, the driver can be found here:
SQLite ODBC
Use ConfigurationManager.OpenExeConfiguration to read / write your app config .xml file and use it as a key / value store. I can provide examples if needed.
Dynamically create an Access database, it should work as well as MSSQL for most things, with less overhead. Here's how:
Create an Access Database
Use SQLIte DLL. Details on SO
create-sqlite-database-and-table

Access by multiple users to access database

I am not very familiar with Access database till now i was only programming to SQL Server but now it's time to do so. I am building WinForms application which will be using Access database and i have some question related to that point if you don't mind. My application will be used by multiple users and there will be one access databsae. My questions as below:
Is there any problem with accessing access database in same time by many users or only one user can be connected?
If i develop my program to use access 2016 and some of my users will have diffrent windows version and also diffrent access version
will it works?
Should i know something else? :)
If your client want to have a file based database and this is a project constraint , MS Access is the best choice. If you want a more detailed advice, please let me know how many users will perform Read/Write or Read transactions, the size of the database and if the application will run in client-server mode in a LAN/WAN, Cloud or Remote Desktop environment.
Back to your questions:
Depending on these conditions you may range from 10 to 20/25 users. Remember that you can always try with MS Access and later upgrade to a MS SQL database in a couple of hours.
If your front-end application can link to a 2016 Access database, it will do that without installing MS Access to the clients that will run your App, i.e. the vb.net compiled App will install all needed drivers. If you develop your App within MS Access 2016 (Access Form and reports, some VBA) you can run it with the free runtime version of MS Access, but this only when no older version of Access is installed on the running workstation.
Please check with your client the real reasons for a file-based database...
To answer the questions as asked:
You might run into an issue with this, as access was really designed as a personal use database. Having anything more than a small handful of users hitting against it at once will in fact cause problems, as it's not really well designed for that purpose...
This should in theory be fine, as the application itself is interfacing with the database, not the end user...
It seems like you're taking a step backwards using access for this, and SQL might very well be better suited for this purpose. This isn't me trying to just bash access either, this comes from personal experience. Going with this sort of design is likely to cause you more headaches than good.

Light database server options for a small business application

Hi there and many thanks in advance, Im veeery newby.
I am building a small visual basic 2010 application and I need a better choice for my database (around 20 tables), since now Im using SQL server express 2008 and as far as I understand it is too big and complicated for me (just installing it was a pain for me)
I am looking for an application that will be easy to distribute (maybe just an installer and thats it!) and that can run without problems on old computers with windows xp.
The last thing is that I want to have to chance to install just a client version of my app on a computer and tell it to connect to the database wich will be running on other computer on the same LAN (or maybe on a web server on the future!).
In other words I would like to have the option of selecting "where" is the database to read/write on.
I will thank advices for this implemtation and will respond if somebody needs more details before answering.
Well installing sqlserver in not rocketscience al you need to execute .exe .
Though if you looking for opensource database then have a look at mongodb
MySql is open source and quite easy to use, especially with a tool like PHP MyAdmin:
http://www.mysql.com/

SQL Database in VB.NET Application

I'm fairly newb when it comes to programming and even newer when it comes to database management and integration.
So I have a VB.NET Windows Application that uses a SQL Database. I use LINQ to SQL to fill datagridviews in windows that show table data and also use LINQ to SQL to save data to the database.
All works wonderfully however...
When I publish the application, the database isn't external as far as I can tell. It seems to build itself into the application so once the application is installed, the database is there, it views and saves data, but if the computer crashes or the application is uninstalled, all that data is going to be lost without a way to back it up.
I'm using Visual Studio 2010 Express. I created the SQL Database in VS2010-Exp as well. I feel like there's something simple I'm missing here. When the application gets published and then installed, where is the physical database going?
Thanks!
It is running as part of the application. If you wanted a separate, central database, you would need to have an instance of SQL server running in some accessible location.

How to connect sql database compact edition on visual studio 2008 with vb.net (smart device)

I'm doing a project with vb.net (smart device) on visual studio 2008 and I need to connect to a database on the device itself (I do not have a physical device to test, only emulation). How should I go about doing it? I would like the database to be in the device on start up.
I've read on the internet that you have to make a reference to System.Data.SqlServerCe but the documents are, in my opinion, vague. So, I'm pretty lost here.
So there are two questions here:
How do I deploy my database so it's there when my app starts?
How do I access that database from my app?
Both are straightforward.
A1. You have a couple options. First, understand that SQLCE databases are a single file, typically with an SDF extension. You can either package it with your app for deployment, so you know it will be there on first run, or your app can check for its existence on startup and crete the file if it's not there. If you need to populate the initial database with data (lookups, etc) then option 1 is probably better. As long as you deploy/crete the database in a persistent storage location (and under WinMo/Pocket PC that's pretty much anywhere), it will always be there when your app starts up.
A2 You are correct that you need to add a reference to System.Data.SqlServerCe, which is again straightforward. Just add a reference in your smart device project:
Once you've done that, you use the SqlServerCe namespace objects to create the database, tables, indexes, etc, insert and query data, and all of that good stuff. Tutorials 2 and 3 on MSDN here are a really good start and they have VB.NET examples. The nice thing is that most desktop examples for VB.NET accessing a SQLCE database will work as-is on the device, and the things that don't work are usually in the presentation of the data, not the actual database access code itself.