Solved

load crystal report from client machine

Posted on 2009-05-04
12
546 Views
Last Modified: 2013-12-17
Hello,

I work for a large organisation and they have tasked me to make a website for the display of there crystal reports. I am not authorized to upload the reports to the server so I must get Crystal Report viewer to read from the clients local machine C:\GISDATA\Reports\....rpt. how can i do this as the app thinks I am referencing a file from the c:\ on the server..???

Thanks
0
Comment
Question by:Small_Balls
  • 5
  • 3
  • 3
12 Comments
 
LVL 100

Assisted Solution

by:mlmcc
mlmcc earned 80 total points
ID: 24301713
If it is running on the server, I don't think you can unless you can identify the machine by ip address or name.

Any particular reason you aren't allowed to put the reports on the server?

mlmcc
0
 
LVL 4

Assisted Solution

by:bleach77
bleach77 earned 60 total points
ID: 24301880
I'm not sure about this, but if a client share the files in network, you can try call the report using "\\ip_address\folder\rptfiles"

Or maybe if it will be from only one client, you can set the client to be another server and call it on there.
0
 

Accepted Solution

by:
Small_Balls earned 0 total points
ID: 24302068
mlmcc:
If it is running on the server, I don't think you can unless you can identify the machine by ip address or name.

Any particular reason you aren't allowed to put the reports on the server?

Govt agency! (enough said lol)

bleach77:
I'm not sure about this, but if a client share the files in network, you can try call the report using "\\ip_address\folder\rptfiles"

Or maybe if it will be from only one client, you can set the client to be another server and call it on there

I unless i looks for the ip addess that won't work as it needs to target all that log in for agencies in govt department endless number of possible ips

also refer to this post as covered ground (same post)

http://forums.asp.net/p/1418970/3140580.aspx#3140580
0
 
LVL 4

Assisted Solution

by:bleach77
bleach77 earned 60 total points
ID: 24302155
First of all, a webpage alone can't access (read/write) a client files. enough said.
So you can't put the rpt on clients hard drive neither can you read the rpt from client hard drive.

So what are you trying to accomplish here is not possible.
0
 
LVL 4

Assisted Solution

by:bleach77
bleach77 earned 60 total points
ID: 24302170
My best solution would be for you to setup another server , maybe your computer, and from the main server, it will called the rpt files from your computer.
0
How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

 

Author Comment

by:Small_Balls
ID: 24302336
I don't take not possible as an answer and the cost involed in equipment, time, effort and parts is not an option

to you think this will work??
            string reportPath = (@"C:\GISDATA\Reports\");

            string[] reports = Directory.GetFiles(reportPath, "*.rpt");

Open in new window

0
 
LVL 100

Assisted Solution

by:mlmcc
mlmcc earned 80 total points
ID: 24304496
I worked for the government for almost 30 years and never had a problem getting permission to put shared files on network drives.

Normally you will have a shared drive that all users have access to for saving files that need to be shared.  You could put the reports on that drive in a special folder and reference them with the full path as
//Server-Name/CrystalFolder/myreport.rpt

Another way to do this would be to embed the reports into the application.  Thus there is no need for the report files.

I see a major issue with putting them on the clients.  Unless a report is used by only 1 user there is a huge update issue when a report is changed to ensure all users have the latest version.  Also if a report file is on a users machine there is the potential that they could change the report.

Have you considered using Crystal Report Server or some similar product to run reports and control access?

mlmcc
0
 

Author Comment

by:Small_Balls
ID: 24304822
Crystal Report Server is in the pipe line but red tape between here and there in the meantime i need to access the report from the client machine as if it was on the server it would not be up to date in a few months and staff do not have access to change them they are distributed to C:\GISDATA\Reports via a network up date.

all I need is a way to tell the server to read from the clients machine and not its own drives and with out             string reportPath = ("http://" + Response.Write(Request.ServerVariables("remote_addr"))+"/GISDATA/Reports/");

0
 
LVL 100

Assisted Solution

by:mlmcc
mlmcc earned 80 total points
ID: 24305417
Sorry, that is the way the interface is written.  It cannot be done since the applicatiion by default is going to look on the machine it is running on for C:.  You will need to put the name of the machine or the IP in the path.

mlmcc
0
 
LVL 100

Assisted Solution

by:mlmcc
mlmcc earned 80 total points
ID: 24318859
As stated in the EE Help sometimes the correct answer is it can't be done
http://www.experts-exchange.com/help.jsp?hi=405

WIth that in mind the full points should be awarded to the first 2 comments or perhaps use
http:Q_24302170 - bleach77 since that is the solution you have chosen to pursue.

mlmcc
0
 
LVL 100

Expert Comment

by:mlmcc
ID: 24321915
there is a solution and we have given it to you.

The only way a web application that is running on the server can address a client box is through the fully qualified box name or the ip address for that box.

The other solutions are to use an existing network drive to hold the report files or as you are planning to do add a new server/network store and use it.

mlmcc
0

Featured Post

Top 6 Sources for Identifying Threat Actor TTPs

Understanding your enemy is essential. These six sources will help you identify the most popular threat actor tactics, techniques, and procedures (TTPs).

Join & Write a Comment

More often than not, we developers are confronted with a need: a need to make some kind of magic happen via code. Whether it is for a client, for the boss, or for our own personal projects, the need must be satisfied. Most of the time, the Framework…
A long time ago (May 2011), I have written an article showing you how to create a DLL using Visual Studio 2005 to be hosted in SQL Server 2005. That was valid at that time and it is still valid if you are still using these versions. You can still re…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…
You have products, that come in variants and want to set different prices for them? Watch this micro tutorial that describes how to configure prices for Magento super attributes. Assigning simple products to configurable: We assigned simple products…

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

9 Experts available now in Live!

Get 1:1 Help Now