|
You are write it's an Attribute for the Main method.
Which marks it as "Single-Threaded apartment" like 'Michael Sync'[^] said befor!
-- modified at 3:55 Monday 9th July, 2007
|
|
|
|
|
It's not for marking the entry point but rather specifying the threading model. See here[^] for some details.
Steve
|
|
|
|
|
Hallo,
Thank's for the link.
I shouldn't replay out of a hurry, I know!
A quite lousy statement from me.
Sorry for that!
All the best,
Martin
|
|
|
|
|
it just make ur app as "Single-Threaded apartment"
|
|
|
|
|
|
this threrad is for keeping updating the GUI of your form i think!
|
|
|
|
|
Sir,
Actually I have written following code to export a crystal report in excel. It works in my local PC very well but it's not working in Web server.Ms-Excel is available in web server.Second thing is that if I convert it in .pdf then it's working successfully.Just I face problem in excel only.So I can't rectify the problem?? I think some driver or patches are used in this code which are not available in web server.Can u send me the list of pre-required components??
Sir pls reply immediatly.It's very imp.
My code is
ReportDocument oRD = new CrystalDecisions.CrystalReports.Engine.ReportDocument();
DiskFileDestinationOptions oExDo = new CrystalDecisions.Shared.DiskFileDestinationOptions();
oRD.Load(Request.ServerVariables["APPL_PHYSICAL_PATH"].ToString() + "Weekly_Reports\\crpCommonFieldCom.rpt");
ReportDefinition oDef = oRD.ReportDefinition;
// Sub Report1
foreach(ReportObject obj in oDef.ReportObjects)
{
if (obj is SubreportObject)
{
SubreportObject oSub1 = (SubreportObject)obj;
ReportDocument oRdSub1 = oSub1.OpenSubreport(oSub1.SubreportName);
if (oSub1.SubreportName == "crpM35.rpt")
{
oRdSub1.Database.Tables[0].SetDataSource(ds.Tables["M35"]);
}
if (oSub1.SubreportName == "crpM30.rpt")
{
oRdSub1.Database.Tables[0].SetDataSource(ds.Tables["M30"]);
}
if (oSub1.SubreportName == "crpM25.rpt")
{
oRdSub1.Database.Tables[0].SetDataSource(ds.Tables["M25"]);
}
}
}
ExportOptions oExO;
string strFile = Path.GetTempPath() + Session.SessionID.ToString() + ".xls";
oExDo.DiskFileName = strFile;
oExO = oRD.ExportOptions ;
oExO.ExportDestinationType = ExportDestinationType.DiskFile ;
oExO.ExportFormatType = ExportFormatType.Excel;
oExO.DestinationOptions = oExDo;
oRD.Export();
oRD.Close();
Response.ClearContent();
Response.ClearHeaders();
Response.ContentType = "application/vnd.ms-excel";
Response.WriteFile(strFile);
Response.Flush();
Response.Close();
//delete the exported file from disk
System.IO.File.Delete(strFile);
khushbu patel
Reliance Industries Limited,
Software Developer,
Jamnagar.
|
|
|
|
|
Did u use any other javascript funtion in your page??? I think it is better if you try ur sample in blank page. and see whether it works or not..
|
|
|
|
|
Hi!
I make a DEVICE APPLICATION (windows form not webform!!!)and i need help!
Can anybody tell me how to insert into a datagrid a checkbox column?
Thank you!
Marta Paniti.
-- modified at 5:23 Monday 9th July, 2007
--------------------------------
visit: http://pmartike.deviantart.com/
|
|
|
|
|
|
winform for pocketPC
--------------------------------
visit: http://pmartike.deviantart.com/
|
|
|
|
|
|
Check the checkedbox "Ignore HTML tags in this message (good for code snippets)" when pasting the code.
|
|
|
|
|
Hello,
razanabanu wrote: What happened?..
You posted a lot of empty messages!
razanabanu wrote: Sorry I cant paste my coding here
You can, I'm sure!
razanabanu wrote: I dont know what happened
You forgot to turn the HTML tags off.
'Ignore HTML tags in this message'
Or use the 'pre Tags
P.S.: You should delete the other posts!
All the best,
Martin
-- modified at 3:45 Monday 9th July, 2007
Again I forgot to say:
Not the one with the responses!
You can modify that one!
|
|
|
|
|
<Columns>
<asp:TemplateColumn HeaderText="ItemCode">
<ItemTemplate>
<asp:CheckBox ID="ch" OnCheckedChanged="ch_CheckedChanged" Runat="server" AutoPostBack="True" Text='<%#DataBinder.Eval(Container.DataItem,"itemcode")%>'>
</asp:CheckBox>
<asp:TextBox ID="txt" Runat="server" AutoPostBack="True" Text='<%#DataBinder.Eval(Container.DataItem,"itemname")%>'>
</asp:TextBox>
</ItemTemplate>
</asp:TemplateColumn>
</Columns>
Hi,Im Razana
|
|
|
|
|
but i need for winform ...
--------------------------------
visit: http://pmartike.deviantart.com/
|
|
|
|
|
Hi All!!,how can I implement API in C# we Application.Im a beginner...so please give me a simple sample code to implement it in C# WEB Form...
Hi Satips and Christian...how are you?,other members too...
Hi,Im Razana
|
|
|
|
|
|
Hello!
I'm trying to read some data in from Excel.
Now the spreadsheets that I'm accessing contain columns of data, and these columns may sometimes be blank, the main table might start a few columns in and so on.
A raggedy old spreadsheet!
In addition to this I don't know how many rows or columns there will be, so I need to be able to handle this.
All the examples I've seen in the searches I've made have hard-coded limits.
For example my table might look like this (can't quite format this right, but you'll get the idea):
DEPT.M LLD.OHMM MSFL.OHMM RHOB.G/CM3 NO SONIC IGLOO FISH#
1450 12.4303 2.279 2.3188
1450.25 12.4494 5.0599 2.3323
1450.5 14.7747 2.0675 2.2776
1450.75 14.768 1.2149 2.217 0.3974
1451 13.1767 0.4151
1451.25 16.8165 0.2921 0.3974
1451.5 29.4913 0.4151
1451.75 48.8114 0.2921
1452 44.7025
1452.25 28.3492
1452.5 19.2471 2.2749 2.1967 13.1371 0.3974
1452.75 13.4801 1.8502 2.232 13.3881 0.4151
1453 3.2926 2.3583 13.8325 0.2921
1453.25 3.6341 2.4099
1453.5 4.1754 2.356 102.0509 16.9615 10.3197
1453.75 16.9615 5.3556 2.3608 106.603 18.0078 10.7229
1454 18.0078 4.9902 2.3258 105.3982 17.1981 10.2939
1454.25 17.1981 4.6068 2.249 108.3167 16.2081 9.6294
1454.5 16.2081 3.389 2.2199
1454.75 15.7188 1.9904 2.1252
1455 18.0351 128.8776 1.7491
1455.25 28.9451 656.4312 1.4863
1455.5 43.2879 65.2774 1.6644
1455.75 31.8807 12.309 2.182
1456 18.3605 9.6465 2.3213
1456.25 19.039 7.1053 2.1123
1456.5 25.825 9.4629 1.6977
I have this kind of example below, but the limits are hard-coded. How can I get the correct limits so that I can read the whole sheet, regardless of it's size?
<br />
<br />
Excel.Worksheet worksheet = (Excel.Worksheet)sheets.get_Item(1);<br />
<br />
for (int i = 1; i <= 10; i++)<br />
{<br />
Excel.Range range = worksheet.get_Range("A"+i.ToString(), "J" + i.ToString());<br />
System.Array myvalues = (System.Array)range.Cells.Value2;<br />
string[] strArray = ConvertToStringArray(myvalues);<br />
... etc<br />
}<br />
<br />
But what I really want is (pseudo-code in CAPS):
<br />
for (int i = 1; i <= worksheet.NUMBER_OF_ROWS; i++)<br />
{<br />
Excel.Range range = worksheet.get_Range(THE_WHOLE_ROW[i]);<br />
System.Array myvalues = (System.Array)range.Cells.Value2;<br />
string[] strArray = ConvertToStringArray(myvalues);<br />
.. etc <br />
}<br />
Or maybe there's a better way to get at all the data?
Thanks in advance for any help you can offer.
-- modified at 2:42 Monday 9th July, 2007
|
|
|
|
|
Hopefully this is still relevant to you . . .
to do worksheet.get_Range(THE_WHOLE_ROW[i])
we use this snippet:
int lastUsedColumn = worksheet.Cells.SpecialCells(XlCellType.xlCellTypeLastCell, Type.Missing).Column;
Range firstCell = (Range)worksheet.Cells[rowNumber, 1];
Range lastCell = (Range)worksheet.Cells[rowNumber, lastUsedColumn];
Range wholeRow = worksheet.get_Range(firstCell, lastCell);
|
|
|
|
|
|
Hi,
I was checking on of our dlls using Resourcer, and found that Switch case was converted to If - Else loop in the dll. Is this done by framework compiler or by Resourcer?
If this is done by the compiler, why don't we directly use If - Else instead if Switch case?
Could anyone throw some light on this?
Regards,
Blumen
|
|
|
|
|
Not sure. I'd suspect the compiler decides how to generate the IL code...
"Any sort of work in VB6 is bound to provide several WTF moments." - Christian Graus
|
|
|
|
|
Hi ,
How can I Set the Parent of Control On Any Form to Desktop?
ie. want to set controls parent as Desktop ,not the form which contains
the control.
Fly Like An Eagle With MIGHTY POWER.
|
|
|
|
|
I have written all the commands required to do live serach in a method.I am calling that method asynchronously using threads.Although I have created 20 threads and calling the search method from all these 20 threads.(It's Like If have a paragraph with 20 sentences, I want to call my search method 20 times asynchronously without waiting for first one to complete. )The problem is when I moniter my network traffic I can only see 2 connections to the server Instead of 20.Can anybody tell me what is the problem why I can't make 20 connections to MSN Live server.From my programs trace I can see that all 20 treads are being created and callback is also happening for all 20, but what I feel they all are using same 2 connections thus I can't see a boost in performance.
Note I am using synchronous version of MSN web Search method.
|
|
|
|