|
Try to remove extra spaces after the fileds.
Regards,
Sylvester G
Senior Software Engineer
Xoriant Solutions
sylvester_g_m@yahoo.com
|
|
|
|
|
Sir,
i have already suppressed unused sections and also compressed all fields as much as they can be.
The problem occurs whn i change my report page setup to landscape while taking hte printout from printpreivew option.Then page footer section create show that information in new page.
I've set my crystal report printer setup to landscape while creating the report but while printing it from internet explorer i have to convert page setup to landscape again.If i show print without changing page setup to landscape then it shows footer information at the end of same page but when i change it to landscape then footer information move to next page.
Pls see the problem...
|
|
|
|
|
Hello, there,
I'd like to know how I can change the rowState in GridView.
I want to set every row to the edit state when open the gridview control.
I made changes to rowCreated function of the grid view to change every datarow to the Edit state. But the it is not working at all.
The following are the code.
If (e.Row.RowType = DataControlRowType.DataRow) Then
e.Row.RowState = DataControlRowState.Edit
End If
Will you please tell me what I should do to make it happen?
Thank you so much in advance.
|
|
|
|
|
Haven't tried this but if you want your gridview to be in the edit state by default, why not use use template columns and textboxes for your itemtemplates?
sounds like a silly hack but...
acodeisacodeisacode
|
|
|
|
|
Hi all! I'm not able to get connected to Sql server 2005 from ASP.net 2.0 application which is HTTP based. When I run the code I get these errors
Login failed for user 'NIT\ASPNET'. (where NIT is system name)<br />
<br />
'con.ServerVersion' threw an exception of type 'System.InvalidOperationException'<br />
<br />
This is my connection string.<br />
<add key="strCon" value="Data source=localhost;Initial catalog=Anything;uid=;pwd=;Integrated security =SSPI;"/>
I've tried everthing in book, Like Trusted_connection = true also but to no avail.Problem is my another application which is File based running on a random port number assigned by ASP.net runs smoothly. After googling I could not come with something worthwhile.
Pls help
Thanks in advance.
Don't Quit
|
|
|
|
|
Has the ASPNET account permitted to access your SQL Server? And it is set up as a user on the database you want to use?
|
|
|
|
|
Hi Colin! Thanks for reply.
As I told you another asp.net application can access the sql server.
Colin Angus Mackay wrote: Has the ASPNET account permitted to access your SQL Server? And it is set up as a user on the database you want to use?
How to give permission to ASPnet account I dont know Pls tell me.
Thanks in advance.
Don't Quit
|
|
|
|
|
hi colin!
I've done this through
sp_grantlogin 'NIT\ASPNET'
grant insert on dbo.categories to [NIT\ASPNET]
but it created more questions than answers
1. serverversion is still there which can be seen while debugging ?
2. How to give persmission to this user for whole database in one go?
3. Earlier I've used insert queries in similar fashion but why it is asking for permission now.
Can you point me to a good link to find all the things I know about sql authentication and windows but all these things are somewhat new for me.
Thanks
Don't Quit
|
|
|
|
|
Nitin1981 wrote: 2. How to give persmission to this user for whole database in one go?
Add the user to the server role db_owner - it will then own the database and can do anything with it. NOTE: This is a security risk and should not be done on a live system.
There is another role, sysadmin, that gives a user access to all the databases on the server.
Nitin1981 wrote: 3. Earlier I've used insert queries in similar fashion but why it is asking for permission now.
There must be some difference between the previous connection and this one. SQL Server will not randomly deny access to things.
Nitin1981 wrote: Can you point me to a good link to find all the things I know about sql authentication and windows but all these things are somewhat new for me.
SQL Server Books On-Line - i.e. the Help file that comes with SQL server is the best resource.
|
|
|
|
|
Hi,
I have this problem with a gridview from which I am tryng to update a database table. I have this handler for my Row_Updating event:
Dim index As Integer = gvRecruit.EditIndex
Dim row As GridViewRow = gvRecruit.Rows(index)
Dim Id as Integer = Integer.Parse(row.Cells(0).Text)
Dim fName As TextBox = CType(row.FindControl("txtFirstName"), TextBox)
Dim firstName As String = fName.Text
Dim lName As TextBox = CType(row.Cells(1).Controls(1), TextBox)
Dim lastName As String = lName.Text
etc...
Problem is, when I step thru the code, the fName and lName still hold the old values, even though I have updated them with new ones.
I think I am missing something. Can anybody help?
PS
I don't really do VB, but I don't think that is an issue here.
acodeisacodeisacode
|
|
|
|
|
Hi Dear,
How to connect MS Access database using ASP.net
regards
adil
|
|
|
|
|
Hello Adil,
you can use OleDbConnection, for e.g
using System.Data.OleDb;
//...
//...
//...
OledbConnection conn = new OleDbConnection("your connection string here");
//...
but maybe you should be more specific. what exactly do you want to do with the data? bind to a grid?...
Also, what version of Asp.Net
acodeisacodeisacode
|
|
|
|
|
hi dear
I was trying to use following code ..but it is not working properly.
Imports System.Data.OleDb
Public Class Form1 Inherits System.Windows.Forms.Form
Dim cn As OleDbConnection
Dim cmd As OleDbCommand
Dim dr As OleDbDataReader
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e as _
System.EventArgs) Handles MyBase.Load
End Sub
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As_
System.EventArgs) Handles Button1.Click
Try
cn = New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;_
Data Source=C:\emp.mdb;")
'provider to be used when working with access database
cn.Open()
cmd = New OleDbCommand("select * from table1", cn)
dr = cmd.ExecuteReader
While dr.Read()
TextBox1.Text = dr(0)
TextBox2.Text = dr(1)
TextBox3.Text = dr(2)
' loading data into TextBoxes by column index
End While
Catch
End Try
dr.Close()
cn.Close()
End Sub
End Class
regards
adil
|
|
|
|
|
Standard question #1:
What do you mean by "not working"?
Standard question #2:
What error message do you get?
---
single minded; short sighted; long gone;
|
|
|
|
|
Hi Adil,
You said something about ASP.Net but it looks like it is a windows form you are dealing with. Anyhow, it doesn't matter.
What you can do is put a breakpoint in your code for the Button click event
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As_
System.EventArgs) Handles Button1.Click
then step though the code and find out where it breaks. This would give us info enough to help you.
Meanwhile, i expect that the database has a table, Table1 with at least 3 fields that are all of Text type (?).
(gain maybe it would help for you to go with:
TextBox1.Text = dr(0).ToString().....etc
acodeisacodeisacode
|
|
|
|
|
Hi all,
I am using a datagrid to display employee information such as Name,grade,dept,expertise... My problem is that the expertise column goes on expanding and the text wraps and everything`s spoiled.I want that if the length of the column increase the extra information be shown by using onmouseover on that cell of datagrid. How do i dothis in itemcreated event of datagrid
|
|
|
|
|
1.Use template column for particular field
<asp:TemplateColumn HeaderText="Office Location">
<ItemTemplate>
<div class="divstyleNormal"><%#DataBinder.Eval(Container.DataItem , "Location")%></div>
</ItemTemplate>
</asp:TemplateColumn>
CSS refered for the above is
.divstyleNormal
{
overflow: hidden;
width: 175px;
}
This way you can cut the text, and while binding(ItemDataBound) you can set the tool tip
Regards,
Sylvester G
Senior Software Engineer
Xoriant Solutions
sylvester_g_m@yahoo.com
|
|
|
|
|
Please need help on building a web search engine with c#.net got some note but haven't read them yet. want to get much idea so i can work and sort them out offline .
shawn414
|
|
|
|
|
shawn414 wrote: Please need help on building a web search engine with c#.net got some note but haven't read them yet. want to get much idea so i can work and sort them out offline .
This is such a vague question I don't know where to start. What, specifically, are you stuck with? Database design? Database interaction? internet protocols? Parsing of web pages? and so on...
|
|
|
|
|
there are good articles in the articles on this site that will assist you.
do a search for web spiders in the articles.
but as angus says there is alot of detail you need to consider, and as exactly what do you mean by search engine? are you looking to incorporate a full text search on your web site? search engine can mean so many things in this world!
|
|
|
|
|
I'm having a problem with this peice of code and for the life of me I cant figure out why. If I run it as a C# application on my computer it will send an email to the testaddress@gmail.com containing the text "HI!" ... When I copy this code into my Asp.Net applictation and run it on the server I get the error shown below the code... The server version is also shown. Any ideas would be very welcome as I've been trying to make this work for several hours now!
<br />
protected void Button1_Click(object sender, EventArgs e)<br />
{<br />
MailMessage message = new MailMessage("mailer@testdomain.com", "testaddress@gmail.com", "feedback", "HI!");<br />
SmtpClient mailClient = new SmtpClient("mail.testdomain.com");<br />
<br />
mailClient.Port = 25;<br />
mailClient.UseDefaultCredentials = false;<br />
mailClient.Credentials = new NetworkCredential("mailer@testdomain.com", "test");<br />
mailClient.DeliveryMethod = SmtpDeliveryMethod.Network;<br />
<br />
mailClient.Send(message);<br />
<br />
<br />
<br />
message.Dispose();<br />
}<br />
Server Error in '/' Application.<br />
--------------------------------------------------------------------------------<br />
<br />
The SMTP server requires a secure connection or the client was not authenticated. The server response was: PLESK.home ESMTP MailEnable Service, Version: 1.95-- denied access at 02/18/07 02:02:23 <br />
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. <br />
<br />
Exception Details: System.Net.Mail.SmtpException: The SMTP server requires a secure connection or the client was not authenticated. The server response was: PLESK.home ESMTP MailEnable Service, Version: 1.95-- denied access at 02/18/07 02:02:23<br />
<br />
Source Error: <br />
<br />
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below. <br />
<br />
Stack Trace: <br />
<br />
<br />
[SmtpException: The SMTP server requires a secure connection or the client was not authenticated. The server response was: PLESK.home ESMTP MailEnable Service, Version: 1.95-- denied access at 02/18/07 02:02:23]<br />
System.Net.Mail.SmtpConnection.GetConnection(String host, Int32 port) +819256<br />
System.Net.Mail.SmtpTransport.GetConnection(String host, Int32 port) +316<br />
System.Net.Mail.SmtpClient.GetConnection() +42<br />
System.Net.Mail.SmtpClient.Send(MailMessage message) +2004<br />
Email.Button1_Click(Object sender, EventArgs e) +153<br />
System.Web.UI.WebControls.Button.OnClick(EventArgs e) +105<br />
System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) +107<br />
System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) +7<br />
System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +11<br />
System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +33<br />
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +5102<br />
<br />
<br />
<br />
<br />
--------------------------------------------------------------------------------<br />
Version Information: Microsoft .NET Framework Version:2.0.50727.42; ASP.NET Version:2.0.50727.210
Thank you in advance,
Curt
|
|
|
|
|
hetrobezz wrote: The SMTP server requires a secure connection or the client was not authenticated.
I think you'll find your answer in there.
|
|
|
|
|
Hi friends,
I am facing a typical problem in crystal reports i made an application in aspnet2005 using crystal reports i have made n tier system the database is on one server and application is on one server the problem is i have to restart the application server daily in order to view crystal report if i am not doing so i cant see the report in the viewer only blank page is seen can anybody help me.
regards jabbar
jabbarsb
|
|
|
|
|
I'm looking for sample code (AJAX, ASP, JAVA) that allows web users to input questions from a form and when submitted it calls a document (Word, PDF, HTML) and inputs the users answers in the appropriate location of the document and allows them to print the document. Is this possible and what is the best code to use (AJAX, ASP, JAVASCRIPT, PERL)???
Thanks...
JR
|
|
|
|
|
Anythings possible.
AJAX and Javascript probably won't do it (Javascript is client side and Ajax is basically a javascript technology).
It'll be possible with any server-side language, you'll just need a library to write to your document format. HTML is of course easy, PDF theres plenty of libraries available to write to it (I've seen ones for Java, .NET and PHP has several built in). Word I'm not sure about, your only option there may be .NET with Word installed on the server (you can then download the Word interop libraries which make it easy to use Word from within a .NET program)
|
|
|
|