Questions tagged [dynamic]

Dynamic is a widely used term that, in general, describes a decision made by the program at run-time rather than at compile time.

Programs that perform some common tasks based on program inputs in contrast with programs that predetermine the task beforehand. Dynamic is often used to mean:

  • The dynamic keyword
  • using JavaScript to manipulate web pages in the browser.
  • have features that allow the of a variable to be bound at run-time.
  • Program generated content, especially content in contrast with web pages created by a person and stored on disk, ready to serve.
27209 questions
68
votes
4 answers

Dynamic in the immediate window causes 'Microsoft.CSharp.RuntimeBinder.Binder' is not defined or imported error

If I use dynamic in the immediate window of Visual Studio I get an error Predefined type 'Microsoft.CSharp.RuntimeBinder.Binder' is not defined or imported How can I fix that?
Colonel Panic
  • 132,665
  • 89
  • 401
  • 465
67
votes
2 answers

Specifying multiple files with LD_PRELOAD

I know how to override one library with LD_PRELOAD, for example, as follows. LD_PRELOAD=./getpid.so ./testpid Now my question is how to override multiple files. Say I want to override both getpid and getid, how would I specify that?
MetallicPriest
  • 29,191
  • 52
  • 200
  • 356
65
votes
9 answers

How do I work with dynamic multi-dimensional arrays in C?

Does someone know how I can use dynamically allocated multi-dimensional arrays using C? Is that possible?
rpf
  • 3,612
  • 10
  • 38
  • 47
65
votes
14 answers

How do I size a UITextView to its content on iOS 7?

I've been using the accepted answer here for years. On iOS 7, the contentSize.height becomes the frame.height-8, regardless of text content. What's a working method to adjust the height on iOS 7?
Henrik Erlandsson
  • 3,797
  • 5
  • 43
  • 63
64
votes
7 answers

XCode 6.3 Warning: synthesize property

In new Xcode 6.3 I get this warning: Auto property synthesis will not synthesize property 'homeInt'; it will be implemented by its superclass, use @dynamic to acknowledge intention How I can remove it?
UnRewa
  • 2,462
  • 2
  • 29
  • 31
64
votes
8 answers

Change UITableView height dynamically

I want to change the height of my tableview from another viewcontroller based on the sum of its cells' heights, as they are dynamic. Is it at all possible? Thanks Add-on: What I basically have is a UserProfileViewController that has a containerview…
alex
  • 957
  • 2
  • 9
  • 16
63
votes
6 answers

Dynamic loading of python modules

In python how do you dynamically add modules to a package while your program is running. I want to be able to add modules to the package directory from an outside process, and be able to use those new modules in my program: import package def…
No Name
63
votes
10 answers

How can I create a dynamically sized array of structs?

I know how to create an array of structs but with a predefined size. However is there a way to create a dynamic array of structs such that the array could get bigger? For example: typedef struct { char *str; } words; main() …
D. Rattansingh
  • 1,569
  • 3
  • 19
  • 30
63
votes
6 answers

How can I dynamically create menu items?

I'm building an Android application and I'm trying to build a user management system where users can login, logout, etc. I want to display a login menu item if the user is logged out and a logout button if the user is logged in. How can I do this…
Johnathan Au
  • 5,244
  • 18
  • 70
  • 128
62
votes
4 answers

Why is casting a dynamic of type object to object throwing a null reference exception?

I have the following function: public static T TryGetArrayValue(object[] array_, int index_) { ... //some checking goes up here not relevant to question dynamic boxed = array_[index_]; return (T)boxed; } When I call it in the…
bedo
  • 866
  • 8
  • 15
62
votes
6 answers

Difference between static and dynamic programming languages

What is the difference between static and dynamic programming languages? I know that it is all about type systems, but I’m looking for more clear clarifications.
Balaji Reddy
  • 5,576
  • 3
  • 36
  • 47
62
votes
4 answers

How to use a tablename variable for a java prepared statement insert

I am using a java PreparedStatment object to construct a series of batched INSERT queries. The query statement is of the format... String strQuery = "INSERT INTO ? (col1, col2, col3, col4, col5) VALUES (?,?,?,?,?,?);"; ...so both field values and…
ForestSDMC
  • 775
  • 2
  • 7
  • 12
62
votes
14 answers

Is it possible to create a function dynamically, during runtime in C++?

C++ is a static, compiled language, templates are resolved during compile time and so on... But is it possible to create a function during runtime, that is not described in the source code and has not been converted to machine language during…
dtech
  • 47,916
  • 17
  • 112
  • 190
61
votes
5 answers

Why is Clojure dynamically typed?

One thing I like very much is reading about different programming languages. Currently, I'm learning Scala but that doesn't mean I'm not interested in Groovy, Clojure, Python, and many others. All these languages have a unique look and feel and some…
lhk
  • 27,458
  • 30
  • 122
  • 201
59
votes
1 answer

What does @dynamic do in Objective-C?

Objective-C has a feature called @dynamic. Google only lists results about dynamic typing. I rarely see this in code and I don't understand what it is used for. Can anyone explain me this? Thanks.
user142019