|
You're looking for employees ?
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
This is not the rite place to do your company marketing.
|
|
|
|
|
Hi all..
I have a aspx page with a datagrid holding values in it..I need to write the datagrid values in the excel for which i use the following code..
Private Sub btnexcel_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnexcel.Click
Response.Clear()
Response.AddHeader("content-disposition", "attachment;filename=FileName.xls")
Response.Charset = ""
Response.Cache.SetCacheability(HttpCacheability.Public)
Response.ContentType = "application/vnd.xls"
Dim stringWrite As New System.IO.StringWriter
Dim htmlwrite As New System.Web.UI.HtmlTextWriter(stringWrite)
dtgdisplay.RenderControl(htmlwrite)
Response.Write(stringWrite.ToString())
Response.End()
End Sub
Everything is ok..But the datagrid contains column and rows with numeric values(16 digits).So when i write it in excel i am getting them in scientific format..Even when i am formatting the cells ,i couldn't the exact values which are in the datagrid..
Someone help in this regard...
Balaguru
|
|
|
|
|
Try this - This code is in c# and you need to use your way to get datatable instead over sqlhepler.
-----------------------
string sql = 'Select * from user_MASTER';
DataTable dt = SqlHelper.ExecuteDatatable(SqlHelper.ConnectionString, CommandType.Text, sql);
Response.AddHeader("Content-Disposition", "inline;filename=Final.xls");
int i;
for (int icol = 0; icol < dt.Columns.Count; icol++)
{
Response.Write(dt.Columns[icol].ToString() + "\t");
}
Response.Write("\n");
foreach (DataRow dr in dt.Rows)
{
for (i = 0; i < dt.Columns.Count; i++)
{
Response.Write(dr[i].ToString() + "\t");
}
Response.Write("\r");
}
Response.End();
Regards,
Mayank Parmar
Senior Software Engineer
Amba Tech
Gandhinagar, India
|
|
|
|
|
Hi,
How can i parse a character in a dotnet application using c# code?. for ex, i have an application in which i have a username and password. i have to encrypt the password and have to assign a new password for that encrypted password. Can we use Int32.Parse command for that. but how can i use it. pls give me a solution and sample code for this application in C# code.
regards
Vijay
|
|
|
|
|
Goodness knows what you're asking for here. Int32.TryParse and Int32.Parse will try to get a number out of a string. I doubt that is what you mean.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
Hi,
Do anybody know where i get information on:
Authentication on reading card on door system and keep records on database.?
Regards
Vijay
|
|
|
|
|
Hello,
In my ASPX page, I want to show a image from SQL BLOB field. Now, I found the only solution is like this
Now, the handler should query the database and retrieve the binary image file data and show the image.
Ok, what If I want to read the binary image data as byte[] and convert to base64 string and pass the base64 string as query string to the handler, is it possible to implement like this ? In this way, my Handler wont need to query the SQL database, rather it would directly get the GET item from Query string and convert back the base64 string to byte[] and show the image.
I would appreciate if you can give me some better idea to do that. My intension is to provide my client a stand alone and database independant BLOB image viewing solution. Moreover, is it also possible to get rid of a handler and rather it would call a DLL file to show the BLOB image ?
Regards
Bashiwala
|
|
|
|
|
The Article by Ehanthalingam Here[^] will help you.
Regards,
Satips.
|
|
|
|
|
Hi Stips,
Thanks for your reference. But my question is, "Is it possible to send a huge amount of string data (Base64) as a query string to ASHX file in image tag so that the ASHX file can directly parse the binary data from query string and not need to query the database to retrieve the image data ?
OR Is it somehow possible to POST any data to a calling image tag source URL like this ?
<img src="myHandler.ashx"... POST data to ashx file ...NOT GET by query string......
Regards,
Bashiwala
|
|
|
|
|
Hi,
I need to few controls to a panel during run-time, however in the panel a hnl table should be created and then the controls should be added accordingly to the panel.
I have added the controls dynamically to the panel but unable to create a table inside the panel during runtime
Any help is greatly appreciated!
Gautham
|
|
|
|
|
Use Table Control to created table inside the Panel Dynamically.
Eg:
Dim Tbl As New Table<br />
Dim TR As New TableRow<br />
Dim TC As TableCell<br />
<br />
<br />
TC = New TableCell()<br />
TC.Text = "Some Text"<br />
<br />
TR.Cells.Add(TC)<br />
<br />
TC = New TableCell()<br />
TC.Controls.Add(New TextBox())<br />
<br />
TR.Cells.Add(TC)<br />
<br />
Tbl.Rows.Add(TR)<br />
<br />
.... And So on....
Finally Add the Table Control to the Panel. Thats it... Simple!!
|
|
|
|
|
Thanks!
I have done this way too!
But i heard something about add new literal control to a panel, initially had few problems with that because of wrong nmespace given.
Now, both ways it works!!
Gautham
|
|
|
|
|
<asp:LoginName ID="LoginName1" runat="server" <br />
FormatString=" Logged in as {0}" />
the above code is for displaying the login name of the logged in user
is there one for the user logined role?
|
|
|
|
|
The method System.Web.Security.Roles.GetRolesForUser() returns a string[] with all the roles the current user belongs to. Use a Literal/Label, and set the Text property as you like.
|
|
|
|
|
hi
I have one datalist in that I am displaying files (e.g. .txt,.doc etc).
I want to display iocn with file name (e.g. if .txt file is there I want to display notpad icon with it, if .doc file is there i want to display msword iocn etc)
can any one help me
Thanks,
Rushiraj
|
|
|
|
|
Display the Image as an Icon.
Regards,
Satips.
|
|
|
|
|
yes
but how can I find which icon is associated with that particular extension.
Thanks,
Rushiraj
|
|
|
|
|
We can get the images of the icon for word , pdf, txt and insert infront of the Name in the datalist.
Regards,
Satips.
|
|
|
|
|
how to get that image
Thanks,
Rushiraj
|
|
|
|
|
Do you have word and txt and pdf in your system you can keep right click on that image and save it and then use it in yoour Datalist.
Regards,
Satips.
|
|
|
|
|
I don,t want that.
I have web application in that I am displaying files in data list now this file can be of any type .exe, .doc, .psd , .htm , .jpg just any file ,
now I want to display icon associate with file.
e.g. if in my pc .jpg is associate with mspaint I want to dislay paint icon
if in any other pc .jpg is associate with irfan view i want to display irfanview icon for that file
Thanks,
Rushiraj
|
|
|
|
|
When an application is running and the user exit the browser the current web page has gone but the application is still running. How can I exit the application when user exit the browser.
|
|
|
|
|
You don't. The idea is that the application will continue to run on the server waiting for the next request. The server has no concept of a browser being shut down. It just serves up pages.
|
|
|
|
|
Hi,
I have created a web application. it is on my local host. I want that when user type http://twcsdc.com/cms/admin then
my web page should appear here. So how can I convert my application from localhost to above URL.
Thanks,
|
|
|
|