|
Yes u can give width of each column in pixels and in percentages at the design time.
Do good and have good.
|
|
|
|
|
ThanQ for the reply. I have tried that way too. but when i do so. the column with cell that have data exceeding the limit is getting enlarged as long as the data.
Ramesh.Kanjinghat
|
|
|
|
|
Hi friends,
I got the work around for the above said problem. As i am setting the property TABLE-LAYOUT:fixed, the property will be apllied at client side. So we have to set the width of the columns using css class only. Below sample will help you understand the same.
<code>DataGrid1.Attributes.Add("style","TABLE-LAYOUT: fixed; OVERFLOW: hidden");</code>
The above code will force the grid to have eqaul column widths.
<code>DataGrid1.Columns[0].ItemStyle.CssClass="SetWidth"</code>
where SetWidth is given as below in the style tag
<style>
.SetWidth4Temps { WIDTH: 40px }
</style>
Hope this will help you all.
Cheers
Ramesh.Kanjinghat
|
|
|
|
|
i have 2 dates i want to get the difference between them
i have 3 dropdwonlist (day, month,year)
i get the values from it and concatenate them in one string in the format of day/month/year and i need to get the difference between the 2 dates to know which one is the recent one
thanks
|
|
|
|
|
use DateTime.Compare Method
For Example :
DateTime.Compare(DateTime.Parse("12/12/2005"), DateTime.Now) returns -1 indicating Later is greater.
DateTime.Compare(DateTime.Now , DateTime.Parse("12/12/2005") ) returns 1
indicating Former is greater.
DateTime.Compare( DateTime.Now, DateTime.Now) returns 0 indicating both are same.
|
|
|
|
|
Create a DateTime value instead of a string.
To compare two dates you can use the regular operators, i.e. <, <=, =, !=, >, >=.
To get the difference between two dates you can subtract them. The result is a TimeSpan value.
---
b { font-weight: normal; }
|
|
|
|
|
Dim date1 As Date
Dim date2 As Date
date1 = "9/25/2006 8:02:44 PM"
date2 = "9/23/2006 8:02:44 PM"
If date1 > date2 Then
Response.Write("date1 is recent")
Else
Response.Write("date2 is recent")
End If
not the best way to do it but still you can
|
|
|
|
|
Dear ..
You can use Now() function, Just you can compare the date and month and year... such details are found in Now.compare with Now and give the Comditions and get the result,
Another way is you can take it from Query..
Rame..
|
|
|
|
|
Hi,
I have been going crazy trying to find a tutorial or something which will
clearly explain to me what ErrSub is and also how to use it to get more
specific debugging solutions.. please help!
Thank you.
|
|
|
|
|
hello dears
i want to add javascript to webapplication(asp.net)
and how to use it
ashrafhakiem
ashraf_23_2005@yahoo.com
|
|
|
|
|
|
Hi...
What kind of javascript you have to add... we can add javascript easily in asp.Net page. you can add like this in HTML page//
function test()
{
alert('This is a test Page');
}
and you can call this function in ..Onclick or Page load or what ever it is..
here i have give you the example for calling function in onclick
btnSubmit = it is a button name
btnSubmit.attributes.add("onclick","javascript:return test()";)
TRY THIS AND GIVE ME YOUR FEEDBACK.
Rame..
|
|
|
|
|
parveen_banuk, has given you the code how to call a java scrip onclick event of a button.
here is how to call that script in page load.
Dim MyString as String = "test()"
Page.RegisterStartupSvript("MyScript", MyScript)
hope this give you some ideas.
cheers
|
|
|
|
|
Hi Dears,
I have a simple question can any body helpme please.
My Question!!:
I wanted to redirect user to another NTLM authentication based ASP.NET application, and it resides in a different server and also different Domain, but with out promting login box secound time.
More Elaboratively:
I have a username and password of mytarget application, I need to redirect user to that target Application, which is configured as Windows Integrated Authentication.
Here the issue is when the user is redirected to mytarget application it is prompting for credentials, Can we avoid the login box second time?
another way can we avoid multiple login boxes.
Vijay Bhasker Reddy CH
|
|
|
|
|
if the other domain server contains the same username and password, impersonate the currently supplied username and password to the other.
|
|
|
|
|
Hello
I am using my.settings to create a application scope connection string.
The customer would like to change this if they want to connect to another database, and this should update the app.config file with the updated connection string.
My problem I have into the setting and create a connection string (easy). But I don't know and can't find out to update and save the new connection string.
My.Settings.cnnString = "This is example connection" 'Error read-only property
I am using vb.net 2005
Can anyone help,
Thanks in advance,
Steve
|
|
|
|
|
To access and modify web.config or app.config you need to use Xml Classes.
|
|
|
|
|
Hi steve
You can use web.Congig Connection for this Problem. If you get web.Config Connection string means it is very useful for future updation for connection.If you use the same Connection is whole project means . you dont want to change it for whole application. just you do the nessecary changes in we.config.In Web.Config you can access more than one database.
Rame..
|
|
|
|
|
Hello
I am using my.settings to create a application scope connection string.
The customer would like to change this if they want to connect to another database, and this should update the app.config file with the updated connection string.
My problem I have into the setting and create a connection string (easy). But I don't know and can't find out to update and save the new connection string.
My.Settings.cnnString = "This is example connection" 'Error read-only property
I am using vb.net 2005
Can anyone help,
I got this code and it seem it would work. However, there is a problem with the code. I get a "Object reference not set to an instance of an object."
Here my code.
<br />
Dim config As Configuration.Configuration = Configuration.ConfigurationManager.OpenExeConfiguration(Configuration.ConfigurationUserLevel.None)<br />
config.ConnectionStrings.ConnectionStrings("ServiceMasterConnectionString").ConnectionString = "This is new connection " 'Error - <br />
config.Save()<br />
Thanks in advance,
Steve
|
|
|
|
|
I implemented Datagrid with PageindexChangeevent but i need scrolling concepts in the datagrid. Please do help.
kokila
|
|
|
|
|
hi,
take ur datagrid in DIV tag...
<div style="height: 250px; overflow: auto;">
<asp:DataGrid runat="server" ...>
...
</asp:DataGrid>
</div>
Thanks & Regards...
Amit
|
|
|
|
|
Thanks Amit, and it's working fine.Iam the beginner of .net so thank you for your immediate help . Can you guide me to create popupmenus forweb based project.
Thanks & Regards,
kokila
|
|
|
|
|
hi,
the basic concept behind menus in webbased project is to display and hide html elements. here is the simple code explaining this concept. u can format according to your need...
<HEAD>
<style type="text/css">
a.links:link { font-family : Arial; font-size : 12px; color : white; text-decoration : none; }
a.links:visited { font-family : Arial; font-size : 12px; color :white; text-decoration : none; }
a.links:hover { font-family : Arial; font-size : 12px; color : #FF9C03; text-decoration : none; }
td.menu{background:#4891C6}
table.menu {font-size:100%; position:absolute; visibility:hidden;cursor:hand }
</style>
<script type="text/javascript">
function showmenu(elmnt)
{
document.all(elmnt).style.visibility="visible"
}
function hidemenu(elmnt)
{
document.all(elmnt).style.visibility="hidden"
}
</script>
</HEAD>
<body topmargin="0" leftmargin="0" rightmargin="0">
<table width="100%">
<tr bgcolor="#4891c6">
<td style="cursor: hand" onclick="location.href='page1.aspx'" width="14%" onmouseover="showmenu('Mainmenu1')" onmouseout="hidemenu('Mainmenu1')">
<a class="links" HREF="page1.aspx">MainMenu1</a><br>
<table class="menu" id="Mainmenu1" width="100%">
<tr>
<td onclick="location.href='page1.aspx'" class="menu"><a class="links" HREF="page1.aspx">MenuItem</a></td>
</tr>
<tr>
<td onclick="location.href='page1.aspx'" class="menu"><a class="links" HREF="page1.aspx">MenuItem</a></td>
</tr>
<tr>
<td onclick="location.href='page1.aspx'" class="menu"><a class="links" HREF="page1.aspx">MenuItem</a></td>
</tr>
</table>
</td>
<td style="cursor: hand" onclick="location.href='page2.aspx'" width="14%" onmouseover="showmenu('Mainmenu2')" onmouseout="hidemenu('Mainmenu2')">
<a class="links" HREF="page2.aspx">MainMenu2</a><br>
<table class="menu" id="Mainmenu2" width="100%">
<tr>
<td onclick="location.href='page2.aspx'" class="menu"><a class="links" HREF="page2.aspx">MenuItem</a></td>
</tr>
<tr>
<td onclick="location.href='page2.aspx'" class="menu"><a class="links" HREF="page2.aspx">MenuItem</a></td>
</tr>
</table>
</td>
</tr>
</table>
</body>
Thanks & Regards...
Amit
|
|
|
|
|
hi,
i m using vs.net 1.0 and not able to run project in debug mode. program doesn't halt at any break point.
help plz...
thanks in advance
Regards...
Amit
|
|
|
|
|
Crystal report version for INVENTORY application. It gives us error to see the crystal reports which uses the crystalreportviewer component in aspx pages.e.g.FormInvSRFViewPrintingDetails.aspx which shows the error.
If we try to use our version /dlls it does not show the report and gives error when the application is running.
The component shows the version as 'Version=9.1.3300.0' and when Sameena asked Milind (Cybertech) about the version of Crystal reports used...he said he'd used version 7 for it. The framework which is used on server is different than our working version. and that is only framework which we cannot use for developement purpose.
If we make changes in the code and build the dll and put it on the server then it gives error when we try to print the reports.(the printing reports are mainly use the crystal reports dlls.)
So any changes done in the code anywhere in the project give us problem related to the report version as the crystal dlls has different version than it has on the server.
We got the crystal report version 8 from CG also ,which itself is giving error when installation takes place...SO it's of no use.
We are looking for the correct version of it which we haven't got yet.
So as of now we cannot proceed further on inventory module. Plz try to look in the matter from your side also .
Hi all,
dfsdfasdfsd
|
|
|
|