|
I have just done it making an ftp site
ARINDAM
|
|
|
|
|
hi try this
using System.IO;
and
String DocPath = Session["DocPath"].ToString();
//here Docpath = "~/Documents/18abc.jpg"
string path = Server.MapPath(DocPath);
//here path = "Y:\\testsite\\Myfolder\\Documents\\18abc.jpg"
System.IO.FileInfo file = new System.IO.FileInfo(path);
if (file.Exists)
{
Image1.ImageUrl = path;
//or you can use direct path
Image1.ImageUrl = "htt://www.yoursite/folder/file.jpg";
}
this may help you
|
|
|
|
|
Hi,
I m using ajax modal pop up extender control in my ASP.Net 2008 website. On click of some option button it opens up the modal pop disabling the base page. Although it disables the page ... mouse clicks does not work but tab key do work on the base page if there are option buttons on the page.
Can anyone give a suggestion or solution to disable the option buttons on base page through tab keys? Or if there is any other solution for opening pop up windows in asp.net website?
I also want to open another modal pop up from a modal pop up itself. Is it possible ? caz when i use it, it behaves weirdly i.e. does not work properly.
Thanks,
|
|
|
|
|
i tried to response.redirect() to main page , in the session end event, but in that event get a exception saying "Response is not available in this context"
how can i handle this situation
|
|
|
|
|
|
Hi all
I am using ASP.Net 3.5 and send email using smtp server
when i host my application i am getting the below error:
The server rejected one or more recipient addresses. The server response was: 550 5.7.1 Unable to relay for name@domain.com
My Code:::
Dim objMail As New MailMessage
Try
objMail.From = "name@domain.com"
objMail.To = "name@domain.com"
objMail.BodyFormat = MailFormat.Text
objMail.Priority = MailPriority.High
objMail.Subject = "My first ASP.NET email"
objMail.Body = "This is my first email sent via "
SmtpMail.SmtpServer = "server ip address"
SmtpMail.Send(objMail)
Catch ex As Exception
Response.Write(ex.Message)
End Try
Thanks in advance
Er. Jagwinder Singh
|
|
|
|
|
You may need to authenticate to your email server so you would need to add that to your code. Below is a code snippet using cdosys, that i tested answering a similar question the other day.
Set myMail=CreateObject("CDO.Message")
myMail.Subject="Sending email with CDO"
myMail.From="youremail@yourdomain.com"
myMail.To="youremail@yourdomain.com"
myMail.TextBody="This is a message."
myMail.Configuration.Fields.Item ("http://schemas.microsoft.com/cdo/configuration/sendusing")=2
'Name or IP of remote SMTP server
myMail.Configuration.Fields.Item ("http://schemas.microsoft.com/cdo/configuration/smtpserver")="youremailserver"
'Server port
myMail.Configuration.Fields.Item ("http://schemas.microsoft.com/cdo/configuration/smtpserverport")=25
'authenticate
myMail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpauthenticate") = 1
'email address for authentication
myMail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/sendusername") = "youremailaddresshere"
'email password
myMail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/sendpassword") = "youremailpasswordhere"
myMail.Configuration.Fields.Update
myMail.Send
set myMail=nothing
Hope this helps
|
|
|
|
|
Hi,
I am building a ASP.NET page using c#.
I need a code to add a javascript function to disable a button on a text change event.
The below is the code i wrote
The script code in tags:
function SetButtonStatus()
{
document.getElementById("Button2").disabled = true;
}
this is the textbox tag:
<asp:textbox id="txtName" runat="server" onchange="SetButtonStatus()" xmlns:asp="#unknown">
It doesn't seem to work. Please help me on this one.
|
|
|
|
|
row.Cells[cellIndex].RowSpan = previousRow.Cells[cellIndex].RowSpan < 2 ? 2 : previousRow.Cells[cellIndex].RowSpan + 1;
|
|
|
|
|
If previousRow.Cells(cellIndex).RowSpan < 2 Then
row.Cells(cellIndex).RowSpan = 2
Else
row.Cells(cellIndex).RowSpan += 1
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
|
|
|
|
|
Hello folks,
I just can't seem to get the property right...I am enter data using text boxes on a page such as Name, address etc. So in a give row on the page, I have one lable (such as name) and a text box corresponding that lable where the user will type in teh name and then the same thing for the address and so forth. I've been using the designer to adjust all the text boxes so that they lign up accurately. I have dumped all these controls (lables, text boxes, required field validation text and finally a submit button in a div)
I want all those text boxes alligned underneath each other accurately and space   (from the designer) can't seem to cut it can't someone please tell me what other properties needs to be set...on the div, or better yet, I'll put a cssClass attribute on the div...what properties should I set in the extenal CSS so that the text boxes are all alligned properly. Thanks as you can probably tell, I'm not good with CSS
Thanks
Tina
|
|
|
|
|
You can do it with css using float:left to make sure they all left align, or you can do all this within a table as well.
example (C#):
<pre>
<table>
<tr>
<td align="left"><asp:Label ID="Label1" Text="User Name: " runat="server"></asp:Label></td>
<td align="left"><asp:TextBox ID="TextBox1" runat="server"></asp:TextBox></td>
</tr>
<tr>
<td align="left"><asp:Label ID="Label2" Text="Password: " runat="server"></asp:Label></td>
<td align="left"><asp:TextBox ID="TextBox2" runat="server"></asp:TextBox></td>
</tr>
</table></pre>
This would accomplish what you were asking with just tables. As far as css i would suggest doing google searches for good css tutorials.
Hope that helps
Matthew Vass
QA Analyst
mvass@hostmysite.com
HostMySite.com
|
|
|
|
|
Hey there, thanks for the response...I ended up using float as well....but yeah I'm using Divs and span...as opposed to Tables. Thanks for the help though!
Tina
|
|
|
|
|
I use this code in the web.config file
<authentication mode="Forms">
<forms name="login" loginUrl="Admin/login.aspx" path="/" />
</authentication>
<authorization>
<deny users="?" />
</authorization>
For this reason unauthenticated user cannot access any pages(without Admin/login.aspx). I have also used membership provider. Everything is OK. after login any graphics file can be added as a background picture. But I want to give access some pages to unauthenticated users and I want to add some graphics file in the login.aspx like the following:
<td style="width:15px;background-image: url(http://localhost:2152/Test/images/bg.gif);">
<form id="frmLogin" runat="server">
<asp:Login ID="MyLogin" runat="server" OnAuthenticate="MyLogin_Authenticate" BackColor="White" BorderPadding="0" BorderStyle="Solid" BorderWidth="2px" Width="252px">
<LabelStyle BackColor="LightYellow" Font-Bold="True" ForeColor="#400040" />
<CheckBoxStyle ForeColor="Black" />
<TextBoxStyle BackColor="White" BorderColor="DarkGray" BorderStyle="Groove" />
<ValidatorTextStyle BorderColor="Black" ForeColor="RoyalBlue" />
<TitleTextStyle BackColor="Black" ForeColor="Yellow" HorizontalAlign="Left" />
<LoginButtonStyle BorderColor="Purple" BorderStyle="Groove" />
</asp:Login>
</form>
</td>
I think that since I am not a authenticated user before login so, graphics file is not showing.
I think this is solved problem to many programmers. Is there any programmers who will help about this problem?
|
|
|
|
|
Hello everybody, i.m new using owc, i know how to change the color in a bar chart but it´s not the same with a pie chart...i hope you can help me please...
modified on Friday, March 27, 2009 12:14 PM
|
|
|
|
|
I have implemented linked servers in SQL server using microsoft.jet.oledb and it works fine from the sql management studio but when I implement it in an aspx page I get below error,
"Cannot initialize the data source object of OLE DB provider "Microsoft.Jet.OLEDB.4.0" for linked server "
Any help will be appreciated.
a novice
|
|
|
|
|
Can we see what you are doing in your code ?
Vuyiswa Maseko,
Few companies that installed computers to reduce the employment of clerks have realized their expectations.... They now need more and more expensive clerks even though they call them "Developers" or "Programmers."
C#/VB.NET/ASP.NET/SQL7/2000/2005/2008
http://www.vuyiswamaseko.tiyaneProperties.co.za
vuyiswa@its.co.za
www.ITS.co.za
|
|
|
|
|
I required to pass userID, so I open the Users table(ASPNETDB) and found that the UserID is very complicated to understand or to use. I dunno why they did so, is there any solid reason 'coz I don't think userID is sensitive. It can be just a simple long value.
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
|
|
|
|
|
What are you talking about??
Vuyiswa Maseko,
Few companies that installed computers to reduce the employment of clerks have realized their expectations.... They now need more and more expensive clerks even though they call them "Developers" or "Programmers."
C#/VB.NET/ASP.NET/SQL7/2000/2005/2008
http://www.vuyiswamaseko.tiyaneProperties.co.za
vuyiswa@its.co.za
www.ITS.co.za
|
|
|
|
|
I was talking about UserId column in Users table of ASPNETDB database.
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
|
|
|
|
|
UserIds are GUIDs
Apurv
“Never trust a computer you can’t throw out a window.”
(Steve Wozniak)
“There are only two industries that refer to their customers as ‘users’.”
(Edward Tufte)
|
|
|
|
|
GUID sucks...completely tacky
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 have a web app that needs to go out to another web app and return. I'm passing the url of the page I want to return to to the second app. In the development environment, the server name is appended with the port, as in "localhost:1768". I'm passing this as part of the url, but when the second app tries to return to the first app, it ignores the port and redirects to "localhost", and I get an error that the resource cannot be found. Does anyone know how to handle this problem?
|
|
|
|
|
give it full url http://localhost:1768/myapp/redirect.aspx
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 was getting the server name from Request.ServerVariables, and it turns out that was returning "localhost". When I hardcoded "localhost:1768" it worked. Thanks.
|
|
|
|