Welcome, Guest: Register On Nairaland / LOGIN! / Trending / Recent / New
Stats: 3,150,706 members, 7,809,686 topics. Date: Friday, 26 April 2024 at 01:06 PM

Please Help! Difficulty In Deploying A Finished And Running Vb.net Project - Programming - Nairaland

Nairaland Forum / Science/Technology / Programming / Please Help! Difficulty In Deploying A Finished And Running Vb.net Project (4991 Views)

[Project] CGPA Mgt System VB.NET Project: Come In Let's Share Ideas On This / .NET C#/VB.NET Project in the Pipeline for Programmers who may be interested / Help In Deploying My Java .exe File With Jvm (2) (3) (4)

(1) (2) (Reply) (Go Down)

Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by nnayere1: 10:33am On Jul 26, 2011
Hi! i developed a mini payroll system with VB.NET using Visual studio 2008 professional edition and Microsoft Access as the back end and it run perfectly when i debugged. I then, deployed it to a DVD and installed it in another system and when i loaded it and tried to login, it showed error; cant find the path/location to the database/server. its trying to frustrate me. please help me because am not really tight yet. My number; 07031557301
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by Kobojunkie: 10:51pm On Jul 27, 2011
Are you certain that when you deployed your application, you updated the connectionString for your Database?, you know, Domain Name, log in, etc?
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by nnayere1: 11:37am On Jul 28, 2011
@Kobojunkie

Its a windows application. I don't know how its updated. Please help me. I'm new into this and deployment is my problem now. I would be glad to hear from you again.
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by nnayere1: 11:48am On Jul 28, 2011
i have tried including the neccessary files in the prerequisites under the publishin property of the project and it brings much error. i was asked to specify a valid UNC path which i don,t know what it means . i have tried browsing but no success yet. please help if you can. i just need, if possible, a nice tutorial on deployment.
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by Kobojunkie: 6:53pm On Jul 28, 2011
Possible issues you

a) ConnectionString is not formatted correctly for the machine you have deployed to. Here is a link to a website to help you update your connection if that is the problem. If you built the application yourself, you should know where the connection string in stored. I can't help with that from here .

http://www.connectionstrings.com/access-200730

b) You do not have access installed on the machine you have deployed your db to. You may want to check event viewer to get a better idea of the exact error that your application might be throwing. If you do not know how to do this, please google for answers.
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by VURN(m): 12:27am On Jul 31, 2011
I've finally deployed it by changin the connection string so the database will be in drive c of any computer but another problem while runnin it is that the reports can't load. This is really stressful.
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by dellnet: 5:03am On Jul 31, 2011
This issue has been discussed countless times here. The first problem is you assume if you have C drive in your development computer everyone should have C but I could have Z drive on my computer so you should ask yourself how do you go about it. You don't need to worry about if the target computer is running on C drive or D drive infact you should not have anything like C:\ or D:\ referencing a path in your code, just copy your resources to the same deployment folder as your exe  and call System.Windows.Forms.Application.StartupPath in your code to get the fullpath of where your program is residing on the system.

for example declare a global variable
Dim db_path As String = System.Windows.Forms.Application.StartupPath & "\" & "access.mdb"
change access.mdb to your access database name, the file should be in the same folder as the exe. Use Microsoft Jet Library as your connection string e.g

dim provider as string ="Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & db_path & ";User Id=admin;Password=;"

To test System.Windows.Forms.Application.StartupPath in your IDE put the db file in your bin/debug folder or bin/release folder of your project.

This should make your project deploy-able to any Windows O/S
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by Beaf: 3:36pm On Jul 31, 2011
^
The bin is the wrong place to put (users might run into permission and write issues), Asp.NET has special folders. It should go in App_Data, it has the right security and permissions pre set up.
The debug folder is well out of the question, because release builds should be deployed for all sorts of reasons, especially security. You don't want to write the whole World a letter revealing vital info about your local file paths in your pdb's. Your pdb's should be release versions.

For those new to .NET, the Asp.NET has special folders are:

App_Code Folder
Bin Folder
App_Data Folder
App_Theme Folder
App_Browser Folder
App_WebReference Folder
App_LocalResource Folder
App_GlobalResource Folder
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by dellnet: 7:25am On Aug 01, 2011
this thread is talking about vb.net windows application not asp.net applications.
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by nnayere1: 11:30am On Aug 01, 2011
Guys I'm impressed with your replies. yes, i am talking about windows application and not web. So, why is it that after deploying an application, the crystal doesn't find the path to its source. how can the data source string be changed in design view if you discover this? In fact, you guys are opening my head. Thank you all. Thumbs up! @DELL_NET
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by dellnet: 2:33pm On Aug 01, 2011
What do you mean by crystal?
what type of data connection are you using? ADO, ADO.NET, OLEDB
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by VURN(m): 12:54am On Aug 02, 2011
Sorry, i mean crystal report. I'm using oledb. Thank you.
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by dellnet: 6:59am On Aug 02, 2011
A simple was to view your report


       
Dim SQL As String = "SELECT * FROM accounts" 'change to proper sql statement
        Dim conStr As String = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & db_path & ";"
        Dim myOleDbConnection As OleDb.OleDbConnection = New OleDb.OleDbConnection(conStr)
        Dim adp As System.Data.OleDb.OleDbDataAdapter = New System.Data.OleDb.OleDbDataAdapter(SQL, myOleDbConnection)
        Dim dataset As New DataSet
        adp.Fill(dataset, "accounts"wink 'change to real table

        Dim rpt As New CrystalDecisions.CrystalReports.Engine.ReportDocument
        rpt.Load(System.Windows.Forms.Application.StartupPath & "\customer.rpt"wink 'change to real file
        rpt.SetDataSource(dataset)
        CrystalReportViewer1.ReportSource = rpt
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by VURN(m): 9:48pm On Aug 02, 2011
@dell_net
Bros You're too much. You're of great assistance. I apply the codes and with little modifications, they work for me. Programming is just interestin wit you guys. Pls assist me wit any book on developing complex projects. I'll be very grateful. Thanks and God bless.
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by dellnet: 7:37am On Aug 03, 2011
Usually at the end of some pedagogy text there are some real life applications to deal with,,,I can't point you to any text but the best practice is you come up with what you want to develop, collect information from those in the application's industry and just build it,,,We will be of help to assist you through if you get stuck.
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by VURN(m): 11:03pm On Aug 05, 2011
@dell net
thanks for the reply. Please, i seem to be having little problem in the report creation. I did everythin and included the codes with the necessary modifications but the error message is :fail to load report. Its been so hard to succeed in i creating at least, one simple report. Thanks for your concern.
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by dellnet: 1:48am On Aug 06, 2011
put the report in the same folder as your .exe
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by VURN(m): 9:03pm On Aug 06, 2011
Bros thank you. But i tried it by copyin the report from the bin folder to the same folder with the set up. The same error message, "fail to load report". I just wish i could send it to you to do it for me. I really appreciate your assistance. Its actually my final year project i'm battlin with like this. Thanks broo
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by dellnet: 4:57am On Aug 07, 2011
If you can successfully view the report in your development environment i.e. running from IDE and you are testing your application on Windows Vista and above then I suspect you are having UAC issue. What you need to do is change the level of execution in your application manifest.

To get to your application manifest in visual studio, click project-> * properties. In the editor window Click Application->View UAC settings. In the file that show, change the line <requestedExecutionLevel level="asInvoker" uiAccess="false" /> to <requestedExecutionLevel level="requireAdministrator" uiAccess="false" />

Note: the instruction is there in comments (in green). If it still fails then I have to look at your code.

* = name of your project
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by Beaf: 10:09am On Aug 07, 2011
dell_net:

this thread is talking about vb.net windows application not asp.net applications.

Damn! My bad.
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by Kobojunkie: 4:06pm On Aug 07, 2011
@Poster, you need to have better error reporting. I am not certain if moving your files will solve this since I assume you were able to get them working on another machine in the way they are now. Are you able to check event viewer on the server machine? If yes, pLease look for detailed info on the exact exception message.
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by VURN(m): 11:12pm On Aug 07, 2011
@dell_net
I've done it as you directed and published again, it still can't load the report as it gives the same error. Would you like to see the codes? I would love it if you can publish it for me and tell me what you did. If possible Pls write to me on valvurn@yahoo.ca let me attach the source code and send to you or if you wouldn't mind, give me your email here. Thanks for your concern. Honestly, the stuff is frustrating.
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by VURN(m): 7:40pm On Aug 08, 2011
@kobojunkie
you know i'm a newbie here and honestly, some of the things You're talkin about, i don't understand. My report can't load after publishing the project. That's my problem. Pls help
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by VURN(m): 4:13pm On Aug 09, 2011
@dell net

Pls i'm still waiting for your reply.
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by dellnet: 5:32pm On Aug 09, 2011
seem you don't read your email.
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by VURN(m): 2:59pm On Aug 10, 2011
Bros sorry for the delay, i have been choked up with tight lectures and assignments. i have sent the source code to your mail as i could not send it through the file sight you provided. i am so grateful for your assistance.
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by VURN(m): 3:41pm On Aug 10, 2011
@dell net
the payroll database password is "jaypee"
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by VURN(m): 3:43pm On Aug 10, 2011
The payroll database password is jaypee
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by dellnet: 12:36am On Aug 11, 2011
there is nothing in my mailbox from you.
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by VURN(m): 7:49am On Aug 11, 2011
I compressed it to .rar and attached. Let me send again then. Thanks and take care.
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by nnayere1: 10:58am On Aug 12, 2011
@Dell net
Hope u've got it. You're really of great help to us. I had to use my partner's email to send you the file since yahoo did not support the file. Thanks for everything.
Re: Please Help! Difficulty In Deploying A Finished And Running Vb.net Project by dellnet: 11:34am On Aug 12, 2011
I sent an exe back to your partners box,,,

(1) (2) (Reply)

How To Add Icon To Visual Basic 6.0 Form / Lovely Ascii Art In C Code! / I Need Ideas On How To Develop Sms-based Applications

(Go Up)

Sections: politics (1) business autos (1) jobs (1) career education (1) romance computers phones travel sports fashion health
religion celebs tv-movies music-radio literature webmasters programming techmarket

Links: (1) (2) (3) (4) (5) (6) (7) (8) (9) (10)

Nairaland - Copyright © 2005 - 2024 Oluwaseun Osewa. All rights reserved. See How To Advertise. 35
Disclaimer: Every Nairaland member is solely responsible for anything that he/she posts or uploads on Nairaland.