|
hi friends
i am using the following code:
int i = Convert.ToInt32(Session["Count"].ToString());
int k = 0;
string[] strTextBoxValues = new string[] { };
for (k = 0; k <= i - 1; k++)
{
string textboxval = "DynamicTextbox" + Convert.ToString(k);
TextBox textval = (TextBox)this.Page.FindControl(textboxval);
textval.ID = textboxval;
Response.Write(textval.Text);
}
but the findcontrol method returns null....and any one to help me in this issue as i am stuck in my work...
K.Gayathri
|
|
|
|
|
I want to allow the users to generate a long running report to PDF on demand. Basically they will click a link and it will pop up a new window and let them know what the progress of their report is and allow a PDF download when they are done.
I am using the Telerik reporting module for reporting as the server is a hosted server that does not have SSRS. The whole thing is a big pain in the butt. Here are my hurdles.
1. I can pop up the new window, and have it generate the report and then return a view, but if the user closes that window before the report is done there is a problem.
2. The view doesn't get returned until the report is done, making it a useless blank window until the report is done where it would be nice to even have it say just something until the report is done.
The report is several thousand pages, and several hundred mb, so could take several hours. Anyone have methodology pointers here? As a hosted web app on GoDaddy, I am not sure what to do about calling an external reporting service, or even how to build one to begin with.
Thoughts? Cheers, --EA
|
|
|
|
|
Here are some possible solution you might consider it.
eddieangel wrote
1. I can pop up the new window, and have it generate the report and then return a view, but if the user closes that window before the report is done there is a problem.
You can use jQuery or javascript that prompts the user to confirm whether or not he/she wants to close the process.
$(window).unload( function () {
var result = comfirm("Are you sure you want close this window ?");
if(result) {
$.ajax({
type: "POST",
url: "ProcessReportPDF/GeneratePDF",
data: "{}",
contentType: "application/json; charset=utf-8",
dataType: "json",
success: function(msg) {
alert("Process successfully halted!");
}
});
}
});
eddieangel wrote
2. The view doesn't get returned until the report is done, making it a useless blank window until the report is done where it would be nice to even have it say just something until the report is done.
You can use a jQuery UI progress bar[^] before showing the actual generated report.
Hope it will help you well.
Wonde Tadesse
MCTS
|
|
|
|
|
Has anyone ever developed an electronic health record system in .Net? Is this something one person could develop or does it require a team?
|
|
|
|
|
fresh1207 wrote: Has anyone ever developed an electronic health record system in .Net? Is this something one person could develop or does it require a team?
not sure this is the right forum for either of these questions. complexity of a project can only be measured by the size of the requirements behind it.
in my experience... I have seen two different EHRS systems built in ASP.Net and both were done with a team of engineers.
as if the facebook, twitter and message boards weren't enough - blogged
|
|
|
|
|
This is definitely NOT something to be done by a single person. I've been involved in projects for this, using .NET, that included teams of developers, business analysts and legal representatives.
No comment
|
|
|
|
|
I'm developping a demo HRS system and let me say it is very very complex, you can reuse the requirements from HL7, I have a huge quantity of documents about it from my Thesis.
|
|
|
|
|
|
Please don't post links to questions in other forums. Your original question has already received some responses. If you need more help then edit your question, or respond to the people who have offered advice.
Unrequited desire is character building. OriginalGriff
I'm sitting here giving you a standing ovation - Len Goodman
|
|
|
|
|
Hi,
How to block the login of same user at different location in asp.net.
Thankyou,
ypki
|
|
|
|
|
Do you mean to allow users to login on one machine only such that they can't simultaneously login from another machine? Presumably you are tracking that users have logged in? If so, there are a number of ways to do this, the simplest being check to see if they are already logged in if. If they are, refuse the new login. You could also capture the IP address of the machine and refuse a login from another IP address if they are still logged in on the first machine. This also means handling logging out and dead sessions - leave you to figure out the nuts and bolts of all of this as appropriate to your application.
"If you think it's expensive to hire a professional to do the job, wait until you hire an amateur." Red Adair.
nils illegitimus carborundum
me, me, me
|
|
|
|
|
hi friends
i need to know how to dynamically add textboxes on the click of a button
say:
if i click the button once 1 textbox should be added
if i click the button second time another textbox should be added and so on...
so how to do it...
any help
K.Gayathri
|
|
|
|
|
public partial class newTemplate : Form
{
int i = 0;
int x = 22;
int noofcontrols = 0;
TextBox[] t1 = new TextBox[25];
Label[] l1 = new Label[25];
private void button2_Click(object sender, EventArgs e)
{
t1[i] = new TextBox();
l1[i] = new Label();
t1[i].Size = new System.Drawing.Size(244, 22);
t1[i].Location = new System.Drawing.Point(85, x);
l1[i].Location = new System.Drawing.Point(60, x);
l1[i].Font =new System.Drawing.Font("Microsoft Sans Serif", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
l1[i].Text = i.ToString()+". ";
t1[i].TabIndex = i;
t1[i].Name = "txt"+i;
panel1.Controls.Add(t1[i]);
panel1.Controls.Add(l1[i]);
panel1.AutoSize = true;
panel1.Show();
panel1.Refresh();
t1[i].Focus();
i++;
x = x +30 ;
noofcontrols++;
}
}
|
|
|
|
|
Seeing that this is posted under asp.net i will give you a client side solution in "jQuery":
<div id="divWithTextBoxes">
<input class="text-boxes" runat="server" type="text" />
</div>
<input id="btnGenerateTxtBoxes" runat="server" type="button" onclick="GenerateTextBoxes( $('#divWithTextBoxes') );" />
function GenerateTextBoxes( sender )
{
var txtBoxHtml = '<input class="text-boxes" runat="server" type="text" />';
sender.append( txtBoxHtml );
}
To make it easier for you, i added a css class (text-boxes) that you can later use to retrieve the values of your textboxes if need be and below is how you can achieve that using "jQuery":
function GetTextBoxValues()
{
var arrayOfValues = [];
$( '.text-boxes' ).each( function(){
if( $(this).val() != '' )
{
arrayOfValues.push( $(this).val() );
}
});
}
Hope that helps,
Morgs
|
|
|
|
|
now I need to request one thing,
in my database table, there is date column as datatime value.
I want to generate using the year of this 'date' column.
for example , I want to do like below:
id | name | date | caseID
1 | Peter | 12/1/2011 12:00:00 AM | 201100001
2 | Willam | 12/2/2011 12:00:00 AM | 201100002
3 | Willam | 12/3/2011 12:00:00 AM | 201100003
4 | Alex | 1/1/2012 12:00:00 AM | 201200001
5 | Willam | 2/2/2013 12:00:00 AM | 201300001
in this table,
in 'caseID' column, I want to generate like above..
for year 2011,
201100001 // (2011(year) + 00001)
201100002 //(2011(year) + 00002)
....
201100010 //(2011(year) + 00010)
When reached year 2012, I want to auto start from 00001 like that:
201200001
201200002
...and so on.
please help me how I have to do for caseID column in my example table.
thanks all.
how I have to pass year parameter value & how I have to create user defined function. please
|
|
|
|
|
|
|
|
Are you talking about this.
It uses System.IO.Compression
|
|
|
|
|
Kindly note that I am starting to learn ASP.NET4 thus the way I am wording my question might not be good.
Anyway, I would like to display all the records retrieved from a database via a data reader. At this moment I am simply doing it as follows:
. . .
. . .
SqlDataReader reader = cmd.ExecuteReader();
// Display the records on generic gridview.
grdvEmail.DataSource = reader;
grdvEmail.DataBind();
reader.Close();
And grdvEmail is very basic one thus for my output I simply get the following basic display:
ID LastName FirstName EmailAddress
71 Chan Jackie food@bluegarden.com
72 Kuzi Joseph food@goldengate.com
73 Kuzii John foods@goldengate.com
.
.
.
95 Zeta Kyle fuzzy@share.com.com
How could I make the display in such a way that I can scroll down and up the available list, and then one a row is currently highlighted or selected, if I select an Edit button that is located below the current display, a new form containing the detail record for the currently selected or hihglighted row will be displayed.
Kindly note that the header texts have to be changed also.
It does not have to be gridview to do the display. I know this is a very basic question, but once I know how to do simple things like this learning and doing work with ASP.NET 4 will be easier for me because I understand already know how to do the database programming.
Any better suggestion? I do not know whether I have to use ObjectDataSource to do a better display. Thanks.
|
|
|
|
|
You need to add some sort of trigger or button, and double click on it to wire up a command function.
in the command function, as the control for the selected value
if page.ispostback
dim iValue as Integer
iValue = controlName.SelectedValue
if iValue > 0 Then
|
|
|
|
|
Thank you for your reply. After doing some changes, my new questions now are the ones shown on the message below. Please let me know your suggestions.
|
|
|
|
|
Hi,
For displaying scroll bar in grid view you can use an asp:panel.
<asp:panel id="pnlGrid" runat="server" <b="">Scrollbars="Vertical"/>
On The Edit button click you can use another panel and show it when you edit a grid view row.
This panel would consists of text boxes which would display the selected row's details in brief.
You can use grid view rowcommand event for displaying details of the selected row
<asp:templatefield headertext="ID">
<itemtemplate>
<asp:linkbutton id="lnkbtnEdit" runat="server" commandargument="<%#Eval("ID")%>" commandname="Select">
Note:Eval is a databinding expression.
You can maintain the datasource in session
and filter values in datasource based upon the command argument.
protected void GridView_RowCommand(object sender, GridViewCommandEventArgs e)
{
if(e.CommandName=="Select")
{
string ID=Convert.ToString(e.CommandArgument.ToString());
DataView gridviewData=(DataView)this.Session["DS"];
DataRow[] selectedRow = gridviewData.Table.Select("ID=" + ID);
if (selectedRow[0] != null)
{
DataRowW currRow=selectedRow[0];
txtEmailadd.text=currRow["EmailAdd"].tostring();
}
}
}
<div class="signature">Cheers
SyedMuneem</div>
|
|
|
|
|
 Hello, SyedMuneem.
My current code is shown below. I could see the vertical scrollbar in case there are many corresponding records to be display. My other questions now are:
(1)When I scroll up or down, the very first header line moves up or down also. How do I make the very first header line fixed?
(2)The very last column, the PersonSeq, if I click, I am actually displaying another form from which I can edit the various fields that can be edited.
What I would like to do finally is get rid or hide that PersonSeq column and be able to click on or select any row just like any row in a scrollable textbox.
And once I have clicked on or selected any row, if I would like to edit that currently selected row, I would just click one "EDIT" button at the very bottom of the panel(?) and then that is when I would like to call that separate form for editing the details of that selected. How do I do this, and how do I pick up the PersonSeq of the row/record that I clicked (or selected) on so I could pass it to that separate form for editing. The point is I do not want to use the gridview's provided edit/select buttons that are on each row or record of the gridview.
<asp:Panel ID="Panel1" runat="server" ScrollBars="Auto" Width="100%" Height="350px">
<asp:GridView ID="gridViewPersonInfo" runat="server" AutoGenerateColumns="False"
CellPadding="4" ForeColor="#333333" GridLines="None"
onselectedindexchanged="gridViewPersonInfo_SelectedIndexChanged">
<AlternatingRowStyle BackColor="White" ForeColor="#284775" />
<Columns>
<asp:BoundField DataField="EmailAddress" HeaderText="Email Address" />
<asp:BoundField DataField="LastName" HeaderText="Last Name" ReadOnly="True" />
<asp:BoundField DataField="FirstName" HeaderText="First Name" ReadOnly="True" />
<asp:ButtonField CommandName="Select" DataTextField="PersonSeq"
HeaderText="Person Seq" Text="Button" />
</Columns>
<EditRowStyle BackColor="#999999" />
<FooterStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
<HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
<PagerStyle BackColor="#284775" ForeColor="White" HorizontalAlign="Center" />
<RowStyle BackColor="#F7F6F3" ForeColor="#333333" />
<SelectedRowStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" />
<SortedAscendingCellStyle BackColor="#E9E7E2" />
<SortedAscendingHeaderStyle BackColor="#506C8C" />
<SortedDescendingCellStyle BackColor="#FFFDF8" />
<SortedDescendingHeaderStyle BackColor="#6F8DAE" />
</asp:GridView>
</asp:Panel>
|
|
|
|
|
Would love to help, but I don't do gridview questions.
|
|
|
|