Hi,
I am using ubuntu 9.10 and it comes with gcc 4.4.
How can I install gcc 4.5 without screwing up my gcc 4.4. environment. I just need gcc 4.5 to compile 1 application.
Thank you.
Hello,
I have an application whereby I dynamically create controls on a form from a database.
This works well, but my problem is the following:
private Type activeControlType;
private void addControl(ContainerControl inputControl, string ControlName, string Namespace,
string ControlDisplayText, DataRow drow, string cntrlName)
{
Assembly assem;
Type myType = Type.GetType(ControlName + ", " + Namespace);
assem = Assembly.GetAssembly(myType);
Type controlType = assem.GetType(ControlName);
object obj = Activator.CreateInstance(controlType);
Control tb = (Control)obj;
tb.Click += new EventHandler(Cntrl_Click);
inputControl.Controls.Add(tb);
activeControlType = controlType;
}
private void Cntrl_Click(object sender, EventArgs e)
{
string test = ((activeControlType)sender).Text; //Problem ???
}
How do I dynamically cast the sender object to a class that I can reference the property fields of it.
I have googled, and found myself trying everything I have come across..... Now I am extremely confused... and in need of some help
Thnx
JT
I am personally a SVN lover, but am starting to fall prey to the buzz that is surrounding DVCS.
SVN is free, and time tested, is DVCS the new SVN?
I am also looking for which DVCS server will win out GIT or Mercurial?
Hi,
I have an embedded HTML resource (helloworld.htm) inside my Visual Studio project. (Ie, I've added an HTML file to the project and set its properties to "Embedded Resource".
Within the same application I have a WebBrowser control.
I'd like to direct the WebBrowser control to display the HTML resource using the res:// protocol.
But I can't figure out the exact format needed to address an embedded resource using this style of URL.
Any ideas? Thanks!
Okay i have a custom server control that has some autocomplete settings, i have this as follows and it works fine.
/// <summary>
/// Auto complete settings
/// </summary>
[System.ComponentModel.DesignerSerializationVisibility (System.ComponentModel.DesignerSerializationVisibility.Content),
PersistenceMode(PersistenceMode.InnerProperty),
Category("Data"), Description("Auto complete settings"), NotifyParentProperty(true)]
public AutoCompleteLookupSettings AutoComplete { private set; get; }
I also have a ParameterCollection that is really related to the auto complete settings, currently this collection resides off the control itself like so :
/// <summary>
/// Parameters for any data lookups
/// </summary>
[System.ComponentModel.DesignerSerializationVisibility(System.ComponentModel.DesignerSerializationVisibility.Content), PersistenceMode(PersistenceMode.InnerProperty)]
public ParameterCollection Parameters { get; set; }
What i would like to do is move the parameter collection inside of the AutoCompleteSettings as it really relates to my autocomplete, i have tried this but to no avail..
I would like to move from
<cc1:TextField ID="TextField1" runat='server'>
<AutoComplete MethodName="GetTest" TextField="Item1" TypeName ="AppFrameWork.Utils" />
<Parameters>
<asp:ControlParameter ControlID="txtTest" PropertyName="Text" Name="test" />
</Parameters>
</cc1:TextField>
To
<cc1:TextField ID="TextField1" runat='server'>
<AutoComplete MethodName="GetTest" TextField="Item1" TypeName ="AppFrameWork.Utils" >
<Parameters>
<asp:ControlParameter ControlID="txtTest" PropertyName="Text" Name="test" />
</Parameters>
</AutoComplete>
</cc1:TextField>
I need to determine whether an HTTP request was an HTTP/1.0 or an HTTP/1.1 request in my PHP script, which is running under Apache. Is there a way to query this information?
We have analog IR cameras (not IP Cameras) and they are connected to DVR model no is (DVR Model: DVR H264, 16 Channel - ECOR264-16X1). We assigned a static IP to DVR and able to view all the cameras connected to it.
Our requirement is to view individual cameras and recording option in remote location (the recorded data should store in remote) as like IP Cameras.
Is it possible, if not, are there any DVR Model which can support like this.
I wrote a CSharpScriptBinding roughly equivalent to the PyBinding on CodePlex. It uses the C# script engine from http://www.csscript.net.
After I wrote it, I kind of decided it might not really be something good to use. Although it caches the compiled script code as an already compiled Assembly, my concern is that I will have one temporary Assembly created each time I use the binding. Will this add up to a problem in the future? If so, maybe there is a way in the C# script engine that I don't know about to optimize this further...? Any thoughts to confirm my suspicion that this was just a bad idea (but useful excersise in learning more about bindings and converters)?
I want to download VS 2010 Ultimate through my MSDN licence, but I don't see one for the 64-bit. There's Visual Studio Team Foundation Server 2010 (x86 and x64) - DVD (English), but is that just the server or can I use it for dev too?
I'm trying to configure my Windows 2008 servers so that my developers can view their status without needing to log on to the box or be an admin. Unfortunately, the permissions set in Windows 2008 for remote non-admin users don't include the ability to enumerate or otherwise query services. This causes anything that contacts the SCM on the far end to fail (Win32_Service, sc.exe, services.msc etc).
How do I set up permissions so that they can at least list the services and see if they are running?
I have a program that reads the contacts from my phone, but I can't export them from it.
I'd like to use another program to read the contents of the controls on the original program. In this case, I would like to export the content of a dropdown list (combobox), containing these contacts. Can someone recommend a good program for this or recommend another method?
I know I saw something for this last year on lifehacker.com in a collection of diagnostic tools, but I can't find it now.
Hey everyone. I am having some issues on my end and hopefully it's just something on my end but, could someone take a look at THIS PAGE in IE and let me know if you can see what is wrong. Please check it out first in FF or Chrome or Safari because it all works fine in those browsers.
The two scripts I am using are a custom-ish dropdown menu and another using jcarousel lite. I can't seem to figure out what the problem is.
Thanks for any help!!!
I am going to be administering a small network of linux based workstations for a charity institution (not all have the same distro- some are ubuntu and some are fedora). Is there something in Linux that is similar to group policy in windows?. For example I would like to standardize the wallpapers - have only firefox as a browser - default VLC as the media player etc etc.
Thank you, any suggestions are very appreciated.
When creating a new Rails project using:
rails sample
Then creating a model using:
script/generate model person first_name:string last_name:string
Everything is fine. However, if I add any gems to my environment.rb:
config.gem "authlogic"
And run the same generator, I get the following:
/Library/Ruby/Gems/1.8/gems/rails-2.3.5/lib/rails/gem_dependency.rb:119:Warning:
Gem::Dependency#version_requirements
is deprecated and will be removed on
or after August 2010.
The warning just recently appeared (I think), but I would like to fix it if possible. Any hints or similar experiences?
Thanks.
Assuming daily certain up to date database is produced via loading from various sources.
Changes need to be applied to historical database based on uid, new records will added , non existing will be softly deleted , some will be updated. Is Ado.Net and Sql statements the most appropriate technology for the task like this ?
Hello...,
I have little bit confusion regarding apache tomcat installation.
So, I would like to know that whats the difference between the .zip and the .exe tomcat ?
Thanks in advance...
select count(a),b,c
from APPLE
join MANGO on (APPLE.link=MANGO.link)
join ORANGE on (APPLE.link=ORANGE.link)
where id='camel'
group by b,c;
the column b gives values like
1.0
1.0,R
1.0,B
2.0
2.0,B
2.0,R
3.0,C
3.0,R
is there a way to modify the above quer so that all 1.0 and 1.0,R and 1.0,B are merged as 1.0
and 2.0,2.0,B are merged as 2.0 and same way for 3.0 and 4.0
We have developers some developers who are developing against a SQL Server 2005 database, while others are using 2008.
We just discovered that generating the edmx against a 2008 database set the ProviderManifestToken to 2008, which means some queries won't work against a 2005 database.
While this is a known issue, is there any way to set this value at run time, based on a config file?
I am used to using Ctrll to access my address bar. Unfortunately YouTube "helpfully" defines Ctrll as a hotkey to jump forward several seconds in the currently playing video, so I need a way to stop YouTube from adding that key binding. A Greasemonkey/Scriptish userscript that disables the binding after page load would be acceptable.
To be clear, this is while I am on a YouTube video's page, not on a third-party site that has embedded a YouTube video, and the behavior occurs when the Flash player does not have focus.
Note: I am aware that Altd does the same as Ctrll in Firefox, but I'm too used to Ctrll and I'd rather not be forced to switch.
Edit: OS-specific solutions are less desirable since I use multiple OSes; in-browser solutions are preferred.
I have the following struct declaration and typedef in my code:
struct blockHeaderStruct {
bool allocated;
unsigned int length;
};
typedef struct blockHeaderStruct blockHeader;
When I do sizeof(blockheader), I get the value of 4 bytes back, but when I do sizeof(blockHeaderStruct), I get 8 bytes.
Why is this happening? Why am I not getting 5 back instead?
I've inherited an enormous .NET solution of about 200 projects. There are now some developers who wish to start adding their own components into our application, which will require that we begin exposing functionality via an API.
The major problem with that, of course, is that the solution we've got on our hands contains such a spider web of dependencies that we have to be careful to avoid sabotaging the API every time there's a minor change somewhere in the app. We'd also like to be able to incrementally expose new functionality without destroying any previous third party apps.
I have a way to solve this problem, but i'm not sure it's the ideal way - i was looking for other ideas.
My plan would be to essentially have three dlls.
APIServer_1_0.dll - this would be the dll with all of the dependencies.
APIClient_1_0.dll - this would be the dll our developers would actual refer to. No references to any of the mess in our solution.
APISupport_1_0.dll - this would contain the interfaces which would allow the client piece to dynamically load the "server" component and perform whatever functions are required. Both of the above dlls would depend upon this. It would be the only dll that the "client" piece refers to.
I initially arrived at this design, because the way in which we do inter process communication between windows services is sort of similar (except that the client talks to the server via named pipes, rather than dynamically loading dlls).
While i'm fairly certain i can make this work, i'm curious to know if there are better ways to accomplish the same task.
This may sound like it's not a programming related question, but stick with me here...
My team and I have found that documenting our project (a development platform w/ API) with a wiki is both useful to us and useful to the users. Due to some organizational issues, we're forced to do multi-site development without network connectivity. We've switched to a DVCS (Mercurial) and had great success with this. The wiki documentation proves to be a problem as the central site is setup with MediaWiki. The offsite people have no way to access or edit the wiki.
Is there any sort of wiki-style package which doesn't not require a server/database and will be useable in a DVCS environment?
Update: Should be open-source and cross-platform
Hello,
I want to create an custom control (descendant of TRichEdit).
I simply want add some text above the editfield.
I've created my own control and I override the constructor to create a TLabel for the caption.
It works, but my problem: How is it possible to move the label above the richedit?
When I set Top := -5 the label begins to disappaer.
Here's the code of the constructor:
constructor TDBRichEditExt.Create(AOwner: TComponent);
begin
inherited;
lblCaption := TLabel.Create(self);
lblCaption.Parent := parent;
lblCaption.Caption := 'Header';
lblCaption.Top := -5;
end;
I think it's logic that the label disappaers since the richedit is the parent.
I've tried
lblCaption.Parent := self.parent;
To make the form which owns the richedit the parent - but this dosn't work...
How could I achieve this?
Thank you all!
Hi fellow coders
I'm new at LINQ, searching the net for LINQ samples that mimic SQL's LIKE statement doesn't satisfy myself.
What I want is producing the same query result as this SQL
SELECT * FROM table_1 WHERE column_1 LIKE '__0%'
I want to query from table_1 where column_1's third character is '0'
Is there equivalent statement in LINQ
:D thank you
For example I made check box in A1 with "=$B$1"
So now, when I click it the "TRUE", "FALSE" text appears
depending if check box is checked or not.
The problem starts when I want to duplicate those two to
more rows. Now every check box makes the B1 text to change, not
the one it represents as in check box A1 should change B1 text,
check box in cell A2 should change B2 text and so on, but now
all check boxes change the same B1 text.
Is there any workaround?