Questions tagged [extending]

302 questions
0
votes
1 answer

Extend methods in Javascript

I have two different objects to create a clock. A analogue and digital one. THey're practically the same except for minor changes. Alot of methods in the object are used by both however; I want them to be instanced though. So i need them in the…
CaptainCarl
  • 3,411
  • 6
  • 38
  • 71
0
votes
1 answer

Can i reference in Criterion some Extended Attribute from another Powerdesigner XEM?

Let's say i have two Extensions attached to some Powerdesigner model: xem_a xem_b. In xem_a is Extended Attribute ea_a and in xem_b is Extended Attribute ea_b. In xem_a i can create Criterion with condition: %ea_a%==true , but i want to create…
morto
  • 57
  • 1
  • 6
0
votes
1 answer

System.Windows.Shapes.Path incorrect behavior

After doing some research on subject I didn't find anything, so I'm sorry if the same question was already asked. Task: make a colored track-line on Canvas after cursor, when the left mouse button is pressed (like brush in Paint). Problem: I think…
Hellfim
  • 28
  • 4
0
votes
2 answers

Class doesn't inherit - class not found

I have some troubles with inheritance. I have something like that file A.php namespace Main; class A{ public function __construct(){ echo 'A->__construct'; } } and file B.php namespace Main; class B extends \Main\A{ /* if I write this…
0
votes
1 answer

How to extend a formula in VBA past 1 line of code

So I do not have too much experience with programming and almost non with VBA. My main issue is that the formula in my code extends past 1 line and when I include an underscore, space and then start a new line, I receive an error. I have attached a…
user2639527
  • 1
  • 1
  • 1
0
votes
1 answer

backbone-extend.js doesn't seem to load my method

I added this to my backbone-extend.js file which resides in the same folder as backbone-min.js... _.extend(Backbone.View.prototype, { getFormData: function(form) { var unindexed_array = form.serializeArray(); var indexed_array =…
Locohost
  • 1,682
  • 5
  • 25
  • 38
0
votes
1 answer

How to list products in Magento Menu

Like this question: Magento: HOW-TO add active products in a drop-down in Main Navigation Menu ...I want to list the products from a category in the main menu. I have attempted to use the code provided but it's still not working. I'm using Magento…
GarethWyn
  • 51
  • 1
  • 6
0
votes
1 answer

Extending user with user profile in django(1.3)

I am following the link https://stackoverflow.com/a/965883/1657010 for extending the django user to a user profile. #in models.py from django.contrib.auth.models import User from django.db.models.signals import post_save class…
Neo_32
  • 225
  • 4
  • 13
0
votes
1 answer

oop, php, extend class, run function when specific method in class was called

first of all, I'm pretty much a noobie regarding oop etc, so please be kind. I did read a lot of manuals but somehow got lost in all the stuff and couldn't find the answers :( so any hints, links etc would be very much appreciated anyway I find…
olly
  • 61
  • 8
0
votes
1 answer

Android SQLite: How do I transfer variables to a different activity?

MAIN.JAVA public void onClick(View arg0) { switch (arg0.getId()) { case R.id.buttonupdate: String name = sqlName.getText().toString(); String value = sqlValue.getText().toString(); MainActivity entry = new…
Malaka
  • 1,581
  • 5
  • 16
  • 16
0
votes
2 answers

JavaScript language extensions with function calls lacking parenthesis - are they possible?

Is it possible, by any means, to do something like this: function A() { var Loaded = 'loaded'; raise Loaded; } function A_raise(evt) { console.log(evt); } A.prototype.constructor = A; A.prototype.raise = A_raise; The critical part being…
CoryG
  • 2,429
  • 3
  • 25
  • 60
0
votes
1 answer

Using a controller plugin to extend the existing layout in zend framework

I have a layout file as follows: doctype(); ?> headTitle(); ?> headLink(); ?> layout()->content; ?> …
kaushik
  • 2,308
  • 6
  • 35
  • 50
0
votes
1 answer

php manual exception example

So I was reading the php manual on Extending Exceptions and read the example code. My question about the following code is: why does var_dump($o) evaluate to null? Is it because the constructor of the class TestException throws an exception, hence…
Robert
  • 10,126
  • 19
  • 78
  • 130
0
votes
1 answer

Trouble on extending Rails in a sub-directory of the 'lib' directory

I am using Ruby on Rails 3.2.9 and I would like to extend the framework with a custom validator located in a sub-directory of the lib/ directory. I implemented the following: # lib/extension/rails/custom_validator.rb module Extension module Rails …
Backo
  • 18,291
  • 27
  • 103
  • 170
0
votes
1 answer

Extend ActiveRecord method_missing

I've been looking around the web and have found a great deal of information on attempting what I am, however one bit of sugar I'd like to add to my Ruby/Rails mixin, is creating a function that looks for a pattern. I want to create a base function…
Volte
  • 1,905
  • 18
  • 25