|
mktdatapath=Request.Form("selmktdata")
Using that code my objective is to read the file path from where it is being upoaded.
I am using the following code to read the file.
set genfile = myfile.OpenTextFile(mktdatapath,1)
while not genfile.AtEndofStream
filecontent = genfile.readline
filearray= split(filecontent,",")
'insert data into tbl_mktdata file
ObjCon.Execute "insert into tbl_mktdata values ('"&trim(filearray(1))&"',"&cdbl(filearray(7))&")"
wend
-----------------------------------------
~JJ
hi all please clarify my doubts
|
|
|
|
|
It doesn't work like that. Request.Form("selmktdata") may tell you the path to the selected file on the local machine, but you haven't actually uploaded it to the server, and when you do the path there will be different.
You need to learn how to upload files, and save them to the server, then use that path in your OpentextFile method.
http://www.google.co.uk/search?hl=en&q=asp+upload&meta=[^]
Fred
|
|
|
|
|
Hi Fred,
Thanks for your patience;
I want to be clearer about the application.
1. It is not a web-based application. (It runs on our local machine) and we work directly on the machine where the application is configured.
2. We use this application to open the file read it and insert it into our DB (Every thing is done on a stand alone machine.)
3. This application is running smoothly for the past 3-4 years with out any issues.
4. Issue has arrised because the application has been moved to a different machine.
Your feedback is very valuable.
~Jagadeesh
hi all please clarify my doubts
|
|
|
|
|
Well I don't know then, I'm afraid... if the files are on the same machine too (if you're trying to read them across your network then it is, effectively, a web-based application) then I suspect it is, as said at the start, a permissions problem. Check your IIS settings and your windows users settings.
Fred
|
|
|
|
|
Yes, the files r on the same machine. What u suspected at the beginning is correct. It’s a permission problem. All IIS settings seem to be OK. I searched for these settings in net and the solutions did not work in my case. Running the application in windows admin mode also didn’t work in this case.
I'm seeking help in this regard. --> IIS settings and windows users settings, for trouble shooting this error.
Thank you Fred,
~Jagadeesh
hi all please clarify my doubts
|
|
|
|
|
GOT the Solution . The code is working fine now. The issue has arised here
set genfile=myfile.OpenTextFile(holdingspath,1)
because of permissions on the folders from where i am reading the files and the permissions on the (application)code folders.
Give full permissions to both folders. It works.
This link is helpful in this kind of situations.
http://www.aspemporium.com/tutorials.aspx?tid=9
Fred, Thank you very much for support.
~Jagadeesh
|
|
|
|
|
tell me the process to create a subdomain in my application
hi,
this is prasadchowdary
|
|
|
|
|
i want to create subdoamin in asp.net using C# how can i do that
hi,
this is prasadchowdary
|
|
|
|
|
I have a web form where i am created a pdf document through code. To do this, i am using a third party tool viz. ActivePDF. It takes about 5 to 10 minutes to create the document. Upon creation of the document, I am displaying the document in another page. Sometimes, what happens is i am getting the error 'page cannot be displayed' when i tried to display the document. Immediately everybody may feel that document is not available but actually the pdf document is generated. I am checking this thru code and if the file is available, then only i am displaying the pdf. the pdf size is hardly 1MB. the code is as follows
PDFCreationProcess()
if fileexists(pdf)
{
Response.write("window.open('" + pdfname + "'")");
}
pls help me urgently..
|
|
|
|
|
I feel your script might be timing out. Try increasing Server script timeout time.
Server.ScriptTimeout = 800000
Mubashir
Software Architect
Storan Technologies Inc, USA
Every job is a self portrait of the person who did it.
|
|
|
|
|
The .NET 2.0 Framework have a component for receive e-mails?
|
|
|
|
|
|
hi,
i have saved a video in my mysql database, and i want to dispaly it on my asp.net page.
th evideo is saved as BLOB type in the mysql.
can anybody help me?how can i retrive it?
thanks in advanced
|
|
|
|
|
hi.
I'm making a contact us form with asp.net 1.1 & C# .
the form has textbox which people can type their name,email and message ...
then they click the "send" button.
I want to recieve their message and name and email in my inbox not in my database!
because I have written the code which can save the message in the database.but it doesnt the thing that I want.!
I want to recieve their message and name and email in my inbox( I mean my email address inbox ).
So,please tell me how to do it ?
thank alot
|
|
|
|
|
You can do it by SMTP.
Regards,
Satips.
|
|
|
|
|
hi there:
try with System.Web.Mail Namespace
<< >>
|
|
|
|
|
|
|
Hi All,
http://www.tourneylogic.com/Products/BracketControl/Demos/V2/PopularTourneys/NCAA.aspx[^]
Can some one tell me how he has draw lines here.. is it a trick done using DIV/ CSS or using the graphic lib..
I also have asked to develop some thing similar.. I have some idea about how to go about here.. but performance wise and also cross browser compliancy wise I have some concerns.. can some one shoot couple of hints for me to correctly position myself..
High level tips should do well..
Thanks
L.W.C. Nirosh.
Colombo,
Sri Lanka.
|
|
|
|
|
I just found that it is a CSS solution as I off CSS of the browser..
Can some one give me a hint or two to do this little better than this..
L.W.C. Nirosh.
Colombo,
Sri Lanka.
|
|
|
|
|
Hi,
I need to create a login page in asp.net with password encryption, in order to login into an extranet application which has its own login page that should be hidden from the user. Make the user believe that they are loging into the application through the asp.net login page. Here the extranet application is built using java and is on sharepoint server.
Please provide info, suggestions and examples if possible for the above login page creation.
|
|
|
|
|
Hi everybody...
I`m having some problems with a web farm cenario.
The issue is: the ASP.NET create a couple of js files in one server, but when a requisition goes to another server in the web farm the file with the js function doesn`t exist.
To be more especific, I have a LinkButton on my page, and when this link is clicked it fires the 'WebForm_PostBackOptions' (which is 'undefined'sometimes).
Any hints about this problem? A web.config element configuration?
Thans you buddies
|
|
|
|
|
One thing you can do is put a value in each web.config for each server like a machine key or some other unique key then set a cookie with this key information to tie each user to that server.
At the very least this will keep the user locked to one server for that visit.
This will largely depend on how your server(s) are configured though.
|
|
|
|
|
Hey all,
I have searched all over the internet for this, but haven't found exactly what I am looking for. I am not an expert VB.Net programmer, so bear with me here. I have about 12 text and drop down boxes that will reside on a 'Customer Account Creation Request' form page. An HR rep will fill out the form with the appropriate fields and then click submit. It will then just email IT the contents of the form. My code works and all is well. My only problem is to actually format the email so it isn't just one long line of information. I am half way there, but I can't figure out how to insert the appropriate breaks and formatting. This is probably so simple, but I've never done it before in this manner so I need help! A sample of my code is below:
<code>
Dim Email As New System.Net.Mail.MailMessage( _
"email@email.com", "email@email.com")
Email.IsBodyHtml = True
Email.Subject = "New Account Creation Request"
Email.Body = "A new account was requested by " & txtRequesterFirst.Text & " " & txtRequesterLast.Text & " on " & DateTime.Now.ToString() & ". Employee Name - " & txtFirst.Text & " " & txtMiddle.Text & " " & txtLast.Text
</code>
The email.body line is just on one line, so thats why it might display weird in this post. Could someone point me in the right direction? I basically want each text box to be on its own line in the generated email. For example, the Employee Name part should be on the next line of the email and not alongside the first part of the message.
Thanks!!
-- modified at 12:56 Friday 11th May, 2007
|
|
|
|
|
You have:
Email.IsBodyHtml = True
So simply insert html <br> tags where you want them, eg:
Email.Body = "A new account was requested by " & txtRequesterFirst.Text & " " & txtRequesterLast.Text & " on " & DateTime.Now.ToString() & ".<br> Employee Name - " & txtFirst.Text & " " & txtMiddle.Text & " " & txtLast.Text
You can add any html you want:- bold, font color etc.
If you want plain text instead set
Email.IsBodyHtml = False
amd insert newlines instead, viz:
Email.Body = "A new account was requested by " & txtRequesterFirst.Text & " " & txtRequesterLast.Text & " on " & DateTime.Now.ToString() & "." & vbCrLf & "Employee Name - " & txtFirst.Text & " " & txtMiddle.Text & " " & txtLast.Text
cheers
Fred
|
|
|
|