property

How do I set an MSI installation folder dynamically.

I'm creating a web application installer using WiX. I want to allow the user to select the web site from a list of sites on the IIS server, and then install the app in a sub-directory of that web site's root folder. I've finished the "select web site" portion. I have a custom action that sets a bunch of properties based on the selected ...

Command Text property has not been initialiazed

This one is a tricky one I have been looking through the event viewer on our server and can see quite a few people with this error but I can't replicate this myself but it is causing issues for people viewing our website is there anyway I can "initialize" Command Text property? Thanks Jamie UPDATE So I have this query datelistquery...

Where's the Encapsulation?

I'm a new programmer, so please forgive any dumbness of this question but can anyone please tell me how the folowing code is encapsulating private data- public class SomeClass { private int age; public int Age { get { return age; } set { age = value; } } public SomeClass(int age) { this....

What are the common "backing field" naming schemes in .net?

When doing a backing field for a property what are the common naming schemes? Edit: make question specific to .net ...

How to reset a property in ANT?

Hi, I'm writing a velocity macro within which I have some ant tasks. Within a #foreach loop in the velocity macro, I have a pathconvert task: #foreach(<iterate through something>) <pathconvert property='filename' refid='swf.file'> <mapper> <chainedmapper> <flattenmapper/> ...

Can You Specify the Property Name of a Foreign Object in LINQ

Suppose that I have 2 tables: [User] - UserID - Username [Task] - TaskID - TaskName - TaskCreatedByUserID - TaskAssignedToUserID In the [Task] table, both of the ***UserID fields are foreign keys to the [User] table. So when I use the designer to create my LINQ models, I have access to 2 foreign [User] objects with proper...

How to add optgroups to a django ModelMultipleChoiceField ?

Hello Guys, I have a form with a ModelMultipleChoiceField to list of categories. I would like to group categories using the Category.group field. I thought that by changing the field.choices in the init function it will make the trick class CategoriesField(forms.ModelMultipleChoiceField): def __init__(self, queryset, **kwargs): ...

Data encapsulation in C# using properties

Hi guys, currently I am thinking about data encapsulation in C# and I am a little bit confused. Years ago, when I started to learn programing with C++, my professor told me: - "Create a class and hide it data members, so it can't be manipulated directly from outside" Example: You are parsing an XML file and store the parsed data into ...

PHP: Protect an object property without knowing its name in advance

Ok, this may be impossible, but I thought I'd ask before I rework the whole thing... I have a situation like this: I have an object class that can receive "pieces," which are also objects. It works basically like this: class myObject { //Receives an associative array of "Piece" objects function __construct($objects) { f...

Java 6 - Annotation processor and code addition

I wrote a custom annotation containing metadata for a property and an AnnotationProcessor: @SupportedAnnotationTypes({"<package>.Property"}) public class PropertyProcessor extends AbstractProcessor { @Override public boolean process(Set<? extends TypeElement> annotations, RoundEnvironment roundEnv) { // Get messager object Mes...

Why isn't this classprop implementation working?

Based on a question I previously asked, I tried to come up with a class property that would allow setting as well as getting. So I wrote this and put it in a module util: class classprop(object): def __init__(self, fget, fset=None): if isinstance(fget, classmethod): self.fget = fget else: sel...

JavaScript object with internally referenced properties

I'm trying to create a global object with a series of 'slave' properties that are derived from the value of one 'master' property in the same object - something like: var x = 5; var myObj = { master : 17, slave1 : this.master + x, slave2 : (this.master / 2.2) + 1, slave3 : Math.floor(this.slave2) //etc. }; I realiz...

Boolean as a property in Cocoa

I'm sure that this has been asked MANY times before, but it's still giving me trouble. I define my class's Boolean property like this: @property(readwrite,assign) BOOL namesVisible; And it doesn't give compiler errors, but it NSLogs as (null). Obviously I'm doing something wrong here, but I'm at a loss to what it is. ...

What is the Use of Property {get, set} method in C # 3.0

Possible Duplicate: C# Automatic Properties Hello, I have recently moved towards .net (c#) platform from Java. Here I don't face much problem yet... anyway I 'm messed up with property{get, set} method. Actually I could not get up the exact meaning of these (property) according to me the same job of initial...

When to use self and when to use retain

Hi, am working my way through the "Beginning iPad Development" Apress book and have noticed that sometimes when the author is assigning values to a property they will use: self.variable = value; and other times, they will use: variable = [value retain]; In both cases variable is a property defined as: @property (nonatomic, retain)...

Adding a property to an interface that's a List

This compiles: public interface IBookCatalogueView { Book[] Books { get; set; } } This doesn't, giving the error "Interfaces cannot contain fields" public interface IBookCatalogueView { List<Book> Books { get; set; } } > Why? How can I define a property that's a list in...

web element inspector (safari / chrome) dimmed css properties

Silly web element inspector (safari / chrome) question, but I can't seem to figure out why some properties are dimmed. ...

Setting Properties Rundown in Objective C

One of the things I've been struggling with whilst breaking into Objective C programming is understanding how to manipulate properties. I'm perhaps out of my comfort zone using a proper coding language as opposed to scripting languages that I'm used to, so the declaring things in header files and implementation files is confusing me some...

SharePoint 2007 property bag content deplyment

Does anyone know if the property bag settings for a sharepoint 2007 site is included in content deployment? my google foo has failed me today for a solidified answer. ...

PHP: declare a class variable to be a stdClass object

This is probably pretty simple but I haven't been able to figure out how to phrase the question for Google, so here goes: So, I often do something like this... class foo { private $bar = array(); } ... to set some class property to be an array. However, I'd like to make a private property an object instead, something like this: ...