|
This solution helped me a while back. Not sure what exactly it fixed, but it did work (for me at least):
http://forums.devshed.com/iis-97/mail-stuck-in-queue-folder-iis-smtp-virtual-server-windows-xp-service-361246.html[^]">
|
|
|
|
|
I must use this old & deprecated (by me ) object in a ASP.Net 1.1 environment... it works (aehm...) fine until I try delete the physical files I've added to the mail...
Code is like this :
.. bla bla bla...
Dim myMail As New MailMessage
myMail.From = "from@my.com"
myMail.To = "to@my.com"
myMail.Subject = "test"
myMail.Priority = MailPriority.Normal
'filename is a PDF file that exists
Dim mailAtt As New MailAttachment(sFilename)
myMail.Attachments.Add(mailAtt)
myMail.BodyFormat = MailFormat.Html
myMail.Body = xBody 'Loaded from a string
If (System.IO.File.Exists(sFilename)) Then 'to be sure
'System.IO.File.Delete(sFilename)
End If
if I delete attchment SMTP object returns me an error of "File not found" why?
|
|
|
|
|
ddepauli wrote: filename is a PDF file that exists
Dim mailAtt As New MailAttachment(sFilename)
myMail.Attachments.Add(mailAtt)
myMail.BodyFormat = MailFormat.Html
myMail.Body = xBody 'Loaded from a string
If (System.IO.File.Exists(sFilename)) Then 'to be sure Poke tongue
'System.IO.File.Delete(sFilename)
End If
if I delete attchment SMTP object returns me an error of "File not found" Confused why?
Why are you deleting the file before sending the Mail ?
cheers,
Abhijit
CodeProject MVP
|
|
|
|
|
ahaha sorry I've copyed wrong code.. delete is made AFTER sending..
|
|
|
|
|
ddepauli wrote: If (System.IO.File.Exists(sFilename)) Then 'to be sure
'System.IO.File.Delete(sFilename)
End If
Does this precede invoking the Send method?
Vasudevan Deepak Kumar
Personal Homepage Tech Gossips
The woods are lovely, dark and deep,
But I have promises to keep,
And miles to go before I sleep,
And miles to go before I sleep!
|
|
|
|
|
Sorry guys.....
I already posted this question.
This time i like explain clearly what i done and where i am getting problem.
I built a caluclator in .aspx page with button which look exacltly like a real caluclator.
It works fine until taking number into textbox when i click the number button
But when i click the = button the result is not displayed
i am keeping my code here....plz help me
protected void btnplus_Click(object sender, EventArgs e)
{
valholder1.Value = txtcal.Text;
sign = "+";
txtcal.Text = "";
}
protected void btnequal_Click(object sender, EventArgs e)
{
valholder2 = Convert.ToDouble(txtcal.Text);
if (sign == "+")
txtcal.Text = Convert.ToString(valholder2 + Convert.ToDouble (valholder1));
}
Here i took the valueholder1 and valueholder2 to store the values
and i want to display the result in textbox
plz help me.........
Thanx in advance
|
|
|
|
|
|
Hello,
I have placed 5 textboxes on a web page (ASP.NET using VB) and one for input of sum above 5 textboxes. I want to validate the 6th textbox something like it.. suppose sum of 5 textboxes is 1032 and now focus is in 6th (i.e. total) textbox; so here only "1032" characters should be allowed no other; and they should be in this order only; not like 1302 or something like (after pressing 1 it will accept only 0 no other key). How to get this feature please tell me. I know this can be achieved by javascript but less knowledge throw me in the forum.
Thanks & Regards
Girish Sharma
|
|
|
|
|
|
User have to feed the sum in the 6th textbox to verify the sum.
|
|
|
|
|
Hi,
Don't allow User to Calculate the Sum in which case there is a chance to enter the wrong value.
So You must calculate the value on the textChange Event of the 5th TextBox.
This is very Simple.
Bye.
Learner will gain more knowledge than Teacher.
|
|
|
|
|
This is my business need please.
User is doing the data feeding job in this web application. He will enter 5 number and 6th as sum of 5. Now if 1.user has done mistake or 2.the input source(a pre-printed data sheet which will be written by other staff) is having mistake; can be traced out and it will stop to error in database. He will only allowed to feed the right digits in the right order only or press escape key to recorrect the value(s) of above any of 5 inputs.
Thanks & Regards
Girish Sharma
|
|
|
|
|
|
|
Hi i have an html report in asp.net
I want to export html report to word ..
I am able to do that by following code ..but i want to have predefined header and footer in exported word document...
so how to set header/footer of ms-word document from asp.net code.
------------------------------------------CODE-----------
string strHTMLContent = reader.ReadToEnd();
strHTMLContent = strHTMLContent.Replace("#Education#", "BE");
strHTMLContent = strHTMLContent.Replace("#Position#", "Software Engineer");
lblmsg.Text = strHTMLContent;
HttpContext.Current.Response.Clear();
HttpContext.Current.Response.Charset = "";
HttpContext.Current.Response.ContentEncoding = System.Text.Encoding.UTF8;
HttpContext.Current.Response.ContentType = "application/ms-word";
string strFileName = "new1" + ".doc";
HttpContext.Current.Response.AppendHeader("Content-Disposition", "attachment;filename=" + strFileName);
HttpContext.Current.Response.Write(strHTMLContent);
HttpContext.Current.Response.End();
HttpContext.Current.Response.Flush();
|
|
|
|
|
I am new to this .net world.
I like to know how we can run .exe files with asp.net page
plz help me.........
|
|
|
|
|
Just for performing background operations u can use it since server side process are not visible to end users
MSDN[^]
|
|
|
|
|
Anjani Poornima wrote: I am new to this .net world.
I like to know how we can run .exe files with asp.net page
Asp.Net does not build for that. if you use process start exe it will start in Server not in client side.
If you want to really do that, use ActivX and It will work only in IE.
cheers,
Abhijit
CodeProject MVP
|
|
|
|
|
Thank you.....
I tried using system.diagoistics.process.start(".exe");
But it just works in the development side not the webserver. that means. when I click run in the VS.net, it can open a .exe . when i publish it to our web server. I just can see the .exe running under the task manager in the server side, but I can not see any .exe any input will be greatly appreciated.
|
|
|
|
|
Anjani Poornima wrote: I tried using system.diagoistics.process.start(".exe");
But it just works in the development side not the webserver. that means. when I click run in the VS.net, it can open a .exe . when i publish it to our web server. I just can see the .exe running under the task manager in the server side, but I can not see any .exe any input will be greatly appreciated.
As, I have already told you, Process.Start will execute process in Server not in Client. So This will not do the job for you.
First of all think why you need to execute the exe in Asp.net? Any alternative option to solve this.
If you need it then Go for ActiveX control and I have already suggested you it will work only in IE.
cheers,
Abhijit
CodeProject MVP
|
|
|
|
|
|
Sreekumar P P wrote: Forum: ASP.NET
Subject: Re: How to run an .exe from asp.net page
Sender: Sreekumar P P
Date: Wednesday, April 29, 2009 7:01 PM
--
What was that ?
cheers,
Abhijit
CodeProject MVP
|
|
|
|
|
hi;
i can't solve this error.This become a headache to me.i have no problem in source code.plz anyone help me. .
i am getting following from disassemble.
--- d:\E\AjaxTk-AjaxControlToolkit\Release\AjaxControlToolkit\ExtenderBase\ExtenderControlBase.cs
00000000 push edi
00000001 push esi
00000002 mov esi,ecx
00000004 mov edi,edx
00000006 cmp dword ptr ds:[04DA4CC0h],0
0000000d je 00000014
0000000f call 72DF2227
00000014 cmp byte ptr [esi+55h],0
00000018 jne 00000021
0000001a mov ecx,esi
0000001c call FFFFF390
00000021 mov edx,66468A58h
00000026 mov ecx,6DF85B0h
0000002b call 72DF3DB8
00000030 mov edx,edi
00000032 mov ecx,esi
00000034 call 5EE06980
00000039 mov ecx,esi
0000003b call dword ptr ds:[07041FF8h]
00000041 nop
00000042 pop esi
00000043 pop edi
00000044 ret
|
|
|
|
|
Hope you have put the Ajax ControlToolkit Dll in the wrong place.
Please check whether your Ajax extensions installation what correct?
CodingRocks
ASP.NET,C#.NET Programmer
BANGALORE
"Winners don't do different things. They do things differently. ...
|
|
|
|
|
Question Bank
Question 1 This is your first Question?
Option A aaaaa
Option B bbbbb
Option C ccccc
Question 2 This is your Second Question?
Option A aaaaa
Option B bbbbb
Option C ccccc
Question 3 This is your third Question?
Option A aaaaa
Option B bbbbb
Option C ccccc
Question 4 This is your fourth Question?
Option A aaaaa
Option B bbbbb
Option C ccccc
I would like to create a gridView like the above format.
Table name QuestionBank
Fields
questioned
question
optionA
optionB
optionC
Any one can help me.
Email ID cujuno@gmail.com
I am a programmer
|
|
|
|