|
to align controls use css property.
|
|
|
|
|
I could use it to align text, however, I would like to make sure that they fit within a , and, somehow the tags have rendered the page unreadable.
I tried with a smaller version and it worked, so I must have done some mistake in my actual form.
However when I tried to include controls within a wizard control within tags it doesn't compile. Any workarounds?
<br />
<![CDATA[<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %>]]><br />
<br />
<br />
<br />
<html xmlns="http://www.w3.org/1999/xhtml"><br />
<head runat="server"><br />
<title></title><br />
</head><br />
<body><br />
<form id="form1" runat="server"><br />
<div><br />
<br />
<asp:wizard id="Wizard1" runat="server" activestepindex="0" height="132px" xmlns:asp="#unknown"><br />
onfinishbuttonclick="Wizard1_FinishButtonClick" Width="765px"><br />
<wizardsteps><br />
<table><br />
<asp:wizardstep id="step1" runat="server" title="Task details"><br />
</asp:wizardstep></table><br />
Choose<asp:dropdownlist id="DropDownList1" runat="server"><br />
<asp:listitem value="2a">Step 2a</asp:listitem><br />
<asp:listitem value="2b">Step 2b</asp:listitem><br />
</asp:dropdownlist><br />
<br /><br />
<br /><br />
<br />
<asp:wizardstep id="step2a" runat="server" title="Step 2a"><br />
</asp:wizardstep><br />
<asp:wizardstep id="step2b" runat="server" title="Step 2b"><br />
</asp:wizardstep><br />
<br />
</wizardsteps><br />
</asp:wizard><br />
<br />
</div><br />
</form><br />
</body><br />
</html><br />
<br />
Error:
Error 1 System.Web.UI.WebControls.WizardStepCollection must have items of type 'System.Web.UI.WebControls.WizardStepBase'. 'table' is of type 'System.Web.UI.HtmlControls.HtmlTable'. c:\inetpub\wwwroot\WebSite2\Default.aspx 16
Jon
modified on Sunday, January 18, 2009 2:36 PM
|
|
|
|
|
hi to all
my problem is that i have two dropdownlist on a web page both are databind first one is for CountryList and Second One is for Country Related Place list. i am using Ajax control toolkit with Visual Studio 2005 . All these work fine But when i select a Country which has more Places Like 1000 or More then Update Progress bar Stops for some time. when i read about Update pannel on Microsft site then i came to know that update pannel reduce the amount of data which transferred between client and server.
so i want to know that how can i increase data transfer between client and server.
|
|
|
|
|
You might want to take a look at your UI design and maybe come up with a way of further limiting the 'places of interest'. 1000 items is really far too many to put into a drop down list.
|
|
|
|
|
Member 4001596 wrote: so i want to know that how can i increase data transfer between client and server
Rather than increasing data transfer between Client and server try to restrict number of records. More that 1000 in a dropdown list does not make any sense
|
|
|
|
|
i know that. but as my requirement i have a large database which consist two table one is country list and second is Place list. i want as when a country is selected the related places fill in second dropdownlist or list box. there are to total 11000 records in places list. then what i do ?
|
|
|
|
|
hi,
i am having a problem in a SQLquery.
actually i am developing a project in asp.net with C# i. e. "MESSAGE BOARD". in this all the topics are displayed in gridview. but here sorting should be as per the last modified topic as well as if any user has replied more than 10 posts , then these messages should be displayed first.
i mean sticky posts should have highest priority to display first in the gridview as well as last modified topic.
the two tables from which i am accessing datas are:
Table1: "create_topic" :
Table Fields : Description
topic_id# : Topic id
group_id# : Group id
cat_id# : subgroup id/category id
username# : user name
topic_title : title of topic
topic_msg : original message
topic_create_date : date when topic is created
no_of_views : total no. of views
no_of_reply : total no. of replies to this topic
Is_sticky : If more than 10 posts by a single user then it is set to Y else N
Is_closed : ban the reply if satisfied.
Table 2: "reply_topic" :
group_id# : group id
cat_id# : category id
reply_id # :reply id
topic_id # :topic id
Username # :username
reply_msg : reply
rply_date : date when reply
can anyone tell me the query which can fulfill the purpose.
I have tried the query but not successfull:
SELECT a.topic_id, a.group_id, a.cat_id, a.username, a.topic_title, a.topic_msg, a.topic_create_date, a.no_of_views, a.no_of_reply, a.is_sticky,
a.is_closed
FROM create_topic AS a INNER JOIN
reply_topic AS b ON a.group_id = b.group_id AND a.cat_id = b.cat_id AND a.topic_create_date = b.rply_date
ORDER BY b.rply_date, a.topic_create_date
UNION
SELECT topic_id, group_id, cat_id, username, topic_title, topic_msg, topic_create_date, no_of_views, no_of_reply, is_sticky, is_closed
FROM create_topic
ORDER BY is_sticky==Y
what is wrong in it or how can i solve the problem.
also uniqueness should be maintained.
please help me.
|
|
|
|
|
I've not tried it, but something like this should do it:
SELECT a.topic_id, a.group_id, a.cat_id, a.username, a.topic_title, a.topic_msg, a.topic_create_date, a.no_of_views, a.no_of_reply, a.is_sticky,
a.is_closed, case when a.is_sticky = 'Y' then getdate() else coalesce(b.rply_date,a.topic_create_date) end as SortDate
FROM create_topic AS a Outer JOIN
reply_topic AS b ON a.group_id = b.group_id AND a.cat_id = b.cat_id AND a.topic_create_date = b.rply_date
Order by SortDate desc
The idea is, when the topis is sticky then use getdate, else use the reply date (if there is one, else topic create date) and order by sort date desc.
This should give you all the topics , sticky first followed by the most recent replies/postings
As I said, I have not tested it, but it should be somewhere on the lines you need.
Bob
Ashfield Consultants Ltd
Proud to be a 2009 Code Project MVP
|
|
|
|
|
Thanks for your reply.As per you said i have tried the query:
"SELECT a.topic_id, a.group_id, a.cat_id, a.username, a.topic_title, a.topic_msg, a.topic_create_date, a.no_of_views, a.no_of_reply, a.is_sticky, a.is_closed,
CASE WHEN a.is_sticky = 'Y' THEN getdate() ELSE COALESCE (b.rply_date, a.topic_create_date) END AS SortDate
FROM create_topic AS a FULL OUTER JOIN
reply_topic AS b ON a.group_id = b.group_id AND a.cat_id = b.cat_id AND a.topic_create_date = b.rply_date
WHERE (a.cat_id = @cat_id)
ORDER BY SortDate DESC"
Although the query is resulting the sticky post to be displayed first and rest others to be displayed next.Only as per the date of creating post sorting is maintained ,but when any body replied then this does not reflect the order. Also when there are more than one sticky posts then as per the last modified (either made post or replied ) sorting should be maintained and even same should be applied for the non sticky posts. This is not actually happening.
What changes should i make ,so that it may give the result what actually i want.
Please help me.
|
|
|
|
|
Just change the case statement to set the SortDate to whatever you like, i.e. last modified or whatever. I have given you the basics, its up to you to do any tweaks.
Bob
Ashfield Consultants Ltd
Proud to be a 2009 Code Project MVP
|
|
|
|
|
Hello friends.
I want to show the same grid view in another page from first page.
I use the following code in text box case. it work properly. but for grid view what will I change in following code.
In first page:
I take text box and button.
on button click I write
Server.Transfer("page2.aspx");
<u>In Secong page:</u>
On page_load event
{
if(Page.PreviousPage != null)
{
TextBox txt =(TextBox) Page.PreviousPage.FindControl("txtFirstPage");
if(txt != null)
{
Response.Write("<font color='teal' > " + txt.Text + "</font>"); }
}
thanx
|
|
|
|
|
You should really avoid the use of Server.Transfor for such simple scenarios like this. ASP.NET allows you to cross-post from one page to another. Just set the PostbackURL property on the button to page2.aspx, and access the value for txtFirstPage directly from the form: Request.Form["txtFirstPage"]
|
|
|
|
|
can any one guide me how can i do it i have added a dll reference in toolbox and now i want to remove it complete from my visual studio.
any suggesion would be appriciated..
umerumerumer
|
|
|
|
|
mr_muskurahat wrote: i want to remove it complete from my visual studio.
Right Click on toolbox and Click Reset Tool Box
Or
Right Click on Toolbox > Choose ToolBox Item > Unchecked the components that you have add > Ok
BTW : Does it any thing related with ASP.Net
|
|
|
|
|
i want to merge two pdf files... the thing is that the content of tha file should not be lost ... i just want to append the data in file..
|
|
|
|
|
Hi,
there are a lot of tools out there that can merge pdfs. For example PDF Split and Merge (http://www.pdfsam.org/[^]). This app can be controled by console. So all you have to do is to start a process within your app using this tool by console.
Does this help you?
Regards
Sebastian
|
|
|
|
|
|
You need to learn how to put your code in the proper tags.
"Well, we're getting "F"'d at work. WPF, WCF, and WWF... WTF?" --John Simmons
|
|
|
|
|
Hello,
I am trying to implement the code provided at this link:
http://www.danielsoper.com/programming/DataGridViewDragDropRowsColumns.aspx
I have populated the datagrid from oracle table; but it is returning error when i close/end the application. "No symbols are loaded for any call stack frame. The source code cannot be displayed" and then another message box appears which title is "LoaderLock was detected".
Please try at your end and let me know to correct the error.
Regards
Girish
|
|
|
|
|
Have you tried running in debug? Have you tried asking the code author? Those should be your first steps.
Bob
Ashfield Consultants Ltd
Proud to be a 2009 Code Project MVP
|
|
|
|
|
Hi to all,
I have a datagrid and a checkbox in it.In my datagrid I have a template column of "QTY" which is having a textbox.
Suppose user selects an item then it will be displayed in the datagrid.
But if user wants to change the quantity then he has to check the the checkbox and click the update button below datagrid.
for this I did:
<br />
<asp:DataGrid ID="DataGrid2" runat="server" CellPadding="4" ForeColor="#333333" <br />
GridLines="Horizontal" EnableViewState="False" Font-Bold="True" <br />
Font-Names="Verdana" Font-Size="Small" AutoGenerateColumns="False" ><br />
<FooterStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" /><br />
<EditItemStyle BackColor="#999999" /><br />
<SelectedItemStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" /><br />
<PagerStyle BackColor="#284775" ForeColor="White" HorizontalAlign="Center" /><br />
<AlternatingItemStyle BackColor="White" ForeColor="#284775" /><br />
<ItemStyle BackColor="#F7F6F3" ForeColor="#333333" /><br />
<Columns><br />
<asp:TemplateColumn HeaderText="Select" HeaderStyle-Width="50px"><br />
<ItemTemplate><br />
<asp:CheckBox ID="chkSelection" runat="server" ToolTip='<%# Eval("QTY") %>' /><br />
</ItemTemplate><br />
<HeaderStyle Width="50px"></HeaderStyle><br />
</asp:TemplateColumn><br />
<asp:BoundColumn DataField="REF" HeaderStyle-Width="70px" HeaderText="REF"></asp:BoundColumn><br />
<asp:TemplateColumn HeaderText="product_id" Visible="False"><br />
<ItemTemplate><br />
<asp:Label ID="lblProduct_Id" runat="server" Text='<%# Eval("REF") %>'></asp:Label><br />
</ItemTemplate><br />
</asp:TemplateColumn><br />
<asp:BoundColumn DataField="Description" HeaderStyle-Width="330px" HeaderText="Description"></asp:BoundColumn><br />
<asp:TemplateColumn HeaderText="QTY" HeaderStyle-Width="30px"><br />
<ItemTemplate><br />
<asp:TextBox ID="TxtQTY" runat="server" Width="30px" Text='<%# Eval("QTY") %>' /><br />
</ItemTemplate> <br />
</asp:TemplateColumn><br />
<asp:BoundColumn DataField="Price" HeaderStyle-Width="50px" HeaderText="Price"></asp:BoundColumn><br />
<asp:BoundColumn DataField="Cost" HeaderStyle-Width="70px" HeaderText="Cost"></asp:BoundColumn><br />
</Columns><br />
<HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" /><br />
</asp:DataGrid><br />
protected void BtnUpdate_Click(object sender, EventArgs e)
{
CheckBox chkSelected = new CheckBox();
foreach (DataGridItem dgItem in DataGrid2.Items)
{
chkSelected = (CheckBox)dgItem.FindControl("chkSelection");
if (chkSelected.Checked == true)
{
qty3 = Convert.ToInt32(chkSelected.ToolTip);
}
}
}
But the problem is that in the code behind file datagrid2.Items has the count=0.So the foreach loop is not working.
Please guide me that where I am making mistake.
Thanks in advance!
cheers,
sneha
|
|
|
|
|
I'd suggest that you need to look at where your databinding occurs and if viewstate is turned on. If you databind in your page load every time, that runs first and causes viewstate to be lost.
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
your foreach statement should be put in the GridView OnRowDataBound-method.
In the btnUpdate_click you should determine in whicht line the click was made. With that information you could do an sqlquery and then bind that data to the gridview. The OnRowDataBound -method is then fired after each placed row in the griview.
|
|
|
|
|
I have one report which consist subreport also. now i just want to display subreport of that report... so if any 1 of u knw pls reply me..
|
|
|
|
|
I'm currently looking into using the MVP pattern for creating web applications and have some questions:
- If state needs to be recorded I presume its done in the model, if the model classes are in an assembly separate from the actual pages do you still use session or some other form of state management?
- How is UI logic such as "disable this button unless condition is met" handled? is the logic embedded in the view ( or the page code behind), presenter or model.
Can any body can provide some detail/thoughts in relation to these areas?
|
|
|
|