|
Appending in a string builder is tedious. I'd create a HTML page with required design and put placeholders where value gets replaced. Now just read this file and replace the placeholders with real values and assign to mail body. This helps to change the mail design quickly.
|
|
|
|
|
Naveneeth, I'm not sure If I fully understand what you are suggesting...but the string builder approach that Abhijeet mentioined does make sense, are you aware of any potentiall problems with that...since I'm reading data not from just one location, but from different text boxes, I think putting them all together would be possible only through string builder!
|
|
|
|
|
Tina P wrote: but the string builder approach that Abhijeet mentioined does make sense, are you aware of any potentiall problems with that
Maintenance will be tough. Think about a scenario where you need to change the mail design. You have to rework the string builder appending.
Tina P wrote: I'm not sure If I fully understand what you are suggesting
It is very simple. You create a HTML page with the required design. Put place holders, something like {name} and replace this with the real value. File.ReadAllText will give you the HTML file's content. Use String.Replace to replace the placeholder with a real value. So all the places where {name} is given will get replaced with real value.
|
|
|
|
|
Tina P wrote: are you aware of any potentiall problems with that
No, He is not talking about any potential problem.
Tina P wrote: I'm not sure If I fully understand what you are suggesting
Let me explain, If you are sending a mail to any one, you should look for proper formatting of the mail. Now for that you are using some HTML tag like BR, Table, Font etc.
But, did you ever realized how boring is it to formatting text every time using String Builder. The suggestion I have provided to you, is good for small mailing application.
But for a large content of mail and formatting you can understand what you have to do.
Here, Navaneeth suggested, You can create a HTML file with proper formatting in any HTM L editor like Front page, Dream weaver etc. Put a placeholder on that file.
You just read that file and replace the placeholder with value ( your case text box value).
This will makes the things very easier.
cheers,
Abhijit
CodeProject MVP
|
|
|
|
|
N a v a n e e t h wrote: Appending in a string builder is tedious. I'd create a HTML page with required design and put placeholders where value gets replaced. Now just read this file and replace the placeholders with real values and assign to mail body.
Exactly Navaneeth and I have done it in many cases where mail content is to large and lots of formatting are there.
cheers,
Abhijit
CodeProject MVP
|
|
|
|
|
Thank you guys, both of ya'll are great...I appreciate the help. However; this thing is pretty small (i.e. the content of the email is probably gonna be a few lines) so we should be ok there.
Thanks once again.
Tina
|
|
|
|
|
Thanks Abhijeet, this really does make sense. I'm going to try it out shortly, thanks again!
|
|
|
|
|
I've wrote a user control that has a table with rows and columns. And I choose a cell as controls container. But I'm still struggling to do that, read lots of articles but they all were very old and using inappropriate techniques. What I want is simple as Panel. Just drag controls from toolbar in drop in my control. Okay now this is one thing. The another thing is that the control I've made not showing effect in desing time. Mean if I set its width then it doesnt effect however it works good while debugging.
here is a code snippet
public string Width
{
get { return (Convert.ToInt32(ccontainer.Style["Width"].Replace("px", "")) + (18 * 2)).ToString() + "px"; }
set { ccontainer.Style["Width"] = (Convert.ToInt32(value.Replace("px", "")) - (18 * 2)).ToString() + "px"; }
}
Now, when I write like this. No effect in size but size get changed in web browser.
<XC:XPanel ID="XPanel2" runat="server" Width="700px" />
any idea guys ?
TVMU^P[[IGIOQHG^JSH`A#@`RFJ\c^JPL>;"[,*/|+&WLEZGc`AFXc!L
%^]*IRXD#@GKCQ`R\^SF_WcHbORY87֦ʻ6ϣN8ȤBcRAV\Z^&SU~%CSWQ@#2
W_AD`EPABIKRDFVS)EVLQK)JKQUFK[M`UKs*$GwU#QDXBER@CBN%
R0~53%eYrd8mt^7Z6]iTF+(EWfJ9zaK-iTV.C\y<pjxsg-b$f4ia>
-----------------------------------------------
128 bit encrypted signature, crack if you can
|
|
|
|
|
Dear Friends
I don't know what's the problem
we are using Dotnet Framework 2.0 and VS 2005 beta in server
But in the development machine we are using Framework 2.0 and VS 2005 Professional
Our product modules are working fine in development machine
I build the codings and publish in Server it showing the below error
error parsing attribute'Enableeventvalidation'.type 'Default_aspx' does not have appublic property named'enableeventvalidation'
i don't know what kind of error how to solve it Please guide me
Thanks &Regards
Jk
|
|
|
|
|
kankeyan wrote: I build the codings and publish in Server it showing the below error
error parsing attribute'Enableeventvalidation'.type 'Default_aspx' does not have appublic property named'enableeventvalidation'
i don't know what kind of error how to solve it Please guide me
Try to check the Framework version of your virtual directory in Production server.
Open IIS > Right Click on Virtual Directory > Properties > Goto Tab ASP.NET . Now check the asp.net version.
cheers,
Abhijit
CodeProject MVP
|
|
|
|
|
I have created one msi installer and it could able to complete sucessfully and the registry entries also made correct..but when I open the web page , the control is not loading..but when I execute regsvr32 through cmd,the web applicaion could load the control..
Any idea?
Thanks,
Rahul.
SoftwareDeveloper(.NET)
|
|
|
|
|
sounds like your control did not get registered.
Yusuf
Oh didn't you notice, analogous to square roots, they recently introduced rectangular, circular, and diamond roots to determine the size of the corresponding shapes when given the area. Luc Pattyn[^]
|
|
|
|
|
Yusuf,
Do we need to specify any command specifially for register while creating msi?
What I did was, added the files and updated the registry with cls id?
Did I miss anything?
Thanks,
Rahul.
SoftwareDeveloper(.NET)
|
|
|
|
|
I never worked with msi. How did you create it? Is there anywhere that allow you to set component registration?
Yusuf
Oh didn't you notice, analogous to square roots, they recently introduced rectangular, circular, and diamond roots to determine the size of the corresponding shapes when given the area. Luc Pattyn[^]
|
|
|
|
|
I am looking for free (or reasonably priced) online / CD ROM (Like AppDev) training for ASP .NET and C#.
If anyone has some CD's I could borrow / buy for a reasonable price, that would be great.
Links to free resources would also be helpful.
Thanks!
-Brian
|
|
|
|
|
bdaoust wrote: borrow
you can borrow mine from this site[^]
Yusuf
Oh didn't you notice, analogous to square roots, they recently introduced rectangular, circular, and diamond roots to determine the size of the corresponding shapes when given the area. Luc Pattyn[^]
|
|
|
|
|
Seriously?
How can we make arrangements to make that happen? It would seriously help me out!
|
|
|
|
|
hi!
Wonder if anyone there can help re: setting up my machine as a ASP server?
I'm running Windows XP Pro and I have IIS installed and have set it to run in local services.
I've made a test file as follows :
<![CDATA[<%
Dim dHour
dHour = Hour(Now)
If dHour < 12 Then
Response.Write "Good morning!"
ElseIf dHour < 17 Then
Response.Write "Good afternoon!"
Else
Response.Write "Good evening!"
End If
%>]]>
We hope you are enjoying our sample code.<br>
<br>
If you are curious it is currently <%= Time() %> on <%= Date() %>.<br>
</br></br></br>
and saved it to C:\Inetpub\wwwroot\MyWeb
When I go to localhost in my browser, I just get :
Failed to Connect
Firefox can't establish a connection to the server at localhost.
However, I have also saved the file to C:\xampp\htdocs\xampp
and when I am running the Apache service and run the test file in my browser, it just shows the raw code, line for line.
How can I get the file to work as it should? I just want to know that the ASP service is running ok. What do I need to do to make it so ? o_O
Please help !
M
|
|
|
|
|
Tekelt wrote: Wonder if anyone there can help re: setting up my machine as a ASP server?
This is asp.Net forum.
cheers,
Abhijit
CodeProject MVP
|
|
|
|
|
Tekelt wrote: When I go to localhost in my browser, I just get :
Failed to Connect
Firefox can't establish a connection to the server at localhost.
Have you tried it with IE? There are some issues that may prevent you connecting to localhost using FF. Try 127.0.0.1 or google the issue. It is a known issue.
Tekelt wrote: However, I have also saved the file to C:\xampp\htdocs\xampp
and when I am running the Apache service and run the test file in my browser, it just shows the raw code, line for line.
you code looks vbscript to me. Does apache support vbscript?
Tekelt wrote: How can I get the file to work as it should? I just want to know that the ASP service is running ok. What do I need to do to make it so ? o_O
you don't need to write any thing to test asp. Bring your browser and try http://localhost. This will execute asp code.
BTW: This is asp.net forum - next time try 'web development' forum.
Yusuf
Oh didn't you notice, analogous to square roots, they recently introduced rectangular, circular, and diamond roots to determine the size of the corresponding shapes when given the area. Luc Pattyn[^]
|
|
|
|
|
I'm trying to set multiple default browser and I did. But only one runs when I Start Debugging. I just right click on any(randomly select) web page >> Browse With... >> Select 2 required browsers and close that window. Now when I press F5 VS only runs first Default browser.
I'm wondering is it possible to have multiple browsers ?
TVMU^P[[IGIOQHG^JSH`A#@`RFJ\c^JPL>;"[,*/|+&WLEZGc`AFXc!L
%^]*IRXD#@GKCQ`R\^SF_WcHbORY87֦ʻ6ϣN8ȤBcRAV\Z^&SU~%CSWQ@#2
W_AD`EPABIKRDFVS)EVLQK)JKQUFK[M`UKs*$GwU#QDXBER@CBN%
R0~53%eYrd8mt^7Z6]iTF+(EWfJ9zaK-iTV.C\y<pjxsg-b$f4ia>
-----------------------------------------------
128 bit encrypted signature, crack if you can
|
|
|
|
|
Xmen wrote: I'm wondering is it possible to have multiple browsers ?
Xmen, Are you trying to run application in different browser while running application from VS?
cheers,
Abhijit
CodeProject MVP
|
|
|
|
|
okay now listen, I want when I press F5 to start debugging of my website then VS(2008) should run IE and Opera. But its running only one either IE or Opera, if I select both as Default, IE runs.
TVMU^P[[IGIOQHG^JSH`A#@`RFJ\c^JPL>;"[,*/|+&WLEZGc`AFXc!L
%^]*IRXD#@GKCQ`R\^SF_WcHbORY87֦ʻ6ϣN8ȤBcRAV\Z^&SU~%CSWQ@#2
W_AD`EPABIKRDFVS)EVLQK)JKQUFK[M`UKs*$GwU#QDXBER@CBN%
R0~53%eYrd8mt^7Z6]iTF+(EWfJ9zaK-iTV.C\y<pjxsg-b$f4ia>
-----------------------------------------------
128 bit encrypted signature, crack if you can
|
|
|
|
|
I doubt you could run multiple browsers by default. Even if it allow you to set multiple (which it shouldn't do in the first place).
Why do you want to run multiple browsers? Can't you do one after the another. I know it is tedious, but I don't see any other way of doing it. Say if you have multiple browsers open, can you attach to all of them from the the same debugger? I hope not.
Yusuf
Oh didn't you notice, analogous to square roots, they recently introduced rectangular, circular, and diamond roots to determine the size of the corresponding shapes when given the area. Luc Pattyn[^]
|
|
|
|
|
Yusuf wrote: Why do you want to run multiple browsers?
If you are web developer you know the answer
Yusuf wrote: can you attach to all of them from the the same debugger? I hope not.
this is BS
TVMU^P[[IGIOQHG^JSH`A#@`RFJ\c^JPL>;"[,*/|+&WLEZGc`AFXc!L
%^]*IRXD#@GKCQ`R\^SF_WcHbORY87֦ʻ6ϣN8ȤBcRAV\Z^&SU~%CSWQ@#2
W_AD`EPABIKRDFVS)EVLQK)JKQUFK[M`UKs*$GwU#QDXBER@CBN%
R0~53%eYrd8mt^7Z6]iTF+(EWfJ9zaK-iTV.C\y<pjxsg-b$f4ia>
-----------------------------------------------
128 bit encrypted signature, crack if you can
|
|
|
|