|
Thanks for the reply.
I am downloading file from server to localhost using windows application.
but I am using web service for file info and localpath.
Thanks
sjs4u
|
|
|
|
|
Let's start with, your code is a bloody disaster.
1 - do you REALLY intend to deploy this code with localhost as the URL ? So, it will only run on the machine it's deployed to, never to a server ?
2 - your code obviously won't build a full path correctly, as there's no slash between myApp and test.doc.
3 - the Path class will let you build paths cleanly, most of the time.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
Let's Say
I am downloading test.doc file to this path(localhost path) :
string localfile = http://localhost/myApp/test.doc
Now it showing me the error. I am using windows application.I added web service in that project.
I am using Fileinfo Class where I am getting error
FileInfo f = new FileInfo(localfile);
Regards,
sjs4u
|
|
|
|
|
sjs4u wrote: . I am using windows application
OK, now I am stunned.
1 - what the hell are you doing in the ASP.NET forum if you're writing a windows program ?
2 - what makes you assume that localhost points to ANYTHING, let alone what you want it to, if you're writing a windows app ?
3 - why do you assume your end user has localhost configured properly to run this app ?
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
hiii....
i have generated crystal report now i want that the report gets generated based on user
input.like when user give date range,name or anyother input then respective report get generated.
can u plz give me some idea or a link that how cud i do this.thnks in advance......
|
|
|
|
|
use the following code it may help
CrystalReportViewer1.SelectionFormula = "{timetableofteacher1.tid}=" + DropDownList1.SelectedValue + " and {timetableofteacher1.tname}='" + TextBox1.Text + "'";
if it helps let me know
|
|
|
|
|
hii didnt get u exactly.
wat is {timetableofteacher1.tid} and timetableofteacher1.tname
|
|
|
|
|
|
thnks i will go thru it....
|
|
|
|
|
i have to build the image viewer in C#.net application
these images would be displayed from the access database
any ideas how to start building it
or any tutorials suggessted for the beginners
either i have to use GDI+ or not
how i should start studying ???
plz can any one help
|
|
|
|
|
Use ADO.net to get the image from DB.
|
|
|
|
|
and wht about buiding a viewer???
|
|
|
|
|
|
Well, that depends. Does this question have ANYTHING to do with ASP.NET ? I doubt it does. Viewing images is trivial.
Christian Graus
Driven to the arms of OSX by Vista.
Read my blog to find out how I've worked around bugs in Microsoft tools and frameworks.
|
|
|
|
|
I have a VS2005 ASP.NET website which makes use of a custom class, DButils, which is located in the App_Code folder. Things are good when I run the application in the IDE.
I have now decided to deploy it to the "production" server which is a hosted server from Network Solutions. I'm using the "Copy Website" function and FTP to get the site to the production server. When I try to run my test page, I get the error that "Type 'dbUtils' is not defined."
What am I missing here ? It runs fine in the VS2005 IDE. I've developed other webstites using my same methodology and deployed it to "in-house" production servers and everything went fine.
Is this a limitation on the "Network Solutions" server ? I can't find anything helpful on their website about deploying ASP.NET applications. They say that they support ASP.NET, but I don't understand how.
Does anyone have any insight on this ?
|
|
|
|
|
Well... Is it the exact error you are talking about ?
Dbutils and dbUtils are different in case of C#.. ...
Actually app_code gets compiled into one dll and places itself into the bin folder. You can check if the file is there or not. Check in which line the error is coming. See if there is actually any mistake or not.
I dont think IIS couldnt read the app_code.dll file, as it would give some other error then .
Really makes no sense of whats wrong .... Check thoroughly ... you can find one definitely.
|
|
|
|
|
The exact error message is "Compiler Error Message: BC30002: Type 'dbUtils' is not defined."
The code is written in VB, so capitalization shouldn't make a difference, although I checked it out and the spelling of the class is "dbUtils". That is also how I have it referenced on my page's code behind.
Interesting Note: I can't seem to find any "bin" folder being created. Would it show up in the solution explorer ?
I believe I started this as a "New Website", not a new "ASP.NET Web Application". I'm not sure of the exact differences.
Remember that my method of deployment to the IIS server was to use FTP and copy the files and folders from my VS2005 IDE up to the website. I don't see any bin folder and I believe the .NET framework would compile each page as it is visited.
|
|
|
|
|
Yes ... You cant see bin folder in your solution environment as it is excluded from the solution.
Moreover, asp.net compiles each page on first request, and stores it in server cache.. .But it doesnt compile app_code. It should be compiled and deployed, AFAIK.
Now if you dont see the dll, I think you need to compile the project. As I never used direct FTP upload to deploy web site, I cant help you much.. but If you publish your website in a folder, you would surely see the app_code is compiled to a dll.
|
|
|
|
|
Hello,
Thank you for reading. Here is my situation. I have a masterpage with a tablerow that has a few webuser controls inside of <td>. one of my content page is a gridview with item templates,on clicking on a row it shows up a AJAX modalpopup with a button and on click and increments count by 1 in a database table. The webuser control mentioned above gets the count from the db and displays the count. For example when the user first comes in for example, lets say the webusercontrol A shows -Hello XYZ, you have 2 items in your shopping cart. Then the user goes to my page with the gridview and clicks on an item and says add to cart. This would increment in the db the count to 3. I want the webuser control in my masterpage to get this value immediately and display -You have 3 items in your shopping cart. How can I achieve this with updatepanels and how do i trigger a postback for the webusercontrol in my masterpage? All help is greatly appreciated, if you have any code samples or links that do something similar that would be wonderful !!
Thanks
RH
|
|
|
|
|
Well,
Actually if you write the code to fetch data from the database and restore to a label... in the Page_load section of the Masterpage, the job will be quickly done...
Just get the value from database each time and place the message on the screen.
|
|
|
|
|
After you capture the event from the Modal window have a public Sub in your user control that you can call that updates the UC. You can either pass the values into the usercontrol or requery the DB, I would just pass the values in if you already know them.
It would be something like this in the content page, then the corresponding sub in the User Control
Dim oUC As MyUserControlType = CType(Master.FindControl("UserControlName"), MyUserControlType)
oUC.UpdateMe(NewValue)
|
|
|
|
|
Hi...
I have to read one Text file & i have to store content of text file into Database.
Which is the best way to implement this task.
Because text file will update each & every midnight.
I can create one windows service which will run at specify time and store content in the DB....
Is there any other way to implement this task except windows service??
|
|
|
|
|
Hemant_ec48 wrote: Is there any other way to implement this task except windows service??
Another way would be to write a console application(for eg) and schedule it run at specific time.
But, IMO windows service is a nice approach to follow.
Manas Bhardwaj
Please remember to rate helpful or unhelpful answers, it lets us and people reading the forums know if our answers are any good.
|
|
|
|
|
Aha... I didn't see your response
Abhijit Jana | Codeproject MVP
Web Site : abhijitjana.net
Don't forget to click "Good Answer" on the post(s) that helped you.
|
|
|
|
|
Sorry My friend for let reply but i was busy in meeting....
Should i use SSIS from this task...
If I create one DTSX Package And if i use that Package from SQL Job
I do not have Proper Idea Regarding this .....
But I am getting one advice to implemet this one....
If you have any idea regarding this than Please help me....
|
|
|
|