|
Does that compile?
tp[0] is a Process but not an XProcess, so the method does not return the type its declaration promised.
Luc Pattyn [Forum Guidelines] [My Articles]
- before you ask a question here, search CodeProject, then Google
- the quality and detail of your question reflects on the effectiveness of the help you are likely to get
- use the code block button (PRE tags) to preserve formatting when showing multi-line code snippets
|
|
|
|
|
opppss i copied old one, corrected now
TVMU^P[[IGIOQHG^JSH`A#@`RFJ\c^JPL>;"[,*/|+&WLEZGc`AFXc!L
%^]*IRXD#@GKCQ`R\^SF_WcHbORY87֦ʻ6ϣN8ȤBcRAV\Z^&SU~%CSWQ@#2
W_AD`EPABIKRDFVS)EVLQK)JKSQXUFYK[M`UKs*$GwU#(QDXBER@CBN%
Rs0~53%eYrd8mt^7Z6]iTF+(EWfJ9zaK-iTV.C\y<pjxsg-b$f4ia>
--------------------------------------------------------
128 bit encrypted signature, crack if you can
|
|
|
|
|
Luc Pattyn [Forum Guidelines] [My Articles]
- before you ask a question here, search CodeProject, then Google
- the quality and detail of your question reflects on the effectiveness of the help you are likely to get
- use the code block button (PRE tags) to preserve formatting when showing multi-line code snippets
modified on Sunday, June 12, 2011 8:12 AM
|
|
|
|
|
HAHAHA http://www.codeproject.com/script/Forums/View.aspx?fid=1649&msg=2927732
TVMU^P[[IGIOQHG^JSH`A#@`RFJ\c^JPL>;"[,*/|+&WLEZGc`AFXc!L
%^]*IRXD#@GKCQ`R\^SF_WcHbORY87֦ʻ6ϣN8ȤBcRAV\Z^&SU~%CSWQ@#2
W_AD`EPABIKRDFVS)EVLQK)JKSQXUFYK[M`UKs*$GwU#(QDXBER@CBN%
Rs0~53%eYrd8mt^7Z6]iTF+(EWfJ9zaK-iTV.C\y<pjxsg-b$f4ia>
--------------------------------------------------------
128 bit encrypted signature, crack if you can
|
|
|
|
|
I'm using The COM component wmp.dll but when I add the component I cant see the pause,stop,volume etc. buttons. Can you help me about it?
Thanks in advance.
|
|
|
|
|
These are the relevent lines from the code. The same file is being opened, the problem is that the program can't find the sheet when running under XPPRo, 2003 server, or Vista Business. All computers are up to date with the latest .net installed, all have Excel 2003 with current updates. Any ideas?
string listname = "Sheet1";
OleDbConnection con = new OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" + filename + ";Extended Properties=Excel 8.0");
con.Open();
try
{
DataSet myDataSet = new DataSet();
OleDbDataAdapter myCommand = new OleDbDataAdapter(" SELECT * FROM [" + listname + "$]", con);
myCommand.Fill(myDataSet);
All Systems have Excel 2003 SP3
I get an error message on the failures:
System.Data.OleDbException: The Microsoft Jet database engine could not find the object 'Sheet1$'
modified on Tuesday, February 17, 2009 12:14 PM
|
|
|
|
|
Try using this as a connection string instead
"Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" + filename + ";Extended Properties = 'Excel 8.0;HDR=Yes;IMEX=1'";
I am going with the presumption that "filename" is an actual path and "Sheet1" does exist in all cases....
butyou know what they say about presumptions
|
|
|
|
|
You are correct. Filename is a variable holding the full path of the actual file, and sheet1 does exist in all cases, as in each instance, I have copied the file from one to another.
What is the "IMEX=1" all about?
|
|
|
|
|
Darn! Still no good. It makes no sense to me. Why fine on one but not on others?
I used to say that I liked programming because of the instant gratification when you compile an app and it works, but this is an example of the dark counterpoint to that. Instant frustration.
|
|
|
|
|
HDR=Yes; Indicates that there are header rows in the sheet,
and IMEX=1; 0 Export mode, 1 Import mode, 2 Linked mode,
I run Imports from excel in 98/XP/Vista with that connection and its all good.
How are you defining your path ie:Filename??
|
|
|
|
|
This is all the relevant code. I just don't get why it would work for the one system but not the others.
string filename = "C:\\Program files\\Daily_Totals_By_Employee.xls";
string listname = "Sheet1";
OleDbConnection con = new OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" + filename + ";Extended Properties = 'Excel 8.0'");
con.Open();
try
{
DataSet myDataSet = new DataSet();
OleDbDataAdapter myCommand = new OleDbDataAdapter(" SELECT * FROM [" + listname + "$]", con);
myCommand.Fill(myDataSet);
con.Close();
|
|
|
|
|
I would try to put the file in a location like "C:\\Myfolder" just to test
eliminate the "Program files" directory and see what happens, also punch in the path manually
Data Source= C:\Myfolder\Daily_Totals_By_Employee.xls
See if any of those work...sorry I can't be any more specific...
|
|
|
|
|
I just tried the path suggestion. I changed the path to
"C:\\csharpdata\\Daily_Totals_By_Employee.xls".
No change.
At the risk of being obtuse, I don't understand how permissions could be the problem. I'm not saying you're all wrong, just that I don't understand it. The file is being opened: wouldn't a permissions issue prevent that? The program opens the file then fails to find the sheet.
|
|
|
|
|
Hi all
I'm a dev newbie and am struggling to get my listbox to work they way i want it to. Basically, i want to be able to store the results of my stored procedure within a listbox control - so for example, if my sproc returns ServerID (primarykey) and ServerName (text column), i want this bound to my listbox control.
In my app i have created a datareader which contains the results of my query. As i loop through the datareader, i want to bind my ServerID and ServerName values to the listbox.
At the moment, I can get ServerName to display in my listbox by implementing the following:
listbox.items.add(System.Convert.ToString(reader[1]));
I then assume i need the following code to assign my query results to the displaymember and valuemember properties:
lbServerList.DisplayMember = reader[1].ToString();
lbServerList.ValueMember = reader[0].ToString();
Now i want to be able to select a server from my drop down list, and get the associated serverid. So for testing purposes, i've created a button and when i click the button, i want the serverid corresponding to the selected servername in my listbox, to be written to a textbox:
if (lbServerList.ValueMember != null)
{
textBox.Text = listbox.ValueMember;
}
A number is indeed written to the textbox but it is a random number which doesn't link to the selected servername, and the number doesn't change no matter what server i select.
Can someone please help fill the gaps in my understanding???
I need to know first whether i'm populating the listbox correctly, and then secondly how to retrieve my serverid from it.
Thanks!
Di
|
|
|
|
|
divinyl wrote: lbServerList.DisplayMember = reader[1].ToString();lbServerList.ValueMember = reader[0].ToString();
its not like this...
first of all make a class that will hold your data(server name and id thing) with the properties
class XHolder
{
string name;
string id;
public string Name
{ get{ return name;} set { name = value; } }
public string ID
{ get{ return id;} set { id = value; } }
}
now you can use Generic list and add like this
List<xholder> dataSource = new List<xholder>();
dataSource.Add(new XHolder(reader[0].ToString(), reader[1].ToString()));
lbServerList.DataSource = dataSource;
lbServerList.DisplayMember = "Name";
lbServerList.ValueMember = "ID";</xholder></xholder>
I wrote code in CP, it may have errors
TVMU^P[[IGIOQHG^JSH`A#@`RFJ\c^JPL>;"[,*/|+&WLEZGc`AFXc!L
%^]*IRXD#@GKCQ`R\^SF_WcHbORY87֦ʻ6ϣN8ȤBcRAV\Z^&SU~%CSWQ@#2
W_AD`EPABIKRDFVS)EVLQK)JKSQXUFYK[M`UKs*$GwU#(QDXBER@CBN%
Rs0~53%eYrd8mt^7Z6]iTF+(EWfJ9zaK-iTV.C\y<pjxsg-b$f4ia>
--------------------------------------------------------
128 bit encrypted signature, crack if you can
|
|
|
|
|
Hi guys!
I'm struggling with a weird problem I'm unable to solve so far.
I want to enable drag&drop of mail attachments from Outlook.
This does work when my drop target is, for example, a Form or a Panel ; I can get all the file names and contents, no problem.
As soon as I try the same with a RichTextBox as drop target, it doesn't work - whatever I set the desired DropEffect to (usually DropEffect.Copy ), the cursor is always DropEffect.Move when dragging files from Explorer over the RTB (minor nuisance) and DropEffect.None if I drag mail attachments from Outlook (showstopper).
It doesn't matter if I set the effect in DragEnter or DragOver , if EnableAutoDragDrop is true or false, I've even tried loading a Rich Edit control 4.1 instead of the default V2.0, but to no avail.
Can anyone help?
Thanks in advance!
Regards,
mav
--
Black holes are the places where God divided by 0...
|
|
|
|
|
I think its windows inbuilt text effects...
well, try this
TVMU^P[[IGIOQHG^JSH`A#@`RFJ\c^JPL>;"[,*/|+&WLEZGc`AFXc!L
%^]*IRXD#@GKCQ`R\^SF_WcHbORY87֦ʻ6ϣN8ȤBcRAV\Z^&SU~%CSWQ@#2
W_AD`EPABIKRDFVS)EVLQK)JKSQXUFYK[M`UKs*$GwU#(QDXBER@CBN%
Rs0~53%eYrd8mt^7Z6]iTF+(EWfJ9zaK-iTV.C\y<pjxsg-b$f4ia>
--------------------------------------------------------
128 bit encrypted signature, crack if you can
|
|
|
|
|
Thanks, but what exactly do you mean by "windows inbuilt text effects"?
It's not that I don't know how to handle drag&drop from outlook in general (it's working fine on non-RichTextBox controls as drop targets). The question is how to make the RTB appreciate the DragDropEffect I set in the DragEnter /DragOver events and not to tell the user that he can't drop an attachment there when I explicitely set the DragDropEffect to Copy .
Regards,
mav
--
Black holes are the places where God divided by 0...
|
|
|
|
|
mav.northwind wrote: but what exactly do you mean by "windows inbuilt text effects"?
that mean windows is handling that drag drop itself as text content...
TVMU^P[[IGIOQHG^JSH`A#@`RFJ\c^JPL>;"[,*/|+&WLEZGc`AFXc!L
%^]*IRXD#@GKCQ`R\^SF_WcHbORY87֦ʻ6ϣN8ȤBcRAV\Z^&SU~%CSWQ@#2
W_AD`EPABIKRDFVS)EVLQK)JKSQXUFYK[M`UKs*$GwU#(QDXBER@CBN%
Rs0~53%eYrd8mt^7Z6]iTF+(EWfJ9zaK-iTV.C\y<pjxsg-b$f4ia>
--------------------------------------------------------
128 bit encrypted signature, crack if you can
|
|
|
|
|
I’m a new developer in a very complex project. I like to create a program that can plot the methods that is executing in the program to get a fast view of what is calling what. Of course I can debug the program but the best way right now is to write some code like this:
StackTrace s = new StackTrace();
CallAMettodThatDoesALotOfOtherCalls();
s.PrintAllCalledMethodsInAnEasyToReadWay();
Any tip on code/tool that manages that?
_____________________________
...and justice for all
|
|
|
|
|
Not that I know of, but I'd sure like a copy of such a tool if you can find it
I are troll
|
|
|
|
|
Hi,
I have a webform that shows summary information at the top of the page.
If there is only one "row" in the database for the associated project, the summary looks like this:
Tool_ID= "returned value"
Tool ="returned value"
Tool_Quantity= "returned value"
However if there are multiple tool_ids associated with the project in session (ex, 2 tools), the summary will display each tool in its own column:
Tool_ID= "returned value" Tool_ID= "returned value"
Tool ="returned value" Tool ="returned value"
Tool_Quantity= "returned value" Tool_Quantity= "returned value"
The maximum number of Tool_ids that can be associated with any project is 3. I have a query that will search the project and get the tool_ids, tool and tool_quantity, but I dont know how to code in to display the output as I have listed above. I also need this to be able to get updated as the user can add more tools to the project before submission. Please help!
Thank you
|
|
|
|
|
I have created an application and I am using a panel to load and display custom user controls.
In all these custom controls, there is need save data or cancel changes. I want to design a menu or a tool bar with the save and cancel commands such that changes are saved or cancel depending on the control currently displayed. The save changes command is a little complex for me because the code for saving data would be different for each control. How can I design my menu/tool bar such that the right code executes depending on the displayed control?
Secondly, in my display panel how can I get a "reference" ton the currently displayed/visible control. There could be other controls in the back ground hidden by the current control but I just to be able to reference only the top-most control. NB When I load a control, set I it to fill up the entire panel space which hides any control that may have been visible before but I suppose that does not necessarilly set the visible flag of the previous control to false so. So I can't use the Visible property to check for the "visible" control.
Thanks for you help.
|
|
|
|
|
Here I am trying to fill the tree view category and subcategory wise..see the below
|Benson and Hedges
|Kings Gold Falke
Beverages
| |-Beers
| |-Bell Lager 500 ML
| |-CLUB PILSENER 500 ML
| |-Juices
| |-Apple Juice
| |-Chikooo Juice
|-Food
| |-MeatProducts
| |-GOAT MEAT
| |-Fruits
| |-APPLE GREEN
| |-LOCAL ORANGES
|-VegeTable |
| |-BEETROOT
| |-TOMATO FRESH
I have tried the following code..but I am able to fill only one product under one sub category. Please help me out how to??initialize and fill the data into tree view
foreach (DataRow row in table.Rows)
{
MainNode = new TreeNode(row.ItemArray[0].ToString());
MainNode.Name = row.ItemArray[0].ToString();
if (MainNode.Text == "")
{
}
else
{
ChildNode = new TreeNode(row.ItemArray[1].ToString());
ChildNode.Name = row.ItemArray[1].ToString();
if (ChildNode.Text == "")
{
ChildNode = new TreeNode(row.ItemArray[3].ToString());
ChildNode.Name = row.ItemArray[3].ToString();
ChildNode.Tag = row.ItemArray[2].ToString();
if (!MainNode.Nodes.ContainsKey(ChildNode.Name))
{
MainNode.Nodes.Add(ChildNode);
} }
else
{
SubNode = new TreeNode(row.ItemArray[3].ToString());
SubNode.Name = row.ItemArray[3].ToString();
SubNode.Tag = row.ItemArray[2].ToString();
if (!ChildNode.Nodes.ContainsKey(SubNode.Name))
{
ChildNode.Nodes.Add(SubNode);
} }
if (!MainNode.Nodes.ContainsKey(ChildNode.Name))
{
MainNode.Nodes.Add(ChildNode);
}
else
{
for (int i = 0; i <= MainNode.Nodes.Count; i++)
{ MainNode.Nodes.Add(ChildNode);
} }
if (!RootNode.Nodes.ContainsKey(MainNode.Name))
{
RootNode.Nodes.Add(MainNode);
} } } }
|
|
|
|
|
Problem is
for (int i = 0; i <= MainNode.Nodes.Count; i++)
{ MainNode.Nodes.Add(ChildNode);
}
why this loop...you should learn about recursive methods
TVMU^P[[IGIOQHG^JSH`A#@`RFJ\c^JPL>;"[,*/|+&WLEZGc`AFXc!L
%^]*IRXD#@GKCQ`R\^SF_WcHbORY87֦ʻ6ϣN8ȤBcRAV\Z^&SU~%CSWQ@#2
W_AD`EPABIKRDFVS)EVLQK)JKSQXUFYK[M`UKs*$GwU#(QDXBER@CBN%
Rs0~53%eYrd8mt^7Z6]iTF+(EWfJ9zaK-iTV.C\y<pjxsg-b$f4ia>
--------------------------------------------------------
128 bit encrypted signature, crack if you can
|
|
|
|