PostId
int64
13
11.8M
PostCreationDate
stringlengths
19
19
OwnerUserId
int64
3
1.57M
OwnerCreationDate
stringlengths
10
19
ReputationAtPostCreation
int64
-33
210k
OwnerUndeletedAnswerCountAtPostTime
int64
0
5.77k
Title
stringlengths
10
250
BodyMarkdown
stringlengths
12
30k
Tag1
stringlengths
1
25
Tag2
stringlengths
1
25
Tag3
stringlengths
1
25
Tag4
stringlengths
1
25
Tag5
stringlengths
1
25
PostClosedDate
stringlengths
19
19
OpenStatus
stringclasses
5 values
unified_texts
stringlengths
47
30.1k
OpenStatus_id
int64
0
4
6,779,004
07/21/2011 15:54:41
787,756
06/07/2011 15:25:27
1
0
How to initialize pointers properly
I have the following code that calls the function uint32_pack. This program compiles with no errors in Dev-C++ but does not produce the correct result when 'tag' is an even number. In Visual Studio the program compiles but produces errors and I'm guessing that these errors are why I don't get the correct output when 'tag' is even. I'm still trying to get my head around pointers and I'm not sure where I went wrong when declaring them. Thanks for your help. Here is the code where the errors come from: 1 int uint32_pack (uint8_t *fieldnumber, uint32_t value, uint8_t *out); 2 int main(){ 3 uint32_t initvalue = 2; 4 int return_rv; 5 uint8_t *tag = (uint8_t *) malloc(sizeof(uint8_t)); 6 *tag = 38; 7 uint8_t *tempout= (uint8_t *) malloc(30); 8 return_rv = uint32_pack (tag, initvalue, tempout); 9 free(tempout); 10 free(tag); } And the errors from VS as are follows: error C2143: syntax error : missing ';' before 'type' (on line 7) error C2065: 'tempout' : undeclared identifier (on line 8) warning C4047: 'function' : 'unsigned char *' differs in levels of indirection from 'int' (on line 8) warning C4024: 'uint32_pack' : different types for formal and actual parameter 3 (on line 8) error C2065: 'tempout' : undeclared identifier (on line 9) warning C4022: 'free' : pointer mismatch for actual parameter 1 (on line 9)
c
visual-studio-2010
function
pointers
null
null
open
How to initialize pointers properly === I have the following code that calls the function uint32_pack. This program compiles with no errors in Dev-C++ but does not produce the correct result when 'tag' is an even number. In Visual Studio the program compiles but produces errors and I'm guessing that these errors are why I don't get the correct output when 'tag' is even. I'm still trying to get my head around pointers and I'm not sure where I went wrong when declaring them. Thanks for your help. Here is the code where the errors come from: 1 int uint32_pack (uint8_t *fieldnumber, uint32_t value, uint8_t *out); 2 int main(){ 3 uint32_t initvalue = 2; 4 int return_rv; 5 uint8_t *tag = (uint8_t *) malloc(sizeof(uint8_t)); 6 *tag = 38; 7 uint8_t *tempout= (uint8_t *) malloc(30); 8 return_rv = uint32_pack (tag, initvalue, tempout); 9 free(tempout); 10 free(tag); } And the errors from VS as are follows: error C2143: syntax error : missing ';' before 'type' (on line 7) error C2065: 'tempout' : undeclared identifier (on line 8) warning C4047: 'function' : 'unsigned char *' differs in levels of indirection from 'int' (on line 8) warning C4024: 'uint32_pack' : different types for formal and actual parameter 3 (on line 8) error C2065: 'tempout' : undeclared identifier (on line 9) warning C4022: 'free' : pointer mismatch for actual parameter 1 (on line 9)
0
4,036,251
10/27/2010 18:06:14
416,926
08/11/2010 06:46:13
159
58
How to connect to modems within tcp clients in multiple port or other way?
I have around 5000 modem (thin clients), and I want to communicate with them, one of a my method is like this : `string GetModemData(modemID)`, now I have an open port in server that listens to modem and I'm using socket programming to send data to modems (calling related function), but when i want send data to multiple modem in a same time and get response from them, I don't know what should i do? I can send data to one modem and waiting for its response and then send another data to other modems (sequential), but the problem is client should be wait long time to get answer(may be some different client want to get some information from modems so they all will be wait into the Q or something like this), I think one way to solving this problem is to use multiple port and listen for each modem to related port, but it takes too many ports and also may be memory usage going up and exceed my available memory space, so some lost may be occurred (is this true?). what should to do ? I'd thinking about Parallelism, but i think its not related i should to wait for one port, because i don't know should to pass current received data to which client. I'm using asp.net.
c#
asp.net
sockets
parallel-processing
null
null
open
How to connect to modems within tcp clients in multiple port or other way? === I have around 5000 modem (thin clients), and I want to communicate with them, one of a my method is like this : `string GetModemData(modemID)`, now I have an open port in server that listens to modem and I'm using socket programming to send data to modems (calling related function), but when i want send data to multiple modem in a same time and get response from them, I don't know what should i do? I can send data to one modem and waiting for its response and then send another data to other modems (sequential), but the problem is client should be wait long time to get answer(may be some different client want to get some information from modems so they all will be wait into the Q or something like this), I think one way to solving this problem is to use multiple port and listen for each modem to related port, but it takes too many ports and also may be memory usage going up and exceed my available memory space, so some lost may be occurred (is this true?). what should to do ? I'd thinking about Parallelism, but i think its not related i should to wait for one port, because i don't know should to pass current received data to which client. I'm using asp.net.
0
11,288,633
07/02/2012 06:23:28
1,442,115
06/07/2012 11:49:40
1
0
Can you launch jQuery from SVG?
I would like to post on http://anysite.com (any forum/blog/site/...) a *SVG* IMAGE TAG remotely like this: < img src="http://myownsite.com/myimage.svg" > (my own site) in order to launch jQuery/javascript/ajax from it. In detail, I would like the .svg file to open a bigger div including interactive features. Is this possible? If yes, how?
javascript
jquery
svg
null
null
07/02/2012 14:20:37
not a real question
Can you launch jQuery from SVG? === I would like to post on http://anysite.com (any forum/blog/site/...) a *SVG* IMAGE TAG remotely like this: < img src="http://myownsite.com/myimage.svg" > (my own site) in order to launch jQuery/javascript/ajax from it. In detail, I would like the .svg file to open a bigger div including interactive features. Is this possible? If yes, how?
1
10,786,022
05/28/2012 14:09:28
1,372,393
05/03/2012 11:54:26
1
0
Writing data into a bmp file
I'm currently interfacing an oscilloscope (agilent DSO7104B) in objective-c, and my goal is to get the image displayed on the screen of the oscilloscope. The scope sends me the bmp data and then i put it into an empty file and I try to open it, but the image is displayed weirdly, with a kind of offset. Here is my code : NSString *str = @":DISP:DATA? BMP, SCR, GRAY\r\n"; NSData *strData = [str dataUsingEncoding:NSUTF8StringEncoding]; [outputStream write:(uint8_t *)[strData bytes] maxLength:[strData length]]; [NSThread sleepForTimeInterval:1]; uint8_t buf[1024]; [((NSInputStream *) inputStream) read: buf maxLength: 1024]; uint8_t *buff; buff=malloc(2546752); memset (buff, 0, 2546752); //buff=malloc(2551000); //memset (buff, 0, 2551000); int len; [self makeNewFile]; int count=0; for(int i=0; i<8; i++){ len = [((NSInputStream *) inputStream) read: &(buff[count]) maxLength: 318344]; count=count+318344; [NSThread sleepForTimeInterval:3]; } //[self printImage: buff: 2546742]; [self printImage: buff: 2546752]; And here is the printImage function : - (void) printImage: (uint8_t*) buff : (int) len{ NSFileManager *manager; manager = [NSFileManager defaultManager]; NSData *buffer; NSFileHandle *fin, *fout; fin = [NSFileHandle fileHandleForReadingAtPath:instancePath]; fout = [NSFileHandle fileHandleForWritingAtPath:instancePath]; if([manager fileExistsAtPath:instancePath]==NO){ NSLog(@"Unreachable path"); } if([manager fileExistsAtPath:instancePath]==YES){ NSLog(@"File ready"); } //buffer = [NSData dataWithBytes:&(buff[10]) length:2546742-10]; buffer = [NSData dataWithBytes:&(buff[10]) length:2546752-10]; //buffer = [NSData dataWithBytes:buff length:2546742]; [fout writeData:buffer]; [fin closeFile]; [fout closeFile]; All the commented code is some testcode that i don't use anymore. The scope sends me 2546752 bytes of data, including a 10 bytes header that must not be in the bmp file. I have to get it by 8 samples (the for loop) because the telnet buffer is too small otherwise. The first reading (buf 1024 bytes) is here to clear the inputstream of any data that the scope may send before the image. I'm sure that i get the good beginning data because, if i open the file in a hexadecimal editor i can see the bitmap header ("BM..."), but i think i don't get the "core" of the file as i should...
objective-c
bitmap
bmp
null
null
null
open
Writing data into a bmp file === I'm currently interfacing an oscilloscope (agilent DSO7104B) in objective-c, and my goal is to get the image displayed on the screen of the oscilloscope. The scope sends me the bmp data and then i put it into an empty file and I try to open it, but the image is displayed weirdly, with a kind of offset. Here is my code : NSString *str = @":DISP:DATA? BMP, SCR, GRAY\r\n"; NSData *strData = [str dataUsingEncoding:NSUTF8StringEncoding]; [outputStream write:(uint8_t *)[strData bytes] maxLength:[strData length]]; [NSThread sleepForTimeInterval:1]; uint8_t buf[1024]; [((NSInputStream *) inputStream) read: buf maxLength: 1024]; uint8_t *buff; buff=malloc(2546752); memset (buff, 0, 2546752); //buff=malloc(2551000); //memset (buff, 0, 2551000); int len; [self makeNewFile]; int count=0; for(int i=0; i<8; i++){ len = [((NSInputStream *) inputStream) read: &(buff[count]) maxLength: 318344]; count=count+318344; [NSThread sleepForTimeInterval:3]; } //[self printImage: buff: 2546742]; [self printImage: buff: 2546752]; And here is the printImage function : - (void) printImage: (uint8_t*) buff : (int) len{ NSFileManager *manager; manager = [NSFileManager defaultManager]; NSData *buffer; NSFileHandle *fin, *fout; fin = [NSFileHandle fileHandleForReadingAtPath:instancePath]; fout = [NSFileHandle fileHandleForWritingAtPath:instancePath]; if([manager fileExistsAtPath:instancePath]==NO){ NSLog(@"Unreachable path"); } if([manager fileExistsAtPath:instancePath]==YES){ NSLog(@"File ready"); } //buffer = [NSData dataWithBytes:&(buff[10]) length:2546742-10]; buffer = [NSData dataWithBytes:&(buff[10]) length:2546752-10]; //buffer = [NSData dataWithBytes:buff length:2546742]; [fout writeData:buffer]; [fin closeFile]; [fout closeFile]; All the commented code is some testcode that i don't use anymore. The scope sends me 2546752 bytes of data, including a 10 bytes header that must not be in the bmp file. I have to get it by 8 samples (the for loop) because the telnet buffer is too small otherwise. The first reading (buf 1024 bytes) is here to clear the inputstream of any data that the scope may send before the image. I'm sure that i get the good beginning data because, if i open the file in a hexadecimal editor i can see the bitmap header ("BM..."), but i think i don't get the "core" of the file as i should...
0
1,282,763
08/15/2009 20:27:35
45,005
12/10/2008 14:51:54
875
19
Physical world examples of design for testability and test driven development
I'm going to be doing a presentation on unit testing and in doing so I will touch on "design for testability" patterns. In other words using IOC containers, Dependency Injection, avoiding static methods etc. I have a feeling my team will be cold to starting to code differently to accommodate for testing. So I was wondering if anybody knew of any real world examples of altering a design of something for no other reason then to make it easier to test. I'm assuming this concept isn't uncommon in manufacturing, engineering and other professions, I'm just not familiar with any hard examples. I imagine the development of the Saturn V rocket, Space Shuttle, Automobiles, Robotics, etc. must have some documented example of some design for testability or possibly the lack thereof causing problems. **Examples that have come to mind** - I suppose having replaceable parts is a form of dependency injection, where as welding all the components together wouldn't allow testing them individually. - Perhaps the OBD2 port on modern automobiles because it makes it easy to check if any systems have issues.
design-patterns
unit-testing
design
presentations
null
05/05/2012 13:54:40
not constructive
Physical world examples of design for testability and test driven development === I'm going to be doing a presentation on unit testing and in doing so I will touch on "design for testability" patterns. In other words using IOC containers, Dependency Injection, avoiding static methods etc. I have a feeling my team will be cold to starting to code differently to accommodate for testing. So I was wondering if anybody knew of any real world examples of altering a design of something for no other reason then to make it easier to test. I'm assuming this concept isn't uncommon in manufacturing, engineering and other professions, I'm just not familiar with any hard examples. I imagine the development of the Saturn V rocket, Space Shuttle, Automobiles, Robotics, etc. must have some documented example of some design for testability or possibly the lack thereof causing problems. **Examples that have come to mind** - I suppose having replaceable parts is a form of dependency injection, where as welding all the components together wouldn't allow testing them individually. - Perhaps the OBD2 port on modern automobiles because it makes it easy to check if any systems have issues.
4
11,529,374
07/17/2012 19:20:44
1,362,765
04/28/2012 10:51:44
4
0
problems displaying data from mysql
I'm trying to display data from the database. But there are many errors. I can not understand them, please help. I use PHP 5.2 This is the text of the error: ## ERRNO: 2 TEXT: filemtime() [function.filemtime]: stat failed for C:\megapolis/presentation/templates_c90c5e5fee090eaeeef24c7237c96d1343779fa70.file.departments_list.tpl.php LOCATION: C:\megapolis\libs\smarty\sysplugins\smarty_resource.php, line 723, at July 17, 2012, 9:04 pm Showing backtrace: filemtime("C:\megapolis/presentation/templates_c\90c5e5fee090eaeeef24c7237c...") # line 723, file: C:\megapolis\libs\smarty\sysplugins\smarty_resource.php Smarty_Template_Source.getCompiled(Object: Smarty_Internal_Template) # line 646, file: C:\megapolis\libs\smarty\sysplugins\smarty_internal_template.php Smarty_Internal_Template.__get("compiled") # line 154, file: C:\megapolis\libs\smarty\sysplugins\smarty_internal_templatebase.php Smarty_Internal_TemplateBase.fetch(null, null, null, null, false, false, true) # line 286, file: C:\megapolis\libs\smarty\sysplugins\smarty_internal_template.php Smarty_Internal_Template.getSubTemplate("departments_list.tpl", null, null, null, null, Array[0], "0") # line 49, file: C:\megapolis\presentation\templates_c\da6b8994be0effb79caf16160bdf44b8a45d0f90.file.store_front.tpl.php content_5005ab769f8aa0_97554484(Object: Smarty_Internal_Template) # line 180, file: C:\megapolis\libs\smarty\sysplugins\smarty_internal_templatebase.php Smarty_Internal_TemplateBase.fetch("store_front.tpl", null, null, null, true) # line 374, file: C:\megapolis\libs\smarty\sysplugins\smarty_internal_templatebase.php Smarty_Internal_TemplateBase.display("store_front.tpl") # line 22, file: C:\megapolis\index.php
php
mysql
null
null
null
07/17/2012 19:32:49
too localized
problems displaying data from mysql === I'm trying to display data from the database. But there are many errors. I can not understand them, please help. I use PHP 5.2 This is the text of the error: ## ERRNO: 2 TEXT: filemtime() [function.filemtime]: stat failed for C:\megapolis/presentation/templates_c90c5e5fee090eaeeef24c7237c96d1343779fa70.file.departments_list.tpl.php LOCATION: C:\megapolis\libs\smarty\sysplugins\smarty_resource.php, line 723, at July 17, 2012, 9:04 pm Showing backtrace: filemtime("C:\megapolis/presentation/templates_c\90c5e5fee090eaeeef24c7237c...") # line 723, file: C:\megapolis\libs\smarty\sysplugins\smarty_resource.php Smarty_Template_Source.getCompiled(Object: Smarty_Internal_Template) # line 646, file: C:\megapolis\libs\smarty\sysplugins\smarty_internal_template.php Smarty_Internal_Template.__get("compiled") # line 154, file: C:\megapolis\libs\smarty\sysplugins\smarty_internal_templatebase.php Smarty_Internal_TemplateBase.fetch(null, null, null, null, false, false, true) # line 286, file: C:\megapolis\libs\smarty\sysplugins\smarty_internal_template.php Smarty_Internal_Template.getSubTemplate("departments_list.tpl", null, null, null, null, Array[0], "0") # line 49, file: C:\megapolis\presentation\templates_c\da6b8994be0effb79caf16160bdf44b8a45d0f90.file.store_front.tpl.php content_5005ab769f8aa0_97554484(Object: Smarty_Internal_Template) # line 180, file: C:\megapolis\libs\smarty\sysplugins\smarty_internal_templatebase.php Smarty_Internal_TemplateBase.fetch("store_front.tpl", null, null, null, true) # line 374, file: C:\megapolis\libs\smarty\sysplugins\smarty_internal_templatebase.php Smarty_Internal_TemplateBase.display("store_front.tpl") # line 22, file: C:\megapolis\index.php
3
9,759,139
03/18/2012 14:31:45
962,667
09/24/2011 13:42:35
51
0
PHP Zend Framework Zend_Pdf - number of pages of pdf document
simple thing which I need to do is, that I have a pdf document and i need return number of pages of this document. I should to do this with a Zend Framework. Thanks in advance for answers
php
zend-framework
pdf
null
null
null
open
PHP Zend Framework Zend_Pdf - number of pages of pdf document === simple thing which I need to do is, that I have a pdf document and i need return number of pages of this document. I should to do this with a Zend Framework. Thanks in advance for answers
0
467,276
01/21/2009 22:20:57
17,847
09/18/2008 15:27:47
1,317
62
How do I map a one-to-one association with NHibernate using foreign key generator?
So far the association works fine (the `User` class loads the appropriate `UserRoles` instance when present), but when creating a new `User` and setting its `Roles` property to a new instance of `UserRoles`, the `UserRoles` object is not saved. Here is my abridged User.hbm.xml: <?xml version="1.0" encoding="utf-8" ?> <hibernate-mapping xmlns="urn:nhibernate-mapping-2.2"> <class name="DistrictObservations.User, DistrictObservations" table="users"> <cache usage="read-write" region="all" /> <id name="ID" column="id" type="int" unsaved-value="0"> <generator class="identity" /> </id> <!-- snip --> <one-to-one name="Roles" class="DistrictObservations.UserRoles, DistrictObservations" lazy="false" /> </class> </hibernate-mapping> And here is the UserRoles mapping: <?xml version="1.0" encoding="utf-8" ?> <hibernate-mapping xmlns="urn:nhibernate-mapping-2.2"> <class name="DistrictObservations.UserRoles, DistrictObservations" table="user_roles"> <cache usage="read-write" region="all" /> <id name="UserID" column="user_id" type="int" > <generator class="foreign"> <param name="property">User</param> </generator> </id> <!-- snip --> <one-to-one name="User" class="DistrictObservations.User, DistrictObservations" lazy="false" constrained="true" foreign-key="FK_user_roles_users" /> </class> </hibernate-mapping> Anyone got an idea how to have the UserRoles object saved with the User.ID as its primary key? I've been looking at the documentation, and to be honest, it is not particularly helpful.
nhibernate
object-relational-mapping
foreign-keys
.net
null
null
open
How do I map a one-to-one association with NHibernate using foreign key generator? === So far the association works fine (the `User` class loads the appropriate `UserRoles` instance when present), but when creating a new `User` and setting its `Roles` property to a new instance of `UserRoles`, the `UserRoles` object is not saved. Here is my abridged User.hbm.xml: <?xml version="1.0" encoding="utf-8" ?> <hibernate-mapping xmlns="urn:nhibernate-mapping-2.2"> <class name="DistrictObservations.User, DistrictObservations" table="users"> <cache usage="read-write" region="all" /> <id name="ID" column="id" type="int" unsaved-value="0"> <generator class="identity" /> </id> <!-- snip --> <one-to-one name="Roles" class="DistrictObservations.UserRoles, DistrictObservations" lazy="false" /> </class> </hibernate-mapping> And here is the UserRoles mapping: <?xml version="1.0" encoding="utf-8" ?> <hibernate-mapping xmlns="urn:nhibernate-mapping-2.2"> <class name="DistrictObservations.UserRoles, DistrictObservations" table="user_roles"> <cache usage="read-write" region="all" /> <id name="UserID" column="user_id" type="int" > <generator class="foreign"> <param name="property">User</param> </generator> </id> <!-- snip --> <one-to-one name="User" class="DistrictObservations.User, DistrictObservations" lazy="false" constrained="true" foreign-key="FK_user_roles_users" /> </class> </hibernate-mapping> Anyone got an idea how to have the UserRoles object saved with the User.ID as its primary key? I've been looking at the documentation, and to be honest, it is not particularly helpful.
0
10,140,523
04/13/2012 12:08:30
1,144,869
01/12/2012 06:50:01
36
0
Hadoop memory limit exceeded
I am running a Hadoop streaming job. This job fails with error: "TaskTree [pid=13549,tipID=attempt_201202130706_121058_m_000000_0] is running beyond memory-limits. Current usage : 1667149824bytes. Limit : 1610612736bytes. Killing task." For this job, mapred.job.map.memory.mb is set to 1536. Setting this to 1536*2 = 3072 helps, but causes 1 map task to use 2 slots which is not desirable. When I ran this job on host, I found that it uses peak memory of 1.07 GB which is way less than 1536 MB. I verified memory usage of job on host using "top" and a script which uses "ps -o vsz=${pid}" at every 1 second. Can somebody please help me to understand/debug/fix this problem.
hadoop
mapreduce
null
null
null
null
open
Hadoop memory limit exceeded === I am running a Hadoop streaming job. This job fails with error: "TaskTree [pid=13549,tipID=attempt_201202130706_121058_m_000000_0] is running beyond memory-limits. Current usage : 1667149824bytes. Limit : 1610612736bytes. Killing task." For this job, mapred.job.map.memory.mb is set to 1536. Setting this to 1536*2 = 3072 helps, but causes 1 map task to use 2 slots which is not desirable. When I ran this job on host, I found that it uses peak memory of 1.07 GB which is way less than 1536 MB. I verified memory usage of job on host using "top" and a script which uses "ps -o vsz=${pid}" at every 1 second. Can somebody please help me to understand/debug/fix this problem.
0
11,292,932
07/02/2012 11:41:01
497,084
11/04/2010 11:02:24
514
15
Cannot stop Verbose Trace Logs from shipping on Windows Azure
We use the Windows Azure Diagnostics Monitor Trace Listener to ship our trace logs to Azure Diagnostics. As we have a large number of verbose logs we have decided to stop shipping these to Azure Diagnostics to simply debugging. However when we set the `ScheduledTransferLogLevelFilter` property it seems to be ignored by Azure Diagnostics; so all `Verbose` logs are still shipped. The config section we use is: <system.diagnostics> <trace> <listeners> <add type="Microsoft.WindowsAzure.Diagnostics.DiagnosticMonitorTraceListener, Microsoft.WindowsAzure.Diagnostics, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" name="AzureDiagnostics"> <filter type="" /> </add> </listeners> </trace> </system.diagnostics> Whilst the code is: var config = DiagnosticMonitor.GetDefaultInitialConfiguration(); config.Logs.ScheduledTransferLogLevelFilter = LogLevel.Information; config.Logs.ScheduledTransferPeriod = TimeSpan.FromMinutes(1d); DiagnosticMonitor.Start(CONNECTION_STRING, config); Has anyone else come into this problem? Is there an additional section of set of configuration values that need to be set to stop Trace Logs shipping Verbose entries?
c#
logging
azure
windows-azure-diagnostics
null
null
open
Cannot stop Verbose Trace Logs from shipping on Windows Azure === We use the Windows Azure Diagnostics Monitor Trace Listener to ship our trace logs to Azure Diagnostics. As we have a large number of verbose logs we have decided to stop shipping these to Azure Diagnostics to simply debugging. However when we set the `ScheduledTransferLogLevelFilter` property it seems to be ignored by Azure Diagnostics; so all `Verbose` logs are still shipped. The config section we use is: <system.diagnostics> <trace> <listeners> <add type="Microsoft.WindowsAzure.Diagnostics.DiagnosticMonitorTraceListener, Microsoft.WindowsAzure.Diagnostics, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" name="AzureDiagnostics"> <filter type="" /> </add> </listeners> </trace> </system.diagnostics> Whilst the code is: var config = DiagnosticMonitor.GetDefaultInitialConfiguration(); config.Logs.ScheduledTransferLogLevelFilter = LogLevel.Information; config.Logs.ScheduledTransferPeriod = TimeSpan.FromMinutes(1d); DiagnosticMonitor.Start(CONNECTION_STRING, config); Has anyone else come into this problem? Is there an additional section of set of configuration values that need to be set to stop Trace Logs shipping Verbose entries?
0
8,921,702
01/19/2012 05:59:32
614,130
02/12/2011 10:35:11
168
4
What are the advantage and disadvantage using Phongap build?
What are the advantage and disadvantage using Phongap build? Is it the only way to build your apps, if not then why should I be using it? I have a Sencha touch application which I developed for Android and would like to distribute it to the Android market using phonegap as my wrapper. I was looking at the phonegap build's pricing and just got lost on how to distribute my app. below is the link to phonegap build's pricing [http://phonegap.com/2011/10/13/phonegap-build-pricing-plans-update/][1] [1]: http://phonegap.com/2011/10/13/phonegap-build-pricing-plans-update/
android
ios
phonegap
null
null
01/19/2012 08:06:51
not constructive
What are the advantage and disadvantage using Phongap build? === What are the advantage and disadvantage using Phongap build? Is it the only way to build your apps, if not then why should I be using it? I have a Sencha touch application which I developed for Android and would like to distribute it to the Android market using phonegap as my wrapper. I was looking at the phonegap build's pricing and just got lost on how to distribute my app. below is the link to phonegap build's pricing [http://phonegap.com/2011/10/13/phonegap-build-pricing-plans-update/][1] [1]: http://phonegap.com/2011/10/13/phonegap-build-pricing-plans-update/
4
2,851,831
05/17/2010 18:49:49
71,877
02/27/2009 14:02:52
1,217
56
SHBrowseForFolder and shortcuts
In my C++ Windows application, I have a function that is supposed to allow the end-user select a folder. I'm using SHBrowseForFolder and it is working fine except that folder shortcuts are not being displayed in the dialog. Does anyone know if it is possible to configure SHBrowseForFolder so that the end-users will be able to navigate folder shortcuts?
windows
winapi
visual-studio-2005
null
null
null
open
SHBrowseForFolder and shortcuts === In my C++ Windows application, I have a function that is supposed to allow the end-user select a folder. I'm using SHBrowseForFolder and it is working fine except that folder shortcuts are not being displayed in the dialog. Does anyone know if it is possible to configure SHBrowseForFolder so that the end-users will be able to navigate folder shortcuts?
0
4,975,484
02/12/2011 00:39:30
613,799
02/12/2011 00:08:51
1
0
need example sql transaction procedures for sales tracking or financial database
i am making a database for an accounting/sales type system similar to a car sales database and would like to make some transactions for the following real world actions salesman creates new product shipped onto floor (itempk, car make, year, price). salesman changes price. salesman creates sale entry for product sold (salespk, itemforeignkey, price sold, salesman). salesman cancels item for removed product. salesman cancels sale for cancelled sale the examples i have found online are too generic...like this is a transaction... i would like something resembling what i am trying to do to understand it. anybody have some good similar or related sql examples i can look at to design these? or if you have done this kind of sql transaction before could you make an outline for how these could be made? thanks
sql
stored-procedures
transactions
financial
sales
02/12/2011 14:57:34
not a real question
need example sql transaction procedures for sales tracking or financial database === i am making a database for an accounting/sales type system similar to a car sales database and would like to make some transactions for the following real world actions salesman creates new product shipped onto floor (itempk, car make, year, price). salesman changes price. salesman creates sale entry for product sold (salespk, itemforeignkey, price sold, salesman). salesman cancels item for removed product. salesman cancels sale for cancelled sale the examples i have found online are too generic...like this is a transaction... i would like something resembling what i am trying to do to understand it. anybody have some good similar or related sql examples i can look at to design these? or if you have done this kind of sql transaction before could you make an outline for how these could be made? thanks
1
5,968,595
05/11/2011 18:04:31
214,112
11/18/2009 21:38:33
509
27
Minimum bar width in Highcharts column charts
I'm using Highcharts to create some vertical bars (a.k.a. "column charts") a lot like here: http://www.highcharts.com/demo/column-basic Thing is, sometimes there are 30 bars in the chart, sometimes only two. Where then are two really wide bars in the chart, it looks really weird, so the decision was made to set a minimum width for the bars. That way if there are only two then they wouldn't get wider than, say, 50px, but if there were 50 then Highcharts could size them in the way it sees fit. So my problem is that Highcharts doesn't have a way to explicitly set the minimum width of the columns. Has anyone found a solution to that?
javascript
highcharts
null
null
null
null
open
Minimum bar width in Highcharts column charts === I'm using Highcharts to create some vertical bars (a.k.a. "column charts") a lot like here: http://www.highcharts.com/demo/column-basic Thing is, sometimes there are 30 bars in the chart, sometimes only two. Where then are two really wide bars in the chart, it looks really weird, so the decision was made to set a minimum width for the bars. That way if there are only two then they wouldn't get wider than, say, 50px, but if there were 50 then Highcharts could size them in the way it sees fit. So my problem is that Highcharts doesn't have a way to explicitly set the minimum width of the columns. Has anyone found a solution to that?
0
3,035,868
06/14/2010 08:32:17
136,141
07/10/2009 08:41:48
1,093
17
Can you reccomend a podcast on OOP & Design?
Can you recommend me a web site providing pod-casts focused on OOP & Design? Thanks
oop
podcast
null
null
null
09/18/2011 02:53:39
not constructive
Can you reccomend a podcast on OOP & Design? === Can you recommend me a web site providing pod-casts focused on OOP & Design? Thanks
4
8,527,128
12/15/2011 21:52:21
1,092,428
12/11/2011 16:33:51
6
0
Could you recommend me a way to do this?
I am building a photo organizer and I want my app to have this function I can select menu and choose an option, and I can put down a description on the photo, such as where it was taken, what the picture is about, and when the picture was taken, and make my application remember the description and let me view it in the future thanks
android
null
null
null
null
12/16/2011 15:34:30
not a real question
Could you recommend me a way to do this? === I am building a photo organizer and I want my app to have this function I can select menu and choose an option, and I can put down a description on the photo, such as where it was taken, what the picture is about, and when the picture was taken, and make my application remember the description and let me view it in the future thanks
1
3,896,789
10/09/2010 09:40:58
470,979
10/09/2010 09:40:58
1
0
error java.net.socketexception permission denied
i am working with andriod2.2 while calling web service getting error like java.net.SocketException permission denied error ...already added the internet permission in andriodmanifeast file since getting error ....plz help me soon...............
android
null
null
null
null
04/07/2012 14:30:32
too localized
error java.net.socketexception permission denied === i am working with andriod2.2 while calling web service getting error like java.net.SocketException permission denied error ...already added the internet permission in andriodmanifeast file since getting error ....plz help me soon...............
3
5,147,656
02/28/2011 21:14:53
9
07/31/2008 21:35:26
2,984
40
Animation a Silverlight UI element width from 0 to auto, smoothly
I have a Silverlight UI with a slide-out panel. When a button is clicked, I'd like the panel to animate out smoothly, with the width going from 0 to Auto. Is there a way to do this (ideally with pure XAML)?
silverlight
animation
null
null
null
null
open
Animation a Silverlight UI element width from 0 to auto, smoothly === I have a Silverlight UI with a slide-out panel. When a button is clicked, I'd like the panel to animate out smoothly, with the width going from 0 to Auto. Is there a way to do this (ideally with pure XAML)?
0
9,180,320
02/07/2012 16:50:39
313,093
04/09/2010 19:01:24
374
7
MySQL order by field
Hi im trying to order domain data using their status. As you might know, domain status DOM_EXP or DOM_DAKT applies before domain hits DOM_HELD therefore i dont care whitch one of this status has a domain before it became DOM_HELD How can i order this data? Using select provided below i only achieve that DOM_DAKT is behing DOM_EXP but i want it to be somewhere in between, ordered by exp_date SELECT domain_id, status, exp_date FROM domains ORDER BY field (status, 'DOM_DEL', 'DOM_HELD', 'DOM_EXP', 'DOM_DAKT'), exp_date ASC; +-----------+----------+---------------------+ | domain_id | status | exp_date | +-----------+----------+---------------------+ | 2 | DOM_DEL | 2012-02-02 10:47:33 | | 4 | DOM_HELD | 2012-02-02 10:47:38 | | 5 | DOM_HELD | 2012-02-02 10:47:40 | | 7 | DOM_HELD | 2012-02-02 10:47:44 | | 1 | DOM_EXP | 2012-02-02 10:47:27 | | 3 | DOM_EXP | 2012-02-02 10:47:35 | | 6 | DOM_EXP | 2012-02-02 10:47:42 | | 54 | DOM_DAKT | 2012-02-02 10:47:39 | +-----------+----------+---------------------+ the result have to be like this +-----------+----------+---------------------+ | domain_id | status | exp_date | +-----------+----------+---------------------+ | 2 | DOM_DEL | 2012-02-02 10:47:33 | | 4 | DOM_HELD | 2012-02-02 10:47:38 | | 5 | DOM_HELD | 2012-02-02 10:47:40 | | 7 | DOM_HELD | 2012-02-02 10:47:44 | | 1 | DOM_EXP | 2012-02-02 10:47:27 | | 3 | DOM_EXP | 2012-02-02 10:47:35 | | 54 | DOM_DAKT | 2012-02-02 10:47:39 | | 6 | DOM_EXP | 2012-02-02 10:47:42 | +-----------+----------+---------------------+
mysql
order-by
order
ordering
null
null
open
MySQL order by field === Hi im trying to order domain data using their status. As you might know, domain status DOM_EXP or DOM_DAKT applies before domain hits DOM_HELD therefore i dont care whitch one of this status has a domain before it became DOM_HELD How can i order this data? Using select provided below i only achieve that DOM_DAKT is behing DOM_EXP but i want it to be somewhere in between, ordered by exp_date SELECT domain_id, status, exp_date FROM domains ORDER BY field (status, 'DOM_DEL', 'DOM_HELD', 'DOM_EXP', 'DOM_DAKT'), exp_date ASC; +-----------+----------+---------------------+ | domain_id | status | exp_date | +-----------+----------+---------------------+ | 2 | DOM_DEL | 2012-02-02 10:47:33 | | 4 | DOM_HELD | 2012-02-02 10:47:38 | | 5 | DOM_HELD | 2012-02-02 10:47:40 | | 7 | DOM_HELD | 2012-02-02 10:47:44 | | 1 | DOM_EXP | 2012-02-02 10:47:27 | | 3 | DOM_EXP | 2012-02-02 10:47:35 | | 6 | DOM_EXP | 2012-02-02 10:47:42 | | 54 | DOM_DAKT | 2012-02-02 10:47:39 | +-----------+----------+---------------------+ the result have to be like this +-----------+----------+---------------------+ | domain_id | status | exp_date | +-----------+----------+---------------------+ | 2 | DOM_DEL | 2012-02-02 10:47:33 | | 4 | DOM_HELD | 2012-02-02 10:47:38 | | 5 | DOM_HELD | 2012-02-02 10:47:40 | | 7 | DOM_HELD | 2012-02-02 10:47:44 | | 1 | DOM_EXP | 2012-02-02 10:47:27 | | 3 | DOM_EXP | 2012-02-02 10:47:35 | | 54 | DOM_DAKT | 2012-02-02 10:47:39 | | 6 | DOM_EXP | 2012-02-02 10:47:42 | +-----------+----------+---------------------+
0
8,205,415
11/20/2011 22:50:14
179,736
09/27/2009 11:27:55
7,435
53
What JavaScript libraries should be used for creating Gmail-like webapps?
I want to build a social network that's like Google Plus. In other words, parts of the page load, and the user doesn't have to wait for the whole page to re-load. I'm familiar with JQuery. But I've been hearing about: - Backbone.js - Spine.js - Sproutcore I have no idea where to start. Can Backbone.js do it all? What about hashbangs (domain.com/#/user/blah) ...? Where do they come into play?
javascript
jquery
backbone.js
null
null
11/20/2011 22:57:14
not a real question
What JavaScript libraries should be used for creating Gmail-like webapps? === I want to build a social network that's like Google Plus. In other words, parts of the page load, and the user doesn't have to wait for the whole page to re-load. I'm familiar with JQuery. But I've been hearing about: - Backbone.js - Spine.js - Sproutcore I have no idea where to start. Can Backbone.js do it all? What about hashbangs (domain.com/#/user/blah) ...? Where do they come into play?
1
10,263,708
04/21/2012 22:46:38
122,769
06/14/2009 16:17:08
721
26
How to add <soap:Header> tag? WSDL not appearing with these info
I need to add to my message something like this: <soap:Header> <wsse:Security xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd" soap:mustUnderstand="1"> <wsse:UsernameToken xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" wsu:Id="unt_Z1k4LnxEmBzzKuPP"> <wsse:Username>user</wsse:Username> <wsse:Password Type="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordText">password</wsse:Password> <wsse:Nonce EncodingType="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-soap-message-security-1.0#Base64Binary">iNs+LF1iwwPU2AMer8uU6NKY9tfzgYqMTaP3mIEgoK0=</wsse:Nonce> <wsu:Created>2012-04-22T11:57:30Z</wsu:Created> </wsse:UsernameToken> <wsu:Timestamp xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <wsu:Created>2012-04-22T11:57:30Z</wsu:Created> <wsu:Expires>2012-04-22T11:58:30Z</wsu:Expires> </wsu:Timestamp> </wsse:Security> </soap:Header> I'm calling a web service which return a 500 error response which basically means it cannot authenticate I guess cause I'm missing these information from the message, even I have an authentication header on the message. Can this be happening? How can I add the WS-Security header in the message and add all these info in code? I added the service using Add Web Reference in Visual Studio. Thank you.
web-services
c#-4.0
ws-security
soapheader
web-reference
null
open
How to add <soap:Header> tag? WSDL not appearing with these info === I need to add to my message something like this: <soap:Header> <wsse:Security xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd" soap:mustUnderstand="1"> <wsse:UsernameToken xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" wsu:Id="unt_Z1k4LnxEmBzzKuPP"> <wsse:Username>user</wsse:Username> <wsse:Password Type="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordText">password</wsse:Password> <wsse:Nonce EncodingType="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-soap-message-security-1.0#Base64Binary">iNs+LF1iwwPU2AMer8uU6NKY9tfzgYqMTaP3mIEgoK0=</wsse:Nonce> <wsu:Created>2012-04-22T11:57:30Z</wsu:Created> </wsse:UsernameToken> <wsu:Timestamp xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <wsu:Created>2012-04-22T11:57:30Z</wsu:Created> <wsu:Expires>2012-04-22T11:58:30Z</wsu:Expires> </wsu:Timestamp> </wsse:Security> </soap:Header> I'm calling a web service which return a 500 error response which basically means it cannot authenticate I guess cause I'm missing these information from the message, even I have an authentication header on the message. Can this be happening? How can I add the WS-Security header in the message and add all these info in code? I added the service using Add Web Reference in Visual Studio. Thank you.
0
8,873,211
01/15/2012 20:42:07
1,067,819
11/27/2011 12:00:58
93
0
No suitable driver found exception in a Web Service on Glassfish server
I have a Java Web Application and using an operation of it from a consumer Java App i want to handle a MySQL database. When i am trying to get a connection to the database i get a: No suitable driver found for jdbc:mysql://localhost:3306/mysql I have put the JDBC connector jar to the classpath of both my Web App and the Java App that tries to consume the Web Service. I am using NetBeans IDE.
java
mysql
web-services
netbeans
jdbc
null
open
No suitable driver found exception in a Web Service on Glassfish server === I have a Java Web Application and using an operation of it from a consumer Java App i want to handle a MySQL database. When i am trying to get a connection to the database i get a: No suitable driver found for jdbc:mysql://localhost:3306/mysql I have put the JDBC connector jar to the classpath of both my Web App and the Java App that tries to consume the Web Service. I am using NetBeans IDE.
0
7,525,953
09/23/2011 08:01:23
795,849
06/13/2011 11:31:43
75
0
SSIS 2008 delete folder labeled with date
in SSIS 2008, how can code the following requirement: - delete all folder (labeled with date) < Current Date -30 Days ? any help much appreciate thxs!
ssis
null
null
null
null
null
open
SSIS 2008 delete folder labeled with date === in SSIS 2008, how can code the following requirement: - delete all folder (labeled with date) < Current Date -30 Days ? any help much appreciate thxs!
0
9,534,395
03/02/2012 13:50:24
1,058,586
11/21/2011 20:51:49
69
0
jQuery AJAX call to a database query
I have an AJAX function as so: function admin_check_fn(type) { //$("#notice_div").show(); //var allform = $('form#all').serialize(); $.ajax({ type: "POST", //async: false, url: "<?php bloginfo('template_url'); ?>/profile/adminquery_check.php", data: { type: type }, //data: 'code='+code+'&userid='+userid, dataType: "json", //dataType: "html", success: function(result){ var allresult = result.res $('#result').html( allresult ); alert(allresult); //$("#notice_div").hide(); } }) } And server-side: $queryy="SELECT * FROM wp_users"; $name = array(); $resultt=mysql_query($queryy) or die(mysql_error()); ?> <?php while($rowss=mysql_fetch_array($resultt)){ $name = $rowss['display_name']; } echo json_encode( array( "res" => array($rowss['display_name']), "fvdfvv" => "sdfsd" ) ); Basically for some reason it is not displaying all of the returned values from the query to the users table in the database. It works when I query another table with just one entry in it, so im thinking it could be something to do with the fact there is an array it is not parsing correctly? Just wondered if anyone else has came accross this problem? Thanks
jquery
mysql
ajax
null
null
null
open
jQuery AJAX call to a database query === I have an AJAX function as so: function admin_check_fn(type) { //$("#notice_div").show(); //var allform = $('form#all').serialize(); $.ajax({ type: "POST", //async: false, url: "<?php bloginfo('template_url'); ?>/profile/adminquery_check.php", data: { type: type }, //data: 'code='+code+'&userid='+userid, dataType: "json", //dataType: "html", success: function(result){ var allresult = result.res $('#result').html( allresult ); alert(allresult); //$("#notice_div").hide(); } }) } And server-side: $queryy="SELECT * FROM wp_users"; $name = array(); $resultt=mysql_query($queryy) or die(mysql_error()); ?> <?php while($rowss=mysql_fetch_array($resultt)){ $name = $rowss['display_name']; } echo json_encode( array( "res" => array($rowss['display_name']), "fvdfvv" => "sdfsd" ) ); Basically for some reason it is not displaying all of the returned values from the query to the users table in the database. It works when I query another table with just one entry in it, so im thinking it could be something to do with the fact there is an array it is not parsing correctly? Just wondered if anyone else has came accross this problem? Thanks
0
422,543
01/07/2009 23:01:10
45,533
12/11/2008 22:17:46
1
0
Determining when a sound has finished playing in C#
Here is the situation:<br> User looks something up.<br> - Alert sound is played because there is a notice on the item he looked up - User closes the notice - the application continues to retrieve information - User is sent a 'ding' telling them the information has finished retrieving - Application begins sending certain attributes to TextToSpeech - The application encounters a notice second, internal notice on the data and sends another alert (texttospeech is paused, then resumed after the alert finishes) - Text to speech is finished, another 'ding' is played letting the user know that is has read everything We currently use a queue to process sounds in an orderly fashion to prevent overlapping of sounds. We currently only play a sound from the queue when the SoundAdded event is called. This is a custom event we made to be raised when we add a sound to the queue. Currently, only one sound will be played per calling of the event. We have run into the problem where after certain sounds are played, they will 'lock' the queue, preventing further sounds from being process. We got around this by always 'unlocking' the queue even if a sound doesn't play. However, this still leaves us with the problem of the queue getting backed up with sounds to play. The only method I can think of to solve this is to add a loop to keep trying to play the sound if there is still a sound waiting to be played. Currently, the main thread is handling sounds, I would probably need to move sound handling to a separate thread, but I'm not sure what the best method of handing the sound would be. So... my question... Is there a good sound library that we can use that includes an event for the end of a sound. Or... what would be the best way to create such a thing?
c#
audio
.net
null
null
null
open
Determining when a sound has finished playing in C# === Here is the situation:<br> User looks something up.<br> - Alert sound is played because there is a notice on the item he looked up - User closes the notice - the application continues to retrieve information - User is sent a 'ding' telling them the information has finished retrieving - Application begins sending certain attributes to TextToSpeech - The application encounters a notice second, internal notice on the data and sends another alert (texttospeech is paused, then resumed after the alert finishes) - Text to speech is finished, another 'ding' is played letting the user know that is has read everything We currently use a queue to process sounds in an orderly fashion to prevent overlapping of sounds. We currently only play a sound from the queue when the SoundAdded event is called. This is a custom event we made to be raised when we add a sound to the queue. Currently, only one sound will be played per calling of the event. We have run into the problem where after certain sounds are played, they will 'lock' the queue, preventing further sounds from being process. We got around this by always 'unlocking' the queue even if a sound doesn't play. However, this still leaves us with the problem of the queue getting backed up with sounds to play. The only method I can think of to solve this is to add a loop to keep trying to play the sound if there is still a sound waiting to be played. Currently, the main thread is handling sounds, I would probably need to move sound handling to a separate thread, but I'm not sure what the best method of handing the sound would be. So... my question... Is there a good sound library that we can use that includes an event for the end of a sound. Or... what would be the best way to create such a thing?
0
7,108,628
08/18/2011 14:01:03
884,007
08/08/2011 11:56:14
23
0
eclipse do two tasks in one step
I'd like a macro recorder, such as [this one](http://sourceforge.net/projects/practicalmacro/files/), or any other macro recorder, or any other eclipse trick that doesn't use a macro recorder (see I'm not exigent!) to do in one step only (click or keyboard shortcut) the two following tasks: running a maven configuration, followed by running a debug as... operation. Thanks.
eclipse
null
null
null
null
null
open
eclipse do two tasks in one step === I'd like a macro recorder, such as [this one](http://sourceforge.net/projects/practicalmacro/files/), or any other macro recorder, or any other eclipse trick that doesn't use a macro recorder (see I'm not exigent!) to do in one step only (click or keyboard shortcut) the two following tasks: running a maven configuration, followed by running a debug as... operation. Thanks.
0
642,103
03/13/2009 10:28:58
77,616
03/13/2009 09:16:08
1
0
Casting interfaces and MEF
I have the following problem with MEF: Interface definition to be used by host: Public Interface IExecuteDoSomething Inherits IAddinSettings Event DataReceived As EventHandler(Of DataReceivedEventArgs) Function DoSomething() As Boolean End Interface Public Class DataReceivedEventArgs Inherits EventArgs Public Sub New(ByVal message As String) Me.Message = message End Sub Public Message As String End Class extra interface needed by some other code inside the host: Public Interface IAddinSettings ReadOnly Property Setting() As AddinSettings End Interface Public Class AddinSettings Private _Name As String Public Property Name() As String Get Return _Name End Get Set(ByVal value As String) _Name = value End Set End Property Public Sub New(ByVal name As String) Me.Name = name End Sub End Class The class that provides the export: <Export(GetType(SharedLibrary.IExecuteDoSomething))> Public Class Class1 Implements SharedLibrary.IExecuteDoSomething Implements SharedLibrary.IAddinSettings Private _Addinsettings As New SharedLibrary.Addinsettings("Test") Public Function DoSomething() As Boolean Implements SharedLibrary.IExecuteDoSomething.DoSomething MsgBox("i did something") Return True End Function Public Event DataReceived(ByVal sender As Object, ByVal e As SharedLibrary.DataReceivedEventArgs) Implements SharedLibrary.IExecuteDoSomething.DataReceived Public ReadOnly Property Setting() As SharedLibrary.AddinSettings Implements SharedLibrary.IAddinSettings.Setting Get Return _Addinsettings End Get End Property End Class The host: Public Class Form1 Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load Dim catalog As New Hosting.AggregateCatalog Dim d As New Hosting.DirectoryCatalog("..path to dlll..") catalog.Catalogs.Add(d) Dim container = New Hosting.CompositionContainer(catalog) Dim batch As New Hosting.CompositionBatch batch.AddPart(Me) container.Compose(batch) For Each dd In dos AddHandler dd.DataReceived, AddressOf testevent Next End Sub <Import()> Public dos As IEnumerable(Of SharedLibrary.IExecuteDoSomething) Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click For Each d In dos d.DoSomething() Next End Sub Private Sub testevent(ByVal sender As Object, ByVal e As SharedLibrary.DataReceivedEventArgs) MsgBox("Event received: " & e.Message) End Sub Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click Dosomethingelse(DirectCast(dos, System.Collections.Generic.List(Of SharedLibrary.IAddinSettings))) End Sub Private Sub Dosomethingelse(byval settings as IEnumerable(Of SharedLibrary.IAddinSettings)) End Sub End Class Everything seems to work fine until the Button2_Click routine is executed, then an InvalidCastException is thrown with the info: Unable to cast object of type 'System.Collections.Generic.List`1[SharedLibrary.IExecuteDoSomething]' to type 'System.Collections.Generic.List`1[SharedLibrary.IAddinSettings]'. How can i solve this problem, because the imported object implements both of the interfaces?
mef
vb.net
interface
null
null
null
open
Casting interfaces and MEF === I have the following problem with MEF: Interface definition to be used by host: Public Interface IExecuteDoSomething Inherits IAddinSettings Event DataReceived As EventHandler(Of DataReceivedEventArgs) Function DoSomething() As Boolean End Interface Public Class DataReceivedEventArgs Inherits EventArgs Public Sub New(ByVal message As String) Me.Message = message End Sub Public Message As String End Class extra interface needed by some other code inside the host: Public Interface IAddinSettings ReadOnly Property Setting() As AddinSettings End Interface Public Class AddinSettings Private _Name As String Public Property Name() As String Get Return _Name End Get Set(ByVal value As String) _Name = value End Set End Property Public Sub New(ByVal name As String) Me.Name = name End Sub End Class The class that provides the export: <Export(GetType(SharedLibrary.IExecuteDoSomething))> Public Class Class1 Implements SharedLibrary.IExecuteDoSomething Implements SharedLibrary.IAddinSettings Private _Addinsettings As New SharedLibrary.Addinsettings("Test") Public Function DoSomething() As Boolean Implements SharedLibrary.IExecuteDoSomething.DoSomething MsgBox("i did something") Return True End Function Public Event DataReceived(ByVal sender As Object, ByVal e As SharedLibrary.DataReceivedEventArgs) Implements SharedLibrary.IExecuteDoSomething.DataReceived Public ReadOnly Property Setting() As SharedLibrary.AddinSettings Implements SharedLibrary.IAddinSettings.Setting Get Return _Addinsettings End Get End Property End Class The host: Public Class Form1 Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load Dim catalog As New Hosting.AggregateCatalog Dim d As New Hosting.DirectoryCatalog("..path to dlll..") catalog.Catalogs.Add(d) Dim container = New Hosting.CompositionContainer(catalog) Dim batch As New Hosting.CompositionBatch batch.AddPart(Me) container.Compose(batch) For Each dd In dos AddHandler dd.DataReceived, AddressOf testevent Next End Sub <Import()> Public dos As IEnumerable(Of SharedLibrary.IExecuteDoSomething) Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click For Each d In dos d.DoSomething() Next End Sub Private Sub testevent(ByVal sender As Object, ByVal e As SharedLibrary.DataReceivedEventArgs) MsgBox("Event received: " & e.Message) End Sub Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click Dosomethingelse(DirectCast(dos, System.Collections.Generic.List(Of SharedLibrary.IAddinSettings))) End Sub Private Sub Dosomethingelse(byval settings as IEnumerable(Of SharedLibrary.IAddinSettings)) End Sub End Class Everything seems to work fine until the Button2_Click routine is executed, then an InvalidCastException is thrown with the info: Unable to cast object of type 'System.Collections.Generic.List`1[SharedLibrary.IExecuteDoSomething]' to type 'System.Collections.Generic.List`1[SharedLibrary.IAddinSettings]'. How can i solve this problem, because the imported object implements both of the interfaces?
0
2,193,682
02/03/2010 16:54:56
265,451
02/03/2010 16:45:23
1
0
Jython & Mysql - what is the current practice for connection?
Just trying jython for the first time, because something came up at work that would fit for this perfect for it. I assume jython can make mysql jdbc connection using the mysql jdbc driver. After googling and reading, however I am having problems and it seems jython specific and probably simple. so i do jython: Jython 2.5.1 (Release_2_5_1:6813, Sep 26 2009, 13:47:54) [Java HotSpot(TM) 64-Bit Server VM (Apple Inc.)] on java1.6.0_17 Type "help", "copyright", "credits" or "license" for more information. >>> import sys >>> print sys.path ['', '/JYTHONPATH/mysql-connector-java-5.1.10-bin.jar', '/WorkArea/Apps/jython/jython2.5.1/Lib', '__classpath__', '__pyclasspath__/', '/WorkArea/Apps/jython/jython2.5.1/Lib/site-packages'] >>> ***code i'm running*** from java.lang import * from java.sql import * driverName="com.mysql.jdbc.Driver" Class.forName(driverName) url = "jdbc:mysql://localhost/test?user=jgreenaw&password=" con = DriverManager.getConnection(url) stmt = con.createStatement() ***output*** riux:Desktop$ jython pymysql.py Traceback (most recent call last): File "pymysql.py", line 7, in <module> Class.forName(driverName) at java.net.URLClassLoader$1.run(URLClassLoader.java:200) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:188) at java.lang.ClassLoader.loadClass(ClassLoader.java:315) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:330) at java.lang.ClassLoader.loadClass(ClassLoader.java:250) at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:398) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:169) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) java.lang.ClassNotFoundException: java.lang.ClassNotFoundException: com.mysql.jdbc.Driver any advice? thanks
mysql
jython
null
null
null
null
open
Jython & Mysql - what is the current practice for connection? === Just trying jython for the first time, because something came up at work that would fit for this perfect for it. I assume jython can make mysql jdbc connection using the mysql jdbc driver. After googling and reading, however I am having problems and it seems jython specific and probably simple. so i do jython: Jython 2.5.1 (Release_2_5_1:6813, Sep 26 2009, 13:47:54) [Java HotSpot(TM) 64-Bit Server VM (Apple Inc.)] on java1.6.0_17 Type "help", "copyright", "credits" or "license" for more information. >>> import sys >>> print sys.path ['', '/JYTHONPATH/mysql-connector-java-5.1.10-bin.jar', '/WorkArea/Apps/jython/jython2.5.1/Lib', '__classpath__', '__pyclasspath__/', '/WorkArea/Apps/jython/jython2.5.1/Lib/site-packages'] >>> ***code i'm running*** from java.lang import * from java.sql import * driverName="com.mysql.jdbc.Driver" Class.forName(driverName) url = "jdbc:mysql://localhost/test?user=jgreenaw&password=" con = DriverManager.getConnection(url) stmt = con.createStatement() ***output*** riux:Desktop$ jython pymysql.py Traceback (most recent call last): File "pymysql.py", line 7, in <module> Class.forName(driverName) at java.net.URLClassLoader$1.run(URLClassLoader.java:200) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:188) at java.lang.ClassLoader.loadClass(ClassLoader.java:315) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:330) at java.lang.ClassLoader.loadClass(ClassLoader.java:250) at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:398) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:169) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) java.lang.ClassNotFoundException: java.lang.ClassNotFoundException: com.mysql.jdbc.Driver any advice? thanks
0
11,098,746
06/19/2012 10:04:23
1,211,465
02/15/2012 13:46:07
389
2
play icon youtube video div overlay
I have an image nav but the client wants to add a video icon via the product description. ![enter image description here][1] When the user clicks on the video icon it should overlay the youtube video on top of the main product image. Kinda like hiding it and just showing the video. I cannot find any jquery plugin that can do this? Here is some example markup which i have created, when you click play on the icon i want the youtube video to be played inside of the red box on top of the image. **Look at my example:** http://jsfiddle.net/mC5c3/4/ **HTML:** <div class="container"> <div class="product-image"> <img src="http://www.skriftlig.com/konfliktmegling/wp-content/uploads/2010/02/Photoxpress_2658886-480x220.jpg" alt="http://www.skriftlig.com/konfliktmegling/wp-content/uploads/2010/02/Photoxpress_2658886-480x220.jpg"> </div> <div class="image-nav"> </div> <div class="icon"> &nbsp </div> </div> **CSS:** div.container { margin:10px 10px auto; border:1px solid orange; } div.product-image { height:220px; width:480px; border:1px solid red; margin:30px; } div.image-nav { border:1px solid black; width:500px; height:100px; margin:30px; } div.icon { background-image: url("http://i.stack.imgur.com/zsQik.png"); background-repeat: no-repeat; height: 50px; left: 540px; position: relative; top: -104px; width: 50px; } [1]: http://i.stack.imgur.com/zsQik.png
javascript
jquery
css
youtube
overlay
null
open
play icon youtube video div overlay === I have an image nav but the client wants to add a video icon via the product description. ![enter image description here][1] When the user clicks on the video icon it should overlay the youtube video on top of the main product image. Kinda like hiding it and just showing the video. I cannot find any jquery plugin that can do this? Here is some example markup which i have created, when you click play on the icon i want the youtube video to be played inside of the red box on top of the image. **Look at my example:** http://jsfiddle.net/mC5c3/4/ **HTML:** <div class="container"> <div class="product-image"> <img src="http://www.skriftlig.com/konfliktmegling/wp-content/uploads/2010/02/Photoxpress_2658886-480x220.jpg" alt="http://www.skriftlig.com/konfliktmegling/wp-content/uploads/2010/02/Photoxpress_2658886-480x220.jpg"> </div> <div class="image-nav"> </div> <div class="icon"> &nbsp </div> </div> **CSS:** div.container { margin:10px 10px auto; border:1px solid orange; } div.product-image { height:220px; width:480px; border:1px solid red; margin:30px; } div.image-nav { border:1px solid black; width:500px; height:100px; margin:30px; } div.icon { background-image: url("http://i.stack.imgur.com/zsQik.png"); background-repeat: no-repeat; height: 50px; left: 540px; position: relative; top: -104px; width: 50px; } [1]: http://i.stack.imgur.com/zsQik.png
0
3,134,585
06/28/2010 17:19:20
82,368
03/25/2009 04:27:50
1,099
32
Book Recommendation to learn more about Virtual Machines
I have always been intrigued and mystified by Virtual Machines and how they operate. I want to learn more about the inner workings of a virtual machine. Are there any good books on Virtual Machines/Virtual machine designs/Tour of a sample machine? How do I go about studying one? Do I pick up a spec for the JVM or start with the LLVM? Please Advice. Thank you.
clr
jvm
virtual-machine
vm
null
09/17/2011 22:42:49
not constructive
Book Recommendation to learn more about Virtual Machines === I have always been intrigued and mystified by Virtual Machines and how they operate. I want to learn more about the inner workings of a virtual machine. Are there any good books on Virtual Machines/Virtual machine designs/Tour of a sample machine? How do I go about studying one? Do I pick up a spec for the JVM or start with the LLVM? Please Advice. Thank you.
4
1,858,886
12/07/2009 09:38:15
102,040
03/21/2009 15:04:39
434
20
what are the fastest/Popular search technologies
What are the fastest search technologies apart from Relational DB Searches ? I have a collection of Text Files from varied sources (Banks/Ledgers/Stock Markets). Each line in these Text Files is a Record. Each line can further be parsed into some DB Columns(Stock Name/Date of purchase/Owner/...). It is not necessary that each line has all the fields. If some text is not mathcing any of the fields, I store it as it is in a seperate column(columnA). If the parser fails to find any column at all I just store the Line in columnA. I than do a DB search based on user Inputs. I find that the search becomes slow after a few million records. I want to move to an alternative storage like File System or some other Indexed storage. What do you think would be the fastest storage technology for this kind of requirement ? I am currently using SQLite DB. Since I am about to rewrite the entire code, I will be more than happy if any other storage technology can give me faster results.
database
search
full-text-search
indexing
null
04/27/2012 12:22:04
not constructive
what are the fastest/Popular search technologies === What are the fastest search technologies apart from Relational DB Searches ? I have a collection of Text Files from varied sources (Banks/Ledgers/Stock Markets). Each line in these Text Files is a Record. Each line can further be parsed into some DB Columns(Stock Name/Date of purchase/Owner/...). It is not necessary that each line has all the fields. If some text is not mathcing any of the fields, I store it as it is in a seperate column(columnA). If the parser fails to find any column at all I just store the Line in columnA. I than do a DB search based on user Inputs. I find that the search becomes slow after a few million records. I want to move to an alternative storage like File System or some other Indexed storage. What do you think would be the fastest storage technology for this kind of requirement ? I am currently using SQLite DB. Since I am about to rewrite the entire code, I will be more than happy if any other storage technology can give me faster results.
4
4,236,352
11/21/2010 03:53:29
514,880
11/21/2010 03:47:58
1
0
No ADT plugin options available
I'm running Ubuntu 10.10 and installed Eclipse 3.5 (Galileo) for Java Developers along with the Android SDK. When I add the following URL into the "work With" field under Eclipse's Install New Software menu: https://dl-ssl.google.com/android/eclipse No plugins appear between the "Work With" and "Options" sections. I understand I'm supposed to be able to select "Developer Tools". I get nothing. I've tried linking to http vice https. Also, downloading the zip from the android dev site itself yields the same result. When I run "Check for Updates", it comes back saying nothing to update. I also ran "Test Connecction" for the above URL and it comes back positive. Any advice? Thanks very much.
eclipse-plugin
null
null
null
null
null
open
No ADT plugin options available === I'm running Ubuntu 10.10 and installed Eclipse 3.5 (Galileo) for Java Developers along with the Android SDK. When I add the following URL into the "work With" field under Eclipse's Install New Software menu: https://dl-ssl.google.com/android/eclipse No plugins appear between the "Work With" and "Options" sections. I understand I'm supposed to be able to select "Developer Tools". I get nothing. I've tried linking to http vice https. Also, downloading the zip from the android dev site itself yields the same result. When I run "Check for Updates", it comes back saying nothing to update. I also ran "Test Connecction" for the above URL and it comes back positive. Any advice? Thanks very much.
0
2,459,897
03/17/2010 04:25:50
40,945
11/26/2008 08:20:12
1,651
44
Using grails service in domain class
In my grails application I want use service.However it is always coming as null.I am using grails 1.1 version.How to solve this problem. Sample code: class A{ String name; def testService; static transients=['testService'] } Can we use service inside domain class?
grails
null
null
null
null
null
open
Using grails service in domain class === In my grails application I want use service.However it is always coming as null.I am using grails 1.1 version.How to solve this problem. Sample code: class A{ String name; def testService; static transients=['testService'] } Can we use service inside domain class?
0
5,636,028
04/12/2011 13:32:50
767,766
04/12/2011 13:02:08
1
0
query related to window7(64bit) and (32 bit) O.S
how to run 32 bit apps on 64 bit o.s?
query
null
null
null
null
04/12/2011 15:24:08
not a real question
query related to window7(64bit) and (32 bit) O.S === how to run 32 bit apps on 64 bit o.s?
1
3,788,667
09/24/2010 15:39:17
405,398
07/29/2010 07:41:10
311
0
Can any one explain this SQL Query?
Today, my boss told the below SQL query and went out without explaining it. Its working good. But i want to know the way how it works. `SELECT NAME FROM PERMISSIONTOKENS WHERE ID IN(SELECT TOKENID FROM ROLETOKENASSOCIATION WHERE ROLEID = '1');`
sql
null
null
null
null
null
open
Can any one explain this SQL Query? === Today, my boss told the below SQL query and went out without explaining it. Its working good. But i want to know the way how it works. `SELECT NAME FROM PERMISSIONTOKENS WHERE ID IN(SELECT TOKENID FROM ROLETOKENASSOCIATION WHERE ROLEID = '1');`
0
4,611,111
01/06/2011 01:59:00
192,910
10/20/2009 07:56:41
3,700
194
Best framework or system architecture for telemetry / SCADA system design & programming
I asked [a question about a good book for this topic][1]. It's not getting many replies, so maybe there arn't any good books (although I find that strange; I must go search Amazon for myself). In the absence of a book, maybe tehre is a good framework, some good URLs, or just general advice. As I asked in the other question: > I am looking at several projects, all > with roughly the same fucntionality. > > Some instruments collect some data (or > control some functionality). They > commmunicate by Internet > (Etehrnet/wifi/GPRS/sasatellite) with > a databse server which stores the > measurements and provides a browser > based means of qeurying the data, > prodcuing reports, etc (and possibly > also allows control of the remote > equipment). > > Can anyone recommend a good book > describing an approach to developing > such a software architecture, keeping > it generic, which tools, languages. > test methods, etc to use? For "book", please substitute "framework, some good URLs, or just general advice". This is a very common system pattern. Who can advise? Thanks [1]: http://stackoverflow.com/questions/4605635/please-recommend-good-books-for-telemetry-scada-system-design-programming
web-applications
architecture
frameworks
performance-measurement
scada
null
open
Best framework or system architecture for telemetry / SCADA system design & programming === I asked [a question about a good book for this topic][1]. It's not getting many replies, so maybe there arn't any good books (although I find that strange; I must go search Amazon for myself). In the absence of a book, maybe tehre is a good framework, some good URLs, or just general advice. As I asked in the other question: > I am looking at several projects, all > with roughly the same fucntionality. > > Some instruments collect some data (or > control some functionality). They > commmunicate by Internet > (Etehrnet/wifi/GPRS/sasatellite) with > a databse server which stores the > measurements and provides a browser > based means of qeurying the data, > prodcuing reports, etc (and possibly > also allows control of the remote > equipment). > > Can anyone recommend a good book > describing an approach to developing > such a software architecture, keeping > it generic, which tools, languages. > test methods, etc to use? For "book", please substitute "framework, some good URLs, or just general advice". This is a very common system pattern. Who can advise? Thanks [1]: http://stackoverflow.com/questions/4605635/please-recommend-good-books-for-telemetry-scada-system-design-programming
0
7,481,934
09/20/2011 08:04:16
860,191
07/24/2011 12:11:55
19
0
Asp.net mvc work with out Inernet connection on Server computer
Does someone has done the following: Omu.Awesome.Core.dll and Omu.Awesome.Mvc.dll asp.net mvc applications should be running on your computer that has no connection to I internet.All localized and removed files are not the only acquaintance I Has anyone worked with him and how can you look at the source code of the project?
asp.net-mvc
null
null
null
null
09/20/2011 19:15:11
not a real question
Asp.net mvc work with out Inernet connection on Server computer === Does someone has done the following: Omu.Awesome.Core.dll and Omu.Awesome.Mvc.dll asp.net mvc applications should be running on your computer that has no connection to I internet.All localized and removed files are not the only acquaintance I Has anyone worked with him and how can you look at the source code of the project?
1
9,074,771
01/31/2012 05:17:37
1,179,554
01/31/2012 05:03:14
1
0
Java - How do I Retrieve Text from Website (Not Source)
I want to use java to retrieve text from a website. I can easily get the source by doing: (Thank you random internet person who posted this somewhere else) import java.io.BufferedReader; import java.io.InputStreamReader; import java.net.URL; import java.net.URLConnection; public class WebCrawler{ public static void main(String[] args) { try { URL google = new URL("http://stackoverflow.com"); URLConnection yc = google.openConnection(); BufferedReader in = new BufferedReader(new InputStreamReader(yc.getInputStream())); String inputLine; while ((inputLine = in.readLine()) != null) { System.out.println(inputLine); } in.close(); } catch (Exception e) { e.printStackTrace(); } } } However this leaves me with the problem of some sites returning 403s. Is there a way of getting around this? Very simply I was hoping to use java to create a simple bot that would scan a forum thread and automatically respond based of user queries. Am I able to do this in java? or do I need to look at it from the perspective of another language/ data retrieval method? Thank you for your time.
java
bots
null
null
null
01/31/2012 13:05:44
not constructive
Java - How do I Retrieve Text from Website (Not Source) === I want to use java to retrieve text from a website. I can easily get the source by doing: (Thank you random internet person who posted this somewhere else) import java.io.BufferedReader; import java.io.InputStreamReader; import java.net.URL; import java.net.URLConnection; public class WebCrawler{ public static void main(String[] args) { try { URL google = new URL("http://stackoverflow.com"); URLConnection yc = google.openConnection(); BufferedReader in = new BufferedReader(new InputStreamReader(yc.getInputStream())); String inputLine; while ((inputLine = in.readLine()) != null) { System.out.println(inputLine); } in.close(); } catch (Exception e) { e.printStackTrace(); } } } However this leaves me with the problem of some sites returning 403s. Is there a way of getting around this? Very simply I was hoping to use java to create a simple bot that would scan a forum thread and automatically respond based of user queries. Am I able to do this in java? or do I need to look at it from the perspective of another language/ data retrieval method? Thank you for your time.
4
6,636,810
07/09/2011 18:56:47
458,610
09/26/2010 08:40:27
727
6
What is CMS anyway?
I understand that CMS stands for "Content Management System". As much as I understand... that means that user can change pages of site without knowing HTML, right? He just sign in (so there are some authorization system) and can freely add/modify/remove pages with some kind of rich-text editor. Right? And when he saves the page, content is submitted and saved into text-file (bad, arghh) or database. Is that true? For example, Wordpress is CMS.
php
web-applications
content-management-system
null
null
07/09/2011 19:22:57
not a real question
What is CMS anyway? === I understand that CMS stands for "Content Management System". As much as I understand... that means that user can change pages of site without knowing HTML, right? He just sign in (so there are some authorization system) and can freely add/modify/remove pages with some kind of rich-text editor. Right? And when he saves the page, content is submitted and saved into text-file (bad, arghh) or database. Is that true? For example, Wordpress is CMS.
1
11,317,117
07/03/2012 18:38:50
1,499,683
07/03/2012 18:36:03
1
0
Mod_Rewrite Expert Needed
I'm creating a website with Mod_Rewrite at the Moment All urls are redirected to the page name with .php on the end. But /about/ and /photos/ should redirect to page.php?page=about and page.php?page=photos. Is there a way to do this? Connor
php
mod-rewrite
null
null
null
null
open
Mod_Rewrite Expert Needed === I'm creating a website with Mod_Rewrite at the Moment All urls are redirected to the page name with .php on the end. But /about/ and /photos/ should redirect to page.php?page=about and page.php?page=photos. Is there a way to do this? Connor
0
11,113,867
06/20/2012 06:21:00
1,321,343
04/09/2012 06:59:30
1
0
Best technique to do multi theading in C++
Which is the best technique to do multi threading in C++ on linux platform.
c++
linux
multithreading
api
null
06/20/2012 06:29:57
not a real question
Best technique to do multi theading in C++ === Which is the best technique to do multi threading in C++ on linux platform.
1
9,666,629
03/12/2012 12:00:37
1,263,859
03/12/2012 10:25:48
1
0
InetAddress not able to retrieve FQDN while nslookup is able to
I'm trying to retrieve a FQDN of a specific computer from the DNS but on my environment when I use nslookup on the hostname I get its FQDN but when I try this code in Java I only get the host name back: netAddress.getByName("Host name or address").getCanonicalHostName() What can be the cause? Is there a better method of getting the FQDN from a host name without credentials or connection to the LDAP server?
java
ldap
domain
dns
null
null
open
InetAddress not able to retrieve FQDN while nslookup is able to === I'm trying to retrieve a FQDN of a specific computer from the DNS but on my environment when I use nslookup on the hostname I get its FQDN but when I try this code in Java I only get the host name back: netAddress.getByName("Host name or address").getCanonicalHostName() What can be the cause? Is there a better method of getting the FQDN from a host name without credentials or connection to the LDAP server?
0
6,616,976
07/07/2011 20:47:52
814,962
06/25/2011 02:43:40
32
0
Why does this SSL_pending call always return zero?
This code is for an HTTPS server using blocking sockets: request := ''; start := gettickcount; repeat if SSL_pending(ssl) > 0 then begin bytesin := SSL_read(ssl, buffer, sizeof(buffer)-1); if bytesin > 0 then begin buffer[bytesin] := #0; request := request + buffer; end else break; // read failed end; // pending until (gettickcount - start) > LARGETIMEOUT; // "request" is ready, though possibly empty SSL_pending() **always** returns zero and the SSL_read() is never reached. If the SSL_pending() call is removed, SSL_read() is executed. Why doesn't SSL_pending() indicate how many bytes are available? Note that if you call SSL_read() and the number of bytes returned is less than your buffer size, you've read everything and are done. If the incoming data is larger than your buffer size, the first SSL_read() call fills the buffer, and you can repeat calling SSL_read() until you can't fill the buffer. **BUT** if the incoming data is an exact multiple of your buffer size, the last chunk of data fills the buffer. If you attempt another SSL_read() thinking there might be more data on a blocking socket, it hangs indefinitely. Hence the desire to check SSL_pending() first. Yet that doesn't appear to work. How do you avoid hanging on a final SSL_read()? (I can't imagine the answer is to go non-blocking, since that means you could never use SSL_read with blocking.)
https
openssl
winsock
null
null
null
open
Why does this SSL_pending call always return zero? === This code is for an HTTPS server using blocking sockets: request := ''; start := gettickcount; repeat if SSL_pending(ssl) > 0 then begin bytesin := SSL_read(ssl, buffer, sizeof(buffer)-1); if bytesin > 0 then begin buffer[bytesin] := #0; request := request + buffer; end else break; // read failed end; // pending until (gettickcount - start) > LARGETIMEOUT; // "request" is ready, though possibly empty SSL_pending() **always** returns zero and the SSL_read() is never reached. If the SSL_pending() call is removed, SSL_read() is executed. Why doesn't SSL_pending() indicate how many bytes are available? Note that if you call SSL_read() and the number of bytes returned is less than your buffer size, you've read everything and are done. If the incoming data is larger than your buffer size, the first SSL_read() call fills the buffer, and you can repeat calling SSL_read() until you can't fill the buffer. **BUT** if the incoming data is an exact multiple of your buffer size, the last chunk of data fills the buffer. If you attempt another SSL_read() thinking there might be more data on a blocking socket, it hangs indefinitely. Hence the desire to check SSL_pending() first. Yet that doesn't appear to work. How do you avoid hanging on a final SSL_read()? (I can't imagine the answer is to go non-blocking, since that means you could never use SSL_read with blocking.)
0
4,116,306
11/07/2010 02:54:03
294,916
03/16/2010 15:59:44
6
0
NSFetchedResultsController and childController
In the [RootViewController][1] I do a fetch request to the core data store (?) and it returns an NSSet of, let's say, recipes. When a user selects a recipe in the rootviewcontroller I do a pushViewController and push one of the recipes to the childcontroller. In the childController the user has the possibility to refresh the "recipe" so he can update the ingredients for example. When the users selects "refresh" I connect to the interwebs to receive new data. This new data I puth in self.recipe.ingredients. This all works great. But then I want to reload the chilController view. All the refreshing stuff is done in the background so I want to emit a signal when the core data stuff is finished. Hello NSFetchedResultsController! But to use NSFetchedResultsController you need a NSFetchRequest. And that NSFetchRequest is instantiated in my rootViewController. So when I create a controllerDidChangeContent method in my rootViewController I see it getting triggered. But now is the question: how can I update my childViewController's tableview? I thought about calling this method in my rootViewControllers' controllerDidChangeContent method: [self.childController controllerDidChangeContent:controller] So just passing on the fired method Or when instantiating the childController, I could also pass on the fetchRequest to the childController and instantiating a new NSFetchedResultsController in the childController instance. What would be the best of those two? Or are there other posibilities I haven't thinked of? Thanks in advance! [1]: https://github.com/LeonB/Munin/blob/master/Classes/MuninMastersViewController.m
iphone
null
null
null
null
null
open
NSFetchedResultsController and childController === In the [RootViewController][1] I do a fetch request to the core data store (?) and it returns an NSSet of, let's say, recipes. When a user selects a recipe in the rootviewcontroller I do a pushViewController and push one of the recipes to the childcontroller. In the childController the user has the possibility to refresh the "recipe" so he can update the ingredients for example. When the users selects "refresh" I connect to the interwebs to receive new data. This new data I puth in self.recipe.ingredients. This all works great. But then I want to reload the chilController view. All the refreshing stuff is done in the background so I want to emit a signal when the core data stuff is finished. Hello NSFetchedResultsController! But to use NSFetchedResultsController you need a NSFetchRequest. And that NSFetchRequest is instantiated in my rootViewController. So when I create a controllerDidChangeContent method in my rootViewController I see it getting triggered. But now is the question: how can I update my childViewController's tableview? I thought about calling this method in my rootViewControllers' controllerDidChangeContent method: [self.childController controllerDidChangeContent:controller] So just passing on the fired method Or when instantiating the childController, I could also pass on the fetchRequest to the childController and instantiating a new NSFetchedResultsController in the childController instance. What would be the best of those two? Or are there other posibilities I haven't thinked of? Thanks in advance! [1]: https://github.com/LeonB/Munin/blob/master/Classes/MuninMastersViewController.m
0
3,780,515
09/23/2010 16:30:24
363,889
06/10/2010 19:39:01
123
0
Hibernate Annotations and SQL Server
I'm using Hibernate Annotations and trying to save an object. But when saving object I get: Cannot insert the value NULL into column 'status' The thing is that in my SQL Server 2008 configuration that field is defaulted to '0'. Now I dot not want to manually set the default value in my Java code like status='0', because I think this is a bad idea in case the database default value needs to be change. How can I tell Hibernate Annotations to use the database default value? Thanks in advance!!!
java
sql-server
hibernate
jpa
annotations
09/24/2010 02:37:24
too localized
Hibernate Annotations and SQL Server === I'm using Hibernate Annotations and trying to save an object. But when saving object I get: Cannot insert the value NULL into column 'status' The thing is that in my SQL Server 2008 configuration that field is defaulted to '0'. Now I dot not want to manually set the default value in my Java code like status='0', because I think this is a bad idea in case the database default value needs to be change. How can I tell Hibernate Annotations to use the database default value? Thanks in advance!!!
3
5,924,631
05/07/2011 23:16:46
743,497
05/07/2011 23:16:46
1
0
insert from two database some row to one data base that rows
if i have database with name db1 and db1 have row 1, row 2, row 3, row 4, row 5 and i have database with name db2 and db2 have row a, row b, row c, row d, row e and i have database with name db3 wih row f1, row f2, row f3 and i whant to conect next to db3 take data from row 1 and set it in row f1; to take data from row 3 and set it in row f3; and to take data from row a to set in to row f2. how to conetct 2 db and take rows what i need to copy in 3th db in rows that i whant if oyu do not understand i will make picture to show you what i need PS i need PHP scrypt for this http://img856.imageshack.us/img856/2092/unledbur.png here what i need to do this scrypt
php
null
null
null
null
05/08/2011 18:26:08
not a real question
insert from two database some row to one data base that rows === if i have database with name db1 and db1 have row 1, row 2, row 3, row 4, row 5 and i have database with name db2 and db2 have row a, row b, row c, row d, row e and i have database with name db3 wih row f1, row f2, row f3 and i whant to conect next to db3 take data from row 1 and set it in row f1; to take data from row 3 and set it in row f3; and to take data from row a to set in to row f2. how to conetct 2 db and take rows what i need to copy in 3th db in rows that i whant if oyu do not understand i will make picture to show you what i need PS i need PHP scrypt for this http://img856.imageshack.us/img856/2092/unledbur.png here what i need to do this scrypt
1
4,528,414
12/24/2010 21:33:59
1,736
08/18/2008 11:29:16
2,117
26
How to scale text when drawing to an Image with c#
I would like to draw some text in a rectangle and have it scale to the maximum size that fits within the rectangle. So far I have this: Bitmap bitmapImage = new Bitmap(500, 500); Graphics graphicImage = Graphics.FromImage(bitmapImage); graphicImage.SmoothingMode = System.Drawing.Drawing2D.SmoothingMode.AntiAlias; var rect = new Rectangle(0, 0, 500, 500); graphicImage.DrawString( "testing testing 123!", new Font("Arial", 12, FontStyle.Bold), Brushes.Black, rect); bitmapImage.Save("test.png"); it draws the text but doesn't scale up the font size.
c#
text
scale
system.drawing
null
null
open
How to scale text when drawing to an Image with c# === I would like to draw some text in a rectangle and have it scale to the maximum size that fits within the rectangle. So far I have this: Bitmap bitmapImage = new Bitmap(500, 500); Graphics graphicImage = Graphics.FromImage(bitmapImage); graphicImage.SmoothingMode = System.Drawing.Drawing2D.SmoothingMode.AntiAlias; var rect = new Rectangle(0, 0, 500, 500); graphicImage.DrawString( "testing testing 123!", new Font("Arial", 12, FontStyle.Bold), Brushes.Black, rect); bitmapImage.Save("test.png"); it draws the text but doesn't scale up the font size.
0
7,879,317
10/24/2011 17:19:46
51,649
01/05/2009 13:47:38
1,617
52
Speeding Up Writes to Amazon S3
I am trying to upload an image to Amazon S3 using C#: PutObjectRequest titledRequest = null; S3Response response = null; using (var memoryStream = new MemoryStream()) { image.Save(memoryStream, ImageFormat.Png); titledRequest = new PutObjectRequest(); titledRequest.WithBucketName(bucketName) .WithKey(keyName) .WithCannedACL(S3CannedACL.PublicRead) .WithInputStream(memoryStream); response = client.PutObject(titledRequest); } As you can see, I am not saving the image file locally but rather streaming it to S3. However, for some reason, this process takes around 50 seconds for a 50kb file! There is nothing wrong with my upload speed its well over 1mbps. I'm wondering is it faster to save the file first and upload? Is there anything I should consider to speed up upload process? Again, no problems on the broadband side of things!
c#
amazon-s3
null
null
null
null
open
Speeding Up Writes to Amazon S3 === I am trying to upload an image to Amazon S3 using C#: PutObjectRequest titledRequest = null; S3Response response = null; using (var memoryStream = new MemoryStream()) { image.Save(memoryStream, ImageFormat.Png); titledRequest = new PutObjectRequest(); titledRequest.WithBucketName(bucketName) .WithKey(keyName) .WithCannedACL(S3CannedACL.PublicRead) .WithInputStream(memoryStream); response = client.PutObject(titledRequest); } As you can see, I am not saving the image file locally but rather streaming it to S3. However, for some reason, this process takes around 50 seconds for a 50kb file! There is nothing wrong with my upload speed its well over 1mbps. I'm wondering is it faster to save the file first and upload? Is there anything I should consider to speed up upload process? Again, no problems on the broadband side of things!
0
7,447,759
09/16/2011 16:28:24
755,393
05/16/2011 09:04:11
502
31
PHP and "array json style", why not?
I don't know if I can ask this question here. I usually mistake, but... I every want the "array json style" on PHP, like `$a = [1, 2, $value];`. But I read that PHP developers HATE this idea because too many people wants, and they thought it best not to offer the feature. The question is: **WHY?** I thought that might conflict with some existing feature, but I could not think of any. **Additional**: someone know what is the PHP dev features list (where it is presented and discussed)?
php
arrays
json
null
null
09/16/2011 16:47:32
not constructive
PHP and "array json style", why not? === I don't know if I can ask this question here. I usually mistake, but... I every want the "array json style" on PHP, like `$a = [1, 2, $value];`. But I read that PHP developers HATE this idea because too many people wants, and they thought it best not to offer the feature. The question is: **WHY?** I thought that might conflict with some existing feature, but I could not think of any. **Additional**: someone know what is the PHP dev features list (where it is presented and discussed)?
4
3,890,738
10/08/2010 13:05:04
188,475
10/12/2009 14:25:20
558
53
I can code only in evenings, but not in the morning or noon. Is there any way to fix it?
This is probably not the 100% programming question. But the SO is best place to ask it. **I can code only in the evenings.** After 15:00 I perform very-very good. Till the midnight I can do more than any of my colleagues did same day. But my colleagues requires me in the morning and noon. So I must be in the office same time as they are. The only way to not stay in the office till the late night, and to not miss the meetings is to work like everybody else. **I need to be productive in the morning and noon,** but not the evening. Is there any technique to reach the goal?
productivity
time-management
null
null
null
10/08/2010 16:28:09
off topic
I can code only in evenings, but not in the morning or noon. Is there any way to fix it? === This is probably not the 100% programming question. But the SO is best place to ask it. **I can code only in the evenings.** After 15:00 I perform very-very good. Till the midnight I can do more than any of my colleagues did same day. But my colleagues requires me in the morning and noon. So I must be in the office same time as they are. The only way to not stay in the office till the late night, and to not miss the meetings is to work like everybody else. **I need to be productive in the morning and noon,** but not the evening. Is there any technique to reach the goal?
2
8,557,130
12/19/2011 04:35:13
535,967
12/09/2010 05:51:49
969
5
Nested foreach to echo a particular key from sub-array?
I'm trying to get key = 'Tipo' from each nested sub-array. This is array `$palabras`: Array ( [0] => Array ( [Palabra] => juan ) [1] => Array ( [Palabra] => es [0] => Array ( [Raiz] => ser [Tipo] => verbo1 ) [1] => Array ( [Raiz] => ser [Tipo] => verbo2 ) ) [2] => Array ( [Palabra] => un [0] => Array ( [Tipo] => articulo-indeterminado ) ) [3] => Array ( [Palabra] => adjetivo [0] => Array ( [Tipo] => Clase [Clase] => Adjetivo ) ) ) This is me trying to echo each key = 'Tipo': foreach ($palabras as $key => $palabra) { foreach ($palabra as $key2 => $meaning) { echo $palabra[$key2]['Tipo']; } } I'm sure my error is pretty simple, but I'm not sure what it is. The problem is that I get random characters between the 'Tipo's: `jeverbo1verbo2uarticulo-indeterminadoaClase` How is this done properly??
php
null
null
null
null
null
open
Nested foreach to echo a particular key from sub-array? === I'm trying to get key = 'Tipo' from each nested sub-array. This is array `$palabras`: Array ( [0] => Array ( [Palabra] => juan ) [1] => Array ( [Palabra] => es [0] => Array ( [Raiz] => ser [Tipo] => verbo1 ) [1] => Array ( [Raiz] => ser [Tipo] => verbo2 ) ) [2] => Array ( [Palabra] => un [0] => Array ( [Tipo] => articulo-indeterminado ) ) [3] => Array ( [Palabra] => adjetivo [0] => Array ( [Tipo] => Clase [Clase] => Adjetivo ) ) ) This is me trying to echo each key = 'Tipo': foreach ($palabras as $key => $palabra) { foreach ($palabra as $key2 => $meaning) { echo $palabra[$key2]['Tipo']; } } I'm sure my error is pretty simple, but I'm not sure what it is. The problem is that I get random characters between the 'Tipo's: `jeverbo1verbo2uarticulo-indeterminadoaClase` How is this done properly??
0
9,935,344
03/30/2012 00:04:55
1,292,857
03/26/2012 11:12:44
26
0
Ideas on how to copy something from 1 application to another
I am looking for ideas but what I want to know is that I am creating multiple exams. Now lets say I have 2 exams, I create the questions and answers for exam 1 and the submit the form, I then get onto exam 2, now in exam 2 there will be some different questions but there could also be the same questions from exam 1 but in a different order. What I want to know is that what if the best way so that when the user is creating exam 2, he can open up something and be able to copy the questions and answers from exam 1 into exam 2 when he wants to do that? I was thinking using a second database (a backup database) to store all questions from exam 1 and then somehow be able to copy some of these questions and answers from exam 1 into exam 2 by one question at a time. The reason I am thinking of using a backup Database is because I want all of the details to be stored in the proper database after everything is finished (if power goes out or router is turned off during the middle of creating exams, I do not want my proper database to store in hald the data so thats why I want to store it in a backup database and only store it in full database after everything is complete) The layout of my questions and answers is that a question is in a textarea and the answers are from A -Z button where the user can select as many buttons as they wish? Thanks
php
jquery
html
forms
null
03/30/2012 21:25:45
not a real question
Ideas on how to copy something from 1 application to another === I am looking for ideas but what I want to know is that I am creating multiple exams. Now lets say I have 2 exams, I create the questions and answers for exam 1 and the submit the form, I then get onto exam 2, now in exam 2 there will be some different questions but there could also be the same questions from exam 1 but in a different order. What I want to know is that what if the best way so that when the user is creating exam 2, he can open up something and be able to copy the questions and answers from exam 1 into exam 2 when he wants to do that? I was thinking using a second database (a backup database) to store all questions from exam 1 and then somehow be able to copy some of these questions and answers from exam 1 into exam 2 by one question at a time. The reason I am thinking of using a backup Database is because I want all of the details to be stored in the proper database after everything is finished (if power goes out or router is turned off during the middle of creating exams, I do not want my proper database to store in hald the data so thats why I want to store it in a backup database and only store it in full database after everything is complete) The layout of my questions and answers is that a question is in a textarea and the answers are from A -Z button where the user can select as many buttons as they wish? Thanks
1
11,702,088
07/28/2012 14:59:07
1,348,905
04/21/2012 22:57:41
87
20
Javascript Redirect with SetTimout Not Working
Can't seem to get this javascript redirect to work? Suggestions? Should I maybe do it with a meta refresh and how? // If we have a successful location update function onGeoSuccess(event) { document.getElementById("Latitude").value = event.coords.latitude; document.getElementById("Longitude").value = event.coords.longitude; document.getElementById("location").href = "track.cfm?track=s&Lat=" + event.coords.latitude + "&Long=" + event.coords.longitude; var redirectUrl = "track.cfm?track=s&Lat=" + event.coords.latitude + "&Long=" + event.coords.longitude; } // If something has gone wrong with the geolocation request function onGeoError(event) { alert("Error code " + event.code + ". " + event.message); } function redirect() { window.location = redirectUrl; } setTimeout(redirect,15000);
javascript
gps
null
null
null
null
open
Javascript Redirect with SetTimout Not Working === Can't seem to get this javascript redirect to work? Suggestions? Should I maybe do it with a meta refresh and how? // If we have a successful location update function onGeoSuccess(event) { document.getElementById("Latitude").value = event.coords.latitude; document.getElementById("Longitude").value = event.coords.longitude; document.getElementById("location").href = "track.cfm?track=s&Lat=" + event.coords.latitude + "&Long=" + event.coords.longitude; var redirectUrl = "track.cfm?track=s&Lat=" + event.coords.latitude + "&Long=" + event.coords.longitude; } // If something has gone wrong with the geolocation request function onGeoError(event) { alert("Error code " + event.code + ". " + event.message); } function redirect() { window.location = redirectUrl; } setTimeout(redirect,15000);
0
1,045,617
06/25/2009 18:57:13
127,776
06/23/2009 18:45:59
5
1
ASP .NET - Setting the value of a DetailsView TextBox
I am attempting to use the code-behind (Page_Load or PreRender) to set a date-time textbox in a DetailsView so that it defaults to a current date-time. What I have attempted is (one of many variations): protected void DetailsView2_PreRender(object sender, EventArgs e) { ((TextBox)DetailsView2.FindControl("date_time")).Text = DateTime.Now.ToString("d"); } But all that I get is a 'NullReferenceException' error. What I am doing wrong?
asp
.net
c#
null
null
null
open
ASP .NET - Setting the value of a DetailsView TextBox === I am attempting to use the code-behind (Page_Load or PreRender) to set a date-time textbox in a DetailsView so that it defaults to a current date-time. What I have attempted is (one of many variations): protected void DetailsView2_PreRender(object sender, EventArgs e) { ((TextBox)DetailsView2.FindControl("date_time")).Text = DateTime.Now.ToString("d"); } But all that I get is a 'NullReferenceException' error. What I am doing wrong?
0
6,239,530
06/04/2011 21:31:54
760,538
05/19/2011 07:21:57
1
0
supporting multiple screen sizes in android
Hi I'm new to android world.Iam working on an application that supports multiple screen sizes i did as explained here http://developer.android.com/guide/practices/screens_support.html#screen-independence . I didn't create different xmls for each screen size. But when I tested it on android 3 emulator it appears in small part of the screen. So I think that the size specified for my application on the emulator is small so my widgets are not filling the whole screen as I want. Can I control that size of my application on the emulator?
android
screen-size
null
null
null
null
open
supporting multiple screen sizes in android === Hi I'm new to android world.Iam working on an application that supports multiple screen sizes i did as explained here http://developer.android.com/guide/practices/screens_support.html#screen-independence . I didn't create different xmls for each screen size. But when I tested it on android 3 emulator it appears in small part of the screen. So I think that the size specified for my application on the emulator is small so my widgets are not filling the whole screen as I want. Can I control that size of my application on the emulator?
0
9,836,220
03/23/2012 08:46:18
1,163,486
01/22/2012 13:33:15
8
0
AAC-LC format and RTP
I'm trying to encode AAC-LC data packed in 3gpp to RTP. I've gone through rfc 3640 but I still don't know exactly where to start from. What will I find in the AAC data exactly ? If I'm not wrong , the first 40 bytes will be the MP4 header, but what comes afterwards and where can I find It's definition ? In order to build the RTP payload, I have to include the AU headers sections, but I don't know If they are already included in the AAC data and I can't find it anywhere. Once I have taken out the mp4 header I have the following data: 94 39 E5 69 55 E7 98 0C 82 85 4A 19 08 00 45 00 or in bits 10010100 00111001 11100101 01101001 01010101 11100111 10011000 00001100... Is this the AU header ? How do I interpret this data? An another question, what is the relation between AAC-LC and AAC-lbr...I mean, I know the first one stands for low complexity and the second one for low bit rate, but is it the same ? one includes the other ? Thanks in advance, I'm really new to AAC and I'm quite lost !
rtp
aac
null
null
null
null
open
AAC-LC format and RTP === I'm trying to encode AAC-LC data packed in 3gpp to RTP. I've gone through rfc 3640 but I still don't know exactly where to start from. What will I find in the AAC data exactly ? If I'm not wrong , the first 40 bytes will be the MP4 header, but what comes afterwards and where can I find It's definition ? In order to build the RTP payload, I have to include the AU headers sections, but I don't know If they are already included in the AAC data and I can't find it anywhere. Once I have taken out the mp4 header I have the following data: 94 39 E5 69 55 E7 98 0C 82 85 4A 19 08 00 45 00 or in bits 10010100 00111001 11100101 01101001 01010101 11100111 10011000 00001100... Is this the AU header ? How do I interpret this data? An another question, what is the relation between AAC-LC and AAC-lbr...I mean, I know the first one stands for low complexity and the second one for low bit rate, but is it the same ? one includes the other ? Thanks in advance, I'm really new to AAC and I'm quite lost !
0
8,487,673
12/13/2011 10:33:06
1,029,944
11/04/2011 15:18:02
492
34
How would you make this Python Dictionary thread-safe?
I have a Web Server running in `Python`. The server is private, so i only expect around 20 users to connect to it. The server is multi-threaded (8 cores at the moment, so 8 threads I guessed). When requests come in, I am able to identify the users. On some queries, I need to update a simple `dictionary` of the form **username -> Boolean**. How could I make this one thread safe ?
python
multithreading
null
null
null
null
open
How would you make this Python Dictionary thread-safe? === I have a Web Server running in `Python`. The server is private, so i only expect around 20 users to connect to it. The server is multi-threaded (8 cores at the moment, so 8 threads I guessed). When requests come in, I am able to identify the users. On some queries, I need to update a simple `dictionary` of the form **username -> Boolean**. How could I make this one thread safe ?
0
6,067,335
05/20/2011 04:01:35
553,739
12/25/2010 08:13:52
207
4
javascript use for getting element
<li class="even"> <a href="www.google.com">Click here </a> </li> I want to change anchor tag text "Click here" using javascript. How can i accomplish this ? I do not want to use jquery.
javascript
null
null
null
null
null
open
javascript use for getting element === <li class="even"> <a href="www.google.com">Click here </a> </li> I want to change anchor tag text "Click here" using javascript. How can i accomplish this ? I do not want to use jquery.
0
10,583,770
05/14/2012 12:55:28
617,554
02/15/2011 10:05:53
1
0
Copying List to Map in C++
****I an new to C++ I need to know how to copy form the list to Map in C++. Please provide the code snippet.****
c++
null
null
null
null
05/14/2012 13:39:41
not a real question
Copying List to Map in C++ === ****I an new to C++ I need to know how to copy form the list to Map in C++. Please provide the code snippet.****
1
11,197,789
06/25/2012 21:42:34
1,430,675
06/01/2012 12:24:23
1
0
decision tree error in SPSS is too big
I implement decision trees in SPSS using the CRT Growing Method. Iam using the datasets COCOMO81, NASA93, Desharnais, Maxwell. The values I get for estimate and std error in the table of Risk are too big like thousands. What can i do for it? I tried to change the nodes for parent node and child nodes but again I have the same problem. Please help me.
spss
null
null
null
null
06/25/2012 21:55:07
off topic
decision tree error in SPSS is too big === I implement decision trees in SPSS using the CRT Growing Method. Iam using the datasets COCOMO81, NASA93, Desharnais, Maxwell. The values I get for estimate and std error in the table of Risk are too big like thousands. What can i do for it? I tried to change the nodes for parent node and child nodes but again I have the same problem. Please help me.
2
11,610,657
07/23/2012 10:22:18
802,105
06/16/2011 18:47:09
12
0
Java Servlet Hosting
I want to find a hosting service for a small Java servlet (running on Tomcat, no database required). Any suggestions or anything I need to be careful about? Also: The only thing I need to upload to the hosting service is the .war file? thanks a lot.
java
servlets
hosting
null
null
07/23/2012 10:45:49
off topic
Java Servlet Hosting === I want to find a hosting service for a small Java servlet (running on Tomcat, no database required). Any suggestions or anything I need to be careful about? Also: The only thing I need to upload to the hosting service is the .war file? thanks a lot.
2
5,227,565
03/08/2011 02:14:21
228,521
12/10/2009 05:19:51
1
0
How do I find .bash_profile and add to my shell's initialization file?
I am trying to upgrade ruby using rvm. On the pragmatic site (http://pragmaticstudio.com/blog/2010/9/23/install-rails-ruby-mac), it says: `The important part is to add the following line to the end of your shell's initialization file (.bash_profile): [[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm"` How do I do this? Where is this initialization file? Please help
ruby
upgrade
null
null
null
03/08/2011 03:19:48
off topic
How do I find .bash_profile and add to my shell's initialization file? === I am trying to upgrade ruby using rvm. On the pragmatic site (http://pragmaticstudio.com/blog/2010/9/23/install-rails-ruby-mac), it says: `The important part is to add the following line to the end of your shell's initialization file (.bash_profile): [[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm"` How do I do this? Where is this initialization file? Please help
2
7,006,611
08/10/2011 06:15:50
533,399
12/07/2010 08:52:27
3,136
236
Looking for a funny and intelligent C code depicting this situation
As a content for a blog entry, I am looking for a simple C program which has following behaviour: Consider a situation,I am a programmer, participating in a programming competition and solving a problem given. I write down a program, and just before the submission time, 1-2 lines of my code seem uncertain to me, so I comment them out, and submit the program. When the program is evaluated,in the result, the program fails for a specific input, and sadly it would have succeeded had I NOT COMMENTED those 2 lines. So, I am looking for a small program, which has a scope of this type of confusion, and commenting/uncommenting just 1-2 lines makes the difference. Please forgive if the question does not belong here,I found stackoverflow to be the best platform to ask this though.
c
null
null
null
null
08/10/2011 06:25:44
too localized
Looking for a funny and intelligent C code depicting this situation === As a content for a blog entry, I am looking for a simple C program which has following behaviour: Consider a situation,I am a programmer, participating in a programming competition and solving a problem given. I write down a program, and just before the submission time, 1-2 lines of my code seem uncertain to me, so I comment them out, and submit the program. When the program is evaluated,in the result, the program fails for a specific input, and sadly it would have succeeded had I NOT COMMENTED those 2 lines. So, I am looking for a small program, which has a scope of this type of confusion, and commenting/uncommenting just 1-2 lines makes the difference. Please forgive if the question does not belong here,I found stackoverflow to be the best platform to ask this though.
3
9,999,322
04/03/2012 18:37:27
1,148,439
01/13/2012 20:14:59
8
0
How to run long running report in the background
Oracle Application server 10g I need to run the long running reports in the background because while the report is running the cursor is loading and the control doesn't return to the user this feature exist in oracle 6i by set the following parameter RUN_PRODUCT( REPORTS, 'r_1', ASYNCHRONOUS, RUNTIME, FILESYSTEM, pl_id, NULL); How can I accomplish the same in OAS 10g?
oracle10g
oas
null
null
null
null
open
How to run long running report in the background === Oracle Application server 10g I need to run the long running reports in the background because while the report is running the cursor is loading and the control doesn't return to the user this feature exist in oracle 6i by set the following parameter RUN_PRODUCT( REPORTS, 'r_1', ASYNCHRONOUS, RUNTIME, FILESYSTEM, pl_id, NULL); How can I accomplish the same in OAS 10g?
0
10,778,659
05/28/2012 02:09:24
1,328,356
04/12/2012 06:45:41
82
1
Creating a variable selector with jQuery?
Let me clarify. I have a giant loop which parses XML, places markers on a google map accordingly, and makes hidden divs, one per marker, which contain info relating to that marker. The loop also places on each marker an event which opens an info window. The info window contains a button which must show that particular marker's div. But I'm uncertain of how to do this. Here is most of the code below-- I have omitted the irrelevant earlier portions of the loop, and focused on the area where I am trying to attach a click event to each new button. But I am uncertain of how to do this. See the comments in the code for a complete understanding. $(xml).find('sample').each(function(){ var id = $(this).find('id long').text(); /*there was code here which creates the other variables you see below*/ var infoPage = '<div style="display:none; position:absolute; top:0px; bottom:0px; width:100%;" id="' + id +'Info">' + '<p>Number: ' + number + '</p>' + '<p>ID: ' + id + '</p>' + '<p>Rock type: ' + rockType + '</p>' + '<p>Minerals: ' + minerals + '</p>' + '<p>Regions: ' + regions + '</p>' + '<p>Latitude: ' + latitude + '</p>' + '<p>Longitude: ' + longitude + '</p>' + '</div>'; //there was code here which inserts this div into the page //this line creates the button which appears inside the info window var contentString = '<a href="" data-role="button" id="' + id + '">' + number + '</a>'; //this line creates the info window var infowindow = new google.maps.InfoWindow({ content: contentString }); /*Here is where I hit a problem. I now need to construct a line of jQuery which attaches to this particular button a click event. But it needs to do it for every new button in the loop, so that each button's click event is unique and opens its personal div. How do I construct a selector which will change with the loop to accomplish the desired result?*/ $('#'+id).click(function(){ $('#'+id+'Info').show(); }); google.maps.event.addListener(marker, 'click', function(){ infowindow.open(map,marker); }); });
jquery
null
null
null
null
null
open
Creating a variable selector with jQuery? === Let me clarify. I have a giant loop which parses XML, places markers on a google map accordingly, and makes hidden divs, one per marker, which contain info relating to that marker. The loop also places on each marker an event which opens an info window. The info window contains a button which must show that particular marker's div. But I'm uncertain of how to do this. Here is most of the code below-- I have omitted the irrelevant earlier portions of the loop, and focused on the area where I am trying to attach a click event to each new button. But I am uncertain of how to do this. See the comments in the code for a complete understanding. $(xml).find('sample').each(function(){ var id = $(this).find('id long').text(); /*there was code here which creates the other variables you see below*/ var infoPage = '<div style="display:none; position:absolute; top:0px; bottom:0px; width:100%;" id="' + id +'Info">' + '<p>Number: ' + number + '</p>' + '<p>ID: ' + id + '</p>' + '<p>Rock type: ' + rockType + '</p>' + '<p>Minerals: ' + minerals + '</p>' + '<p>Regions: ' + regions + '</p>' + '<p>Latitude: ' + latitude + '</p>' + '<p>Longitude: ' + longitude + '</p>' + '</div>'; //there was code here which inserts this div into the page //this line creates the button which appears inside the info window var contentString = '<a href="" data-role="button" id="' + id + '">' + number + '</a>'; //this line creates the info window var infowindow = new google.maps.InfoWindow({ content: contentString }); /*Here is where I hit a problem. I now need to construct a line of jQuery which attaches to this particular button a click event. But it needs to do it for every new button in the loop, so that each button's click event is unique and opens its personal div. How do I construct a selector which will change with the loop to accomplish the desired result?*/ $('#'+id).click(function(){ $('#'+id+'Info').show(); }); google.maps.event.addListener(marker, 'click', function(){ infowindow.open(map,marker); }); });
0
8,179,468
11/18/2011 08:11:16
1,053,364
11/18/2011 08:03:17
1
0
Neo4J as OLAP performance benchmark
I would like to know if Neo4J can be used as OLAP. The search says it is great tool as OLTP. However there are no proven case studies as OLAP. Also only Jasper 1st version of connector with Neo4J. I have not seen any connectors from other BI providers. If there are any BI providers that have auto connector with Neo4J please share.
olap
neo4j
null
null
null
null
open
Neo4J as OLAP performance benchmark === I would like to know if Neo4J can be used as OLAP. The search says it is great tool as OLTP. However there are no proven case studies as OLAP. Also only Jasper 1st version of connector with Neo4J. I have not seen any connectors from other BI providers. If there are any BI providers that have auto connector with Neo4J please share.
0
6,121,060
05/25/2011 07:38:13
461,972
09/29/2010 16:06:34
558
56
Activity in android
I load lots of contents(images,text,etc..) from server and displayed it on the listview in the activity-A.on clicking the any one row of the listview,i finish the activity and release all the variables(to avoid memory problems) and open another activity-B and display the content in detailed format.suppose when hitting back from activity-B ,obviously it again load content from the server.is there any other solution instead of finishing activity to avoid again loading from the server but it should not come up with the memory problems?
android
null
null
null
null
null
open
Activity in android === I load lots of contents(images,text,etc..) from server and displayed it on the listview in the activity-A.on clicking the any one row of the listview,i finish the activity and release all the variables(to avoid memory problems) and open another activity-B and display the content in detailed format.suppose when hitting back from activity-B ,obviously it again load content from the server.is there any other solution instead of finishing activity to avoid again loading from the server but it should not come up with the memory problems?
0
6,332,662
06/13/2011 15:38:00
796,201
06/13/2011 15:38:00
1
0
Crash log analysis
I have a customer who has submitted to me about ten crash logs, and I have symbolized the logs in XCode. I just have no idea what this means. Please help me analyze this crash log: Incident Identifier: 0E7CF1DF-B79C-4AE1-9FB3-7F13D916C844 CrashReporter Key: 0d530a5efc7ff5fff35f75efe047862f1e3ec068 Hardware Model: iPad1,1 Process: MyStocks [292] Path: /var/mobile/Applications/B120B24C-1B9A-4077-AED3-1364779DBB84/MyStocks.app/MyStocks Identifier: MyStocks Version: ??? (???) Code Type: ARM (Native) Parent Process: launchd [1] Date/Time: 2011-05-28 12:12:41.766 -0400 OS Version: iPhone OS 4.3.3 (8J3) Report Version: 104 Exception Type: EXC_CRASH (SIGABRT) Exception Codes: 0x00000000, 0x00000000 Crashed Thread: 0 Thread 0 name: Dispatch queue: com.apple.main-thread Thread 0 Crashed: 0 libsystem_kernel.dylib 0x32fa3a1c __pthread_kill + 8 1 libsystem_c.dylib 0x362063b4 pthread_kill + 52 2 libsystem_c.dylib 0x361febf8 abort + 72 3 libstdc++.6.dylib 0x30e7da64 __gnu_cxx::__verbose_terminate_handler() + 376 4 libobjc.A.dylib 0x32dcb06c _objc_terminate + 104 5 libstdc++.6.dylib 0x30e7be36 __cxxabiv1::__terminate(void (*)()) + 46 6 libstdc++.6.dylib 0x30e7be8a std::terminate() + 10 7 libstdc++.6.dylib 0x30e7bf5a __cxa_throw + 78 8 libobjc.A.dylib 0x32dc9c84 objc_exception_throw + 64 9 CoreFoundation 0x30adc1b8 -[NSObject(NSObject) doesNotRecognizeSelector:] + 96 10 CoreFoundation 0x30adb642 ___forwarding___ + 502 11 CoreFoundation 0x30a52178 _CF_forwarding_prep_0 + 40 12 MyStocks 0x0000cd28 +[YahooFinanceAPI stockIsValid:] (YahooFinanceAPI.m:31) 13 MyStocks 0x0000bb20 -[StockText check] (StockText.m:51) 14 Foundation 0x35e0f7c6 __NSFireTimer + 130 15 CoreFoundation 0x30aafa40 __CFRUNLOOP_IS_CALLING_OUT_TO_A_TIMER_CALLBACK_FUNCTION__ + 8 16 CoreFoundation 0x30ab1ec4 __CFRunLoopDoTimer + 844 17 CoreFoundation 0x30ab283e __CFRunLoopRun + 1082 18 CoreFoundation 0x30a42ebc CFRunLoopRunSpecific + 224 19 CoreFoundation 0x30a42dc4 CFRunLoopRunInMode + 52 20 GraphicsServices 0x36188418 0x36184000 + 17432 21 GraphicsServices 0x361884c4 0x36184000 + 17604 22 UIKit 0x30f5ed62 -[UIApplication _run] + 398 23 UIKit 0x30f5c800 UIApplicationMain + 664 24 MyStocks 0x00002c88 main (main.m:14) 25 MyStocks 0x00002c08 start + 44 Thread 1 name: Dispatch queue: com.apple.libdispatch-manager Thread 1: 0 libsystem_kernel.dylib 0x32fa4fbc kevent + 24 1 libdispatch.dylib 0x32fcf032 _dispatch_mgr_invoke + 706 2 libdispatch.dylib 0x32fd003a _dispatch_queue_invoke + 86 3 libdispatch.dylib 0x32fcf5ea _dispatch_worker_thread2 + 186 4 libsystem_c.dylib 0x3620758a _pthread_wqthread + 258 5 libsystem_c.dylib 0x36207bbc start_wqthread + 0 Thread 2 name: WebThread Thread 2: 0 libsystem_kernel.dylib 0x32fa1c00 mach_msg_trap + 20 1 libsystem_kernel.dylib 0x32fa1758 mach_msg + 44 2 CoreFoundation 0x30ab02b8 __CFRunLoopServiceMachPort + 88 3 CoreFoundation 0x30ab2562 __CFRunLoopRun + 350 4 CoreFoundation 0x30a42ebc CFRunLoopRunSpecific + 224 5 CoreFoundation 0x30a42dc4 CFRunLoopRunInMode + 52 6 WebCore 0x336c827e RunWebThread(void*) + 382 7 libsystem_c.dylib 0x3620630a _pthread_start + 242 8 libsystem_c.dylib 0x36207bb4 thread_start + 0 Thread 3: 0 libsystem_kernel.dylib 0x32fa1c00 mach_msg_trap + 20 1 libsystem_kernel.dylib 0x32fa1758 mach_msg + 44 2 CoreFoundation 0x30ab02b8 __CFRunLoopServiceMachPort + 88 3 CoreFoundation 0x30ab2562 __CFRunLoopRun + 350 4 CoreFoundation 0x30a42ebc CFRunLoopRunSpecific + 224 5 CoreFoundation 0x30a42dc4 CFRunLoopRunInMode + 52 6 Foundation 0x35da97f6 +[NSURLConnection(NSURLConnectionReallyInternal) _resourceLoadLoop:] + 206 7 Foundation 0x35d9c382 -[NSThread main] + 38 8 Foundation 0x35e0e5c6 __NSThread__main__ + 966 9 libsystem_c.dylib 0x3620630a _pthread_start + 242 10 libsystem_c.dylib 0x36207bb4 thread_start + 0 Thread 4 name: com.apple.CFSocket.private Thread 4: 0 libsystem_kernel.dylib 0x32fa3c60 __select + 20 1 CoreFoundation 0x30ab58f2 __CFSocketManager + 582 2 libsystem_c.dylib 0x3620630a _pthread_start + 242 3 libsystem_c.dylib 0x36207bb4 thread_start + 0 Thread 5: 0 libsystem_kernel.dylib 0x32fa43ec __workq_kernreturn + 8 1 libsystem_c.dylib 0x362076d8 _pthread_wqthread + 592 2 libsystem_c.dylib 0x36207bbc start_wqthread + 0 Thread 0 crashed with ARM Thread State: r0: 0x00000000 r1: 0x00000000 r2: 0x00000001 r3: 0x00000000 r4: 0x3fb8e48c r5: 0x00000006 r6: 0x002e46ec r7: 0x2fdfe7f8 r8: 0x00245f70 r9: 0x00000065 r10: 0x3f646b98 r11: 0x00000000 ip: 0x00000148 sp: 0x2fdfe7ec lr: 0x368d23bb pc: 0x337e1a1c cpsr: 0x00000010 Binary Images: 0x1000 - 0xf2fff +MyStocks armv7 <5a9bc2940092fcb19620e8be465b8847> /var/mobile/Applications/B120B24C-1B9A-4077-AED3-1364779DBB84/MyStocks.app/MyStocks 0x2fe00000 - 0x2fe25fff dyld armv7 <bb9bfc7d242331d29a79adf7ef7aaa18> /usr/lib/dyld 0x30e06000 - 0x310f3fff libLAPACK.dylib armv7 <b855d60dac01310495453bddfd004f0d> /System/Library/Frameworks/Accelerate.framework/Frameworks/vecLib.framework/libLAPACK.dylib 0x31140000 - 0x31145fff liblaunch.dylib armv7 <f5ccc8234aea3ebd9a88bd37f0fa23ae> /usr/lib/system/liblaunch.dylib 0x3145a000 - 0x3145bfff libsystem_network.dylib armv7 <39bf0f48bd8539169a77f8f61cdcd4c9> /usr/lib/system/libsystem_network.dylib 0x31706000 - 0x31706fff libdnsinfo.dylib armv7 <21415179ffa03f949fa8cc851c6c31c7> /usr/lib/system/libdnsinfo.dylib 0x31716000 - 0x31723fff libbsm.0.dylib armv7 <0a1e2bb78d5138419ecad8ba0fe42fdd> /usr/lib/libbsm.0.dylib 0x31724000 - 0x31725fff libsystem_blocks.dylib armv7 <ccc041df3de73eafb7a59e74cdb1702b> /usr/lib/system/libsystem_blocks.dylib 0x31797000 - 0x317d9fff CoreAudio armv7 <c972fd5f8e89333ca680b9a33587f896> /System/Library/Frameworks/CoreAudio.framework/CoreAudio 0x31a71000 - 0x31a71fff Accelerate armv7 <7d5ad465049136afaa1f0d89aac600bc> /System/Library/Frameworks/Accelerate.framework/Accelerate 0x31bae000 - 0x31c57fff libxml2.2.dylib armv7 <5538d3f2c7d83b88b06168488fe6326b> /usr/lib/libxml2.2.dylib 0x31c58000 - 0x31c63fff libz.1.dylib armv7 <ac706bee36593dc683fd5a96a389d72e> /usr/lib/libz.1.dylib 0x31db6000 - 0x31e75fff CFNetwork armv7 <b09e0d53de9f3bc8bde494780f3cdd4f> /System/Library/Frameworks/CFNetwork.framework/CFNetwork 0x31e76000 - 0x31e78fff libgcc_s.1.dylib armv7 <a2631ac302f4310dae8367939e16b7c2> /usr/lib/libgcc_s.1.dylib 0x31e79000 - 0x31e96fff libsystem_info.dylib armv7 <48016be86e3f3cd9aeee1c6590e1ac6f> /usr/lib/system/libsystem_info.dylib 0x3219d000 - 0x321a1fff libGFXShared.dylib armv7 <a0772a32cd8b3b9194bb0c29807c1c5b> /System/Library/Frameworks/OpenGLES.framework/libGFXShared.dylib 0x321b0000 - 0x3220ffff libBLAS.dylib armv7 <0b36b2272aa33a8c9aa22d99c89d7189> /System/Library/Frameworks/Accelerate.framework/Frameworks/vecLib.framework/libBLAS.dylib 0x322de000 - 0x322ecfff OpenGLES armv7 <5a76beaeaa013f0cbf16e5cb154598ab> /System/Library/Frameworks/OpenGLES.framework/OpenGLES 0x32348000 - 0x3234ffff libbz2.1.0.dylib armv7 <0a082e1d475432959ba93aa3dbf7fb31> /usr/lib/libbz2.1.0.dylib 0x32350000 - 0x3295bfff WebCore armv7 <07941e59d0a33f94802c16c76238fddf> /System/Library/PrivateFrameworks/WebCore.framework/WebCore 0x32a50000 - 0x32a7ffff SystemConfiguration armv7 <1d73b8a159363f96bb9c039655c5eae6> /System/Library/Frameworks/SystemConfiguration.framework/SystemConfiguration 0x32c4c000 - 0x32d39fff libiconv.2.dylib armv7 <f4146ce07e3031ea8a81fa5516fd77d0> /usr/lib/libiconv.2.dylib 0x32d49000 - 0x32d4dfff libcache.dylib armv7 <d2f7fd2a352b3cd59c564be34b53cf80> /usr/lib/system/libcache.dylib 0x32d4e000 - 0x32d53fff MobileKeyBag armv7 <8c35c090bc373cb181fc26b961b8dba5> /System/Library/PrivateFrameworks/MobileKeyBag.framework/MobileKeyBag 0x32d54000 - 0x32d54fff vecLib armv7 <0c60cd0a60f43d2791d36cb357d30e3c> /System/Library/Frameworks/Accelerate.framework/Frameworks/vecLib.framework/vecLib 0x32d7f000 - 0x32d82fff libmacho.dylib armv7 <43311c113a9d3182b7d007129819f029> /usr/lib/system/libmacho.dylib 0x32eac000 - 0x33239fff UIKit armv7 <c271b78464d93cb7bf28c6e49df293ba> /System/Library/Frameworks/UIKit.framework/UIKit 0x3323a000 - 0x3323dfff IOSurface armv7 <ad50e71624583d06b891344d832f9b08> /System/Library/PrivateFrameworks/IOSurface.framework/IOSurface 0x332b5000 - 0x3339afff CoreFoundation armv7 <a8444f997111304c9571b3ff974b769c> /System/Library/Frameworks/CoreFoundation.framework/CoreFoundation 0x333e6000 - 0x33425fff libSystem.B.dylib armv7 <33dcf9a403ae3fd5971d6030ada2fcab> /usr/lib/libSystem.B.dylib 0x3342f000 - 0x33431fff libAccessibility.dylib armv7 <d55f1553d14831a2a5435ae27ef75ef4> /usr/lib/libAccessibility.dylib 0x33485000 - 0x33487fff IOMobileFramebuffer armv7 <683f321680763e519d61541170ba2133> /System/Library/PrivateFrameworks/IOMobileFramebuffer.framework/IOMobileFramebuffer 0x334ce000 - 0x3357ffff WebKit armv7 <eb9a0d69c64b3127b2bffd71641add3b> /System/Library/PrivateFrameworks/WebKit.framework/WebKit 0x335e1000 - 0x33702fff CoreGraphics armv7 <65f6c8701b563542820a26b0dfc4f6a4> /System/Library/Frameworks/CoreGraphics.framework/CoreGraphics 0x33771000 - 0x33771fff libsystem_sandbox.dylib armv7 <f47c01d627853b328e088b3fdd08e87d> /usr/lib/system/libsystem_sandbox.dylib 0x3377a000 - 0x337cffff libvDSP.dylib armv7 <0221caba81a235c5a896a835e2aac047> /System/Library/Frameworks/Accelerate.framework/Frameworks/vecLib.framework/libvDSP.dylib 0x337d0000 - 0x337e7fff libsystem_kernel.dylib armv7 <a06ec84e53bf32098b63c0caebdb45b6> /usr/lib/system/libsystem_kernel.dylib 0x3392a000 - 0x3392bfff libdyld.dylib armv7 <41a7b5e5d9983449ab33affed0f635ad> /usr/lib/system/libdyld.dylib 0x33a3b000 - 0x33a70fff AddressBook armv7 <3f2071a77bc134cd82065eef90d4082f> /System/Library/Frameworks/AddressBook.framework/AddressBook 0x33a84000 - 0x33b9efff libicucore.A.dylib armv7 <bada0c2725bb31a483d5adf9aaf1f8df> /usr/lib/libicucore.A.dylib 0x33cdf000 - 0x33d1bfff libGLImage.dylib armv7 <9d97699e44ee3651ba4ac37e5adec35b> /System/Library/Frameworks/OpenGLES.framework/libGLImage.dylib 0x33e2d000 - 0x33e9cfff ProofReader armv7 <6d843c6aecdd37ae84baa40af8ad7e65> /System/Library/PrivateFrameworks/ProofReader.framework/ProofReader 0x33e9d000 - 0x33ea6fff CoreVideo armv7 <ea847e6dba2d36b1826b255c73b39539> /System/Library/Frameworks/CoreVideo.framework/CoreVideo 0x33fb0000 - 0x33fbdfff libdispatch.dylib armv7 <9a0511ad5ebc3db898f1f49ed1a73d34> /usr/lib/system/libdispatch.dylib 0x340a5000 - 0x340d8fff AppSupport armv7 <0217468bd9f839229a47910b7816b3d5> /System/Library/PrivateFrameworks/AppSupport.framework/AppSupport 0x340dc000 - 0x35b2afff TextInput armv7 <f242acc046073c1598195dd26fd8ad6f> /System/Library/PrivateFrameworks/TextInput.framework/TextInput 0x35b2b000 - 0x35b2bfff libCVMSPluginSupport.dylib armv7 <42d8aa2a31843a6e8bfff745644a7ba5> /System/Library/Frameworks/OpenGLES.framework/libCVMSPluginSupport.dylib 0x35b2c000 - 0x35c4bfff Foundation armv7 <09ff368178c5321c9715b9c8d491d53f> /System/Library/Frameworks/Foundation.framework/Foundation 0x35c61000 - 0x35c67fff liblockdown.dylib armv7 <14c89b7346433c1f8675f454531f6ca3> /usr/lib/liblockdown.dylib 0x35d27000 - 0x35debfff libobjc.A.dylib armv7 <6b51e76fde9f381bb7b3bc5badbfee3a> /usr/lib/libobjc.A.dylib 0x35dec000 - 0x35e24fff IOKit armv7 <80ae313ad69d3363935c88e51a11862d> /System/Library/Frameworks/IOKit.framework/Versions/A/IOKit 0x35e25000 - 0x35f51fff libmecabra.dylib armv7 <113de5f9858c32b8b158bfdc68042a97> /usr/lib/libmecabra.dylib 0x35f72000 - 0x35f91fff Bom armv7 <b178e3efb4d733c694bd5a55e57a314f> /System/Library/PrivateFrameworks/Bom.framework/Bom 0x3615c000 - 0x36168fff SpringBoardServices armv7 <c68262667ac8397a949ce4e92dfec7db> /System/Library/PrivateFrameworks/SpringBoardServices.framework/SpringBoardServices 0x36184000 - 0x36190fff GraphicsServices armv7 <ff78a9636e933f0dbd222f8d26209788> /System/Library/PrivateFrameworks/GraphicsServices.framework/GraphicsServices 0x3654e000 - 0x36552fff AssetsLibraryServices armv7 <e1cbfe599c96369ca4bdb0dd99d3cd9f> /System/Library/PrivateFrameworks/AssetsLibraryServices.framework/AssetsLibraryServices 0x36561000 - 0x365abfff libstdc++.6.dylib armv7 <b2cac408951c3f3c9ba3cf563e54ce81> /usr/lib/libstdc++.6.dylib 0x3661a000 - 0x3662ffff libresolv.9.dylib armv7 <e92cfbb83f7b330db19181e797bb3f7b> /usr/lib/libresolv.9.dylib 0x367ef000 - 0x3689efff QuartzCore armv7 <ef9632c9781f3101916b65e9faae1579> /System/Library/Frameworks/QuartzCore.framework/QuartzCore 0x3689f000 - 0x36920fff libsystem_c.dylib armv7 <a7077267b6743ed3bbdd86d4380c75d9> /usr/lib/system/libsystem_c.dylib 0x3698b000 - 0x3698cfff libremovefile.dylib armv7 <e8858a499d663e6a9e3c188521273cc1> /usr/lib/system/libremovefile.dylib 0x369f7000 - 0x369f8fff TextInput_fr armv7 <df896624a716399f877087d35f6c6d86> /System/Library/TextInput/TextInput_fr.bundle/TextInput_fr 0x36bfd000 - 0x36c02fff libnotify.dylib armv7 <9d7198e91de9386a9e5ea43608a66a57> /usr/lib/system/libnotify.dylib 0x36c09000 - 0x36c4ffff CoreTelephony armv7 <af7d1e770e5a3ffd8834a57fb5d40557> /System/Library/Frameworks/CoreTelephony.framework/CoreTelephony 0x36cbb000 - 0x36cf3fff libCGFreetype.A.dylib armv7 <ccea634795153164a681f0f311f4461d> /System/Library/Frameworks/CoreGraphics.framework/Resources/libCGFreetype.A.dylib 0x36cf4000 - 0x36cf5fff CoreSurface armv7 <7b83cd757da73e6e826693c29296d3fa> /System/Library/PrivateFrameworks/CoreSurface.framework/CoreSurface 0x36d0d000 - 0x36da2fff ImageIO armv7 <d520e3241d1130e8ac1375ee0f2c1095> /System/Library/Frameworks/ImageIO.framework/ImageIO 0x36ded000 - 0x36df4fff AggregateDictionary armv7 <ab9777b39e8e3026ad64dc90323cad7e> /System/Library/PrivateFrameworks/AggregateDictionary.framework/AggregateDictionary 0x36e84000 - 0x36eadfff MobileCoreServices armv7 <57fef84bdc17301d8bf53ba0fb967fe6> /System/Library/Frameworks/MobileCoreServices.framework/MobileCoreServices 0x36efd000 - 0x37001fff JavaScriptCore armv7 <61a94142e2d23dafa2964190dd46e9e3> /System/Library/PrivateFrameworks/JavaScriptCore.framework/JavaScriptCore 0x37002000 - 0x37039fff Security armv7 <6599f42a910b3b31a0e1d98c883d61cb> /System/Library/Frameworks/Security.framework/Security 0x37058000 - 0x37071fff libRIP.A.dylib armv7 <4825c3e392983aba947eca06555e4480> /System/Library/Frameworks/CoreGraphics.framework/Resources/libRIP.A.dylib 0x3716a000 - 0x3716ffff libsystem_dnssd.dylib armv7 <c7cfe523e2d73521abc01587313ef730> /usr/lib/system/libsystem_dnssd.dylib 0x371ba000 - 0x371bcfff MobileInstallation armv7 <94b6d6c5d9883175af26764567528127> /System/Library/PrivateFrameworks/MobileInstallation.framework/MobileInstallation 0x37297000 - 0x372e8fff libsqlite3.dylib armv7 <8a41cc6a6d9332308bc415d27577fd24> /usr/lib/libsqlite3.dylib 0x3734c000 - 0x374a0fff AudioToolbox armv7 <6619c8c13f8d328e923e797fa8d0df23> /System/Library/Frameworks/AudioToolbox.framework/AudioToolbox 0x374a4000 - 0x374c4fff PrintKit armv7 <e5a01ca9083a36afacc08611a398e2ad> /System/Library/PrivateFrameworks/PrintKit.framework/PrintKit 0x374c5000 - 0x374cafff libcopyfile.dylib armv7 <e57c2b9054b831d9a37119baaa4947cb> /usr/lib/system/libcopyfile.dylib 0x37539000 - 0x37576fff CoreText armv7 <fb6a72faec2330c4b2cd33c2e9c59588> /System/Library/Frameworks/CoreText.framework/CoreText
iphone
ios
xcode
ipad
crash-reports
06/13/2011 19:15:22
too localized
Crash log analysis === I have a customer who has submitted to me about ten crash logs, and I have symbolized the logs in XCode. I just have no idea what this means. Please help me analyze this crash log: Incident Identifier: 0E7CF1DF-B79C-4AE1-9FB3-7F13D916C844 CrashReporter Key: 0d530a5efc7ff5fff35f75efe047862f1e3ec068 Hardware Model: iPad1,1 Process: MyStocks [292] Path: /var/mobile/Applications/B120B24C-1B9A-4077-AED3-1364779DBB84/MyStocks.app/MyStocks Identifier: MyStocks Version: ??? (???) Code Type: ARM (Native) Parent Process: launchd [1] Date/Time: 2011-05-28 12:12:41.766 -0400 OS Version: iPhone OS 4.3.3 (8J3) Report Version: 104 Exception Type: EXC_CRASH (SIGABRT) Exception Codes: 0x00000000, 0x00000000 Crashed Thread: 0 Thread 0 name: Dispatch queue: com.apple.main-thread Thread 0 Crashed: 0 libsystem_kernel.dylib 0x32fa3a1c __pthread_kill + 8 1 libsystem_c.dylib 0x362063b4 pthread_kill + 52 2 libsystem_c.dylib 0x361febf8 abort + 72 3 libstdc++.6.dylib 0x30e7da64 __gnu_cxx::__verbose_terminate_handler() + 376 4 libobjc.A.dylib 0x32dcb06c _objc_terminate + 104 5 libstdc++.6.dylib 0x30e7be36 __cxxabiv1::__terminate(void (*)()) + 46 6 libstdc++.6.dylib 0x30e7be8a std::terminate() + 10 7 libstdc++.6.dylib 0x30e7bf5a __cxa_throw + 78 8 libobjc.A.dylib 0x32dc9c84 objc_exception_throw + 64 9 CoreFoundation 0x30adc1b8 -[NSObject(NSObject) doesNotRecognizeSelector:] + 96 10 CoreFoundation 0x30adb642 ___forwarding___ + 502 11 CoreFoundation 0x30a52178 _CF_forwarding_prep_0 + 40 12 MyStocks 0x0000cd28 +[YahooFinanceAPI stockIsValid:] (YahooFinanceAPI.m:31) 13 MyStocks 0x0000bb20 -[StockText check] (StockText.m:51) 14 Foundation 0x35e0f7c6 __NSFireTimer + 130 15 CoreFoundation 0x30aafa40 __CFRUNLOOP_IS_CALLING_OUT_TO_A_TIMER_CALLBACK_FUNCTION__ + 8 16 CoreFoundation 0x30ab1ec4 __CFRunLoopDoTimer + 844 17 CoreFoundation 0x30ab283e __CFRunLoopRun + 1082 18 CoreFoundation 0x30a42ebc CFRunLoopRunSpecific + 224 19 CoreFoundation 0x30a42dc4 CFRunLoopRunInMode + 52 20 GraphicsServices 0x36188418 0x36184000 + 17432 21 GraphicsServices 0x361884c4 0x36184000 + 17604 22 UIKit 0x30f5ed62 -[UIApplication _run] + 398 23 UIKit 0x30f5c800 UIApplicationMain + 664 24 MyStocks 0x00002c88 main (main.m:14) 25 MyStocks 0x00002c08 start + 44 Thread 1 name: Dispatch queue: com.apple.libdispatch-manager Thread 1: 0 libsystem_kernel.dylib 0x32fa4fbc kevent + 24 1 libdispatch.dylib 0x32fcf032 _dispatch_mgr_invoke + 706 2 libdispatch.dylib 0x32fd003a _dispatch_queue_invoke + 86 3 libdispatch.dylib 0x32fcf5ea _dispatch_worker_thread2 + 186 4 libsystem_c.dylib 0x3620758a _pthread_wqthread + 258 5 libsystem_c.dylib 0x36207bbc start_wqthread + 0 Thread 2 name: WebThread Thread 2: 0 libsystem_kernel.dylib 0x32fa1c00 mach_msg_trap + 20 1 libsystem_kernel.dylib 0x32fa1758 mach_msg + 44 2 CoreFoundation 0x30ab02b8 __CFRunLoopServiceMachPort + 88 3 CoreFoundation 0x30ab2562 __CFRunLoopRun + 350 4 CoreFoundation 0x30a42ebc CFRunLoopRunSpecific + 224 5 CoreFoundation 0x30a42dc4 CFRunLoopRunInMode + 52 6 WebCore 0x336c827e RunWebThread(void*) + 382 7 libsystem_c.dylib 0x3620630a _pthread_start + 242 8 libsystem_c.dylib 0x36207bb4 thread_start + 0 Thread 3: 0 libsystem_kernel.dylib 0x32fa1c00 mach_msg_trap + 20 1 libsystem_kernel.dylib 0x32fa1758 mach_msg + 44 2 CoreFoundation 0x30ab02b8 __CFRunLoopServiceMachPort + 88 3 CoreFoundation 0x30ab2562 __CFRunLoopRun + 350 4 CoreFoundation 0x30a42ebc CFRunLoopRunSpecific + 224 5 CoreFoundation 0x30a42dc4 CFRunLoopRunInMode + 52 6 Foundation 0x35da97f6 +[NSURLConnection(NSURLConnectionReallyInternal) _resourceLoadLoop:] + 206 7 Foundation 0x35d9c382 -[NSThread main] + 38 8 Foundation 0x35e0e5c6 __NSThread__main__ + 966 9 libsystem_c.dylib 0x3620630a _pthread_start + 242 10 libsystem_c.dylib 0x36207bb4 thread_start + 0 Thread 4 name: com.apple.CFSocket.private Thread 4: 0 libsystem_kernel.dylib 0x32fa3c60 __select + 20 1 CoreFoundation 0x30ab58f2 __CFSocketManager + 582 2 libsystem_c.dylib 0x3620630a _pthread_start + 242 3 libsystem_c.dylib 0x36207bb4 thread_start + 0 Thread 5: 0 libsystem_kernel.dylib 0x32fa43ec __workq_kernreturn + 8 1 libsystem_c.dylib 0x362076d8 _pthread_wqthread + 592 2 libsystem_c.dylib 0x36207bbc start_wqthread + 0 Thread 0 crashed with ARM Thread State: r0: 0x00000000 r1: 0x00000000 r2: 0x00000001 r3: 0x00000000 r4: 0x3fb8e48c r5: 0x00000006 r6: 0x002e46ec r7: 0x2fdfe7f8 r8: 0x00245f70 r9: 0x00000065 r10: 0x3f646b98 r11: 0x00000000 ip: 0x00000148 sp: 0x2fdfe7ec lr: 0x368d23bb pc: 0x337e1a1c cpsr: 0x00000010 Binary Images: 0x1000 - 0xf2fff +MyStocks armv7 <5a9bc2940092fcb19620e8be465b8847> /var/mobile/Applications/B120B24C-1B9A-4077-AED3-1364779DBB84/MyStocks.app/MyStocks 0x2fe00000 - 0x2fe25fff dyld armv7 <bb9bfc7d242331d29a79adf7ef7aaa18> /usr/lib/dyld 0x30e06000 - 0x310f3fff libLAPACK.dylib armv7 <b855d60dac01310495453bddfd004f0d> /System/Library/Frameworks/Accelerate.framework/Frameworks/vecLib.framework/libLAPACK.dylib 0x31140000 - 0x31145fff liblaunch.dylib armv7 <f5ccc8234aea3ebd9a88bd37f0fa23ae> /usr/lib/system/liblaunch.dylib 0x3145a000 - 0x3145bfff libsystem_network.dylib armv7 <39bf0f48bd8539169a77f8f61cdcd4c9> /usr/lib/system/libsystem_network.dylib 0x31706000 - 0x31706fff libdnsinfo.dylib armv7 <21415179ffa03f949fa8cc851c6c31c7> /usr/lib/system/libdnsinfo.dylib 0x31716000 - 0x31723fff libbsm.0.dylib armv7 <0a1e2bb78d5138419ecad8ba0fe42fdd> /usr/lib/libbsm.0.dylib 0x31724000 - 0x31725fff libsystem_blocks.dylib armv7 <ccc041df3de73eafb7a59e74cdb1702b> /usr/lib/system/libsystem_blocks.dylib 0x31797000 - 0x317d9fff CoreAudio armv7 <c972fd5f8e89333ca680b9a33587f896> /System/Library/Frameworks/CoreAudio.framework/CoreAudio 0x31a71000 - 0x31a71fff Accelerate armv7 <7d5ad465049136afaa1f0d89aac600bc> /System/Library/Frameworks/Accelerate.framework/Accelerate 0x31bae000 - 0x31c57fff libxml2.2.dylib armv7 <5538d3f2c7d83b88b06168488fe6326b> /usr/lib/libxml2.2.dylib 0x31c58000 - 0x31c63fff libz.1.dylib armv7 <ac706bee36593dc683fd5a96a389d72e> /usr/lib/libz.1.dylib 0x31db6000 - 0x31e75fff CFNetwork armv7 <b09e0d53de9f3bc8bde494780f3cdd4f> /System/Library/Frameworks/CFNetwork.framework/CFNetwork 0x31e76000 - 0x31e78fff libgcc_s.1.dylib armv7 <a2631ac302f4310dae8367939e16b7c2> /usr/lib/libgcc_s.1.dylib 0x31e79000 - 0x31e96fff libsystem_info.dylib armv7 <48016be86e3f3cd9aeee1c6590e1ac6f> /usr/lib/system/libsystem_info.dylib 0x3219d000 - 0x321a1fff libGFXShared.dylib armv7 <a0772a32cd8b3b9194bb0c29807c1c5b> /System/Library/Frameworks/OpenGLES.framework/libGFXShared.dylib 0x321b0000 - 0x3220ffff libBLAS.dylib armv7 <0b36b2272aa33a8c9aa22d99c89d7189> /System/Library/Frameworks/Accelerate.framework/Frameworks/vecLib.framework/libBLAS.dylib 0x322de000 - 0x322ecfff OpenGLES armv7 <5a76beaeaa013f0cbf16e5cb154598ab> /System/Library/Frameworks/OpenGLES.framework/OpenGLES 0x32348000 - 0x3234ffff libbz2.1.0.dylib armv7 <0a082e1d475432959ba93aa3dbf7fb31> /usr/lib/libbz2.1.0.dylib 0x32350000 - 0x3295bfff WebCore armv7 <07941e59d0a33f94802c16c76238fddf> /System/Library/PrivateFrameworks/WebCore.framework/WebCore 0x32a50000 - 0x32a7ffff SystemConfiguration armv7 <1d73b8a159363f96bb9c039655c5eae6> /System/Library/Frameworks/SystemConfiguration.framework/SystemConfiguration 0x32c4c000 - 0x32d39fff libiconv.2.dylib armv7 <f4146ce07e3031ea8a81fa5516fd77d0> /usr/lib/libiconv.2.dylib 0x32d49000 - 0x32d4dfff libcache.dylib armv7 <d2f7fd2a352b3cd59c564be34b53cf80> /usr/lib/system/libcache.dylib 0x32d4e000 - 0x32d53fff MobileKeyBag armv7 <8c35c090bc373cb181fc26b961b8dba5> /System/Library/PrivateFrameworks/MobileKeyBag.framework/MobileKeyBag 0x32d54000 - 0x32d54fff vecLib armv7 <0c60cd0a60f43d2791d36cb357d30e3c> /System/Library/Frameworks/Accelerate.framework/Frameworks/vecLib.framework/vecLib 0x32d7f000 - 0x32d82fff libmacho.dylib armv7 <43311c113a9d3182b7d007129819f029> /usr/lib/system/libmacho.dylib 0x32eac000 - 0x33239fff UIKit armv7 <c271b78464d93cb7bf28c6e49df293ba> /System/Library/Frameworks/UIKit.framework/UIKit 0x3323a000 - 0x3323dfff IOSurface armv7 <ad50e71624583d06b891344d832f9b08> /System/Library/PrivateFrameworks/IOSurface.framework/IOSurface 0x332b5000 - 0x3339afff CoreFoundation armv7 <a8444f997111304c9571b3ff974b769c> /System/Library/Frameworks/CoreFoundation.framework/CoreFoundation 0x333e6000 - 0x33425fff libSystem.B.dylib armv7 <33dcf9a403ae3fd5971d6030ada2fcab> /usr/lib/libSystem.B.dylib 0x3342f000 - 0x33431fff libAccessibility.dylib armv7 <d55f1553d14831a2a5435ae27ef75ef4> /usr/lib/libAccessibility.dylib 0x33485000 - 0x33487fff IOMobileFramebuffer armv7 <683f321680763e519d61541170ba2133> /System/Library/PrivateFrameworks/IOMobileFramebuffer.framework/IOMobileFramebuffer 0x334ce000 - 0x3357ffff WebKit armv7 <eb9a0d69c64b3127b2bffd71641add3b> /System/Library/PrivateFrameworks/WebKit.framework/WebKit 0x335e1000 - 0x33702fff CoreGraphics armv7 <65f6c8701b563542820a26b0dfc4f6a4> /System/Library/Frameworks/CoreGraphics.framework/CoreGraphics 0x33771000 - 0x33771fff libsystem_sandbox.dylib armv7 <f47c01d627853b328e088b3fdd08e87d> /usr/lib/system/libsystem_sandbox.dylib 0x3377a000 - 0x337cffff libvDSP.dylib armv7 <0221caba81a235c5a896a835e2aac047> /System/Library/Frameworks/Accelerate.framework/Frameworks/vecLib.framework/libvDSP.dylib 0x337d0000 - 0x337e7fff libsystem_kernel.dylib armv7 <a06ec84e53bf32098b63c0caebdb45b6> /usr/lib/system/libsystem_kernel.dylib 0x3392a000 - 0x3392bfff libdyld.dylib armv7 <41a7b5e5d9983449ab33affed0f635ad> /usr/lib/system/libdyld.dylib 0x33a3b000 - 0x33a70fff AddressBook armv7 <3f2071a77bc134cd82065eef90d4082f> /System/Library/Frameworks/AddressBook.framework/AddressBook 0x33a84000 - 0x33b9efff libicucore.A.dylib armv7 <bada0c2725bb31a483d5adf9aaf1f8df> /usr/lib/libicucore.A.dylib 0x33cdf000 - 0x33d1bfff libGLImage.dylib armv7 <9d97699e44ee3651ba4ac37e5adec35b> /System/Library/Frameworks/OpenGLES.framework/libGLImage.dylib 0x33e2d000 - 0x33e9cfff ProofReader armv7 <6d843c6aecdd37ae84baa40af8ad7e65> /System/Library/PrivateFrameworks/ProofReader.framework/ProofReader 0x33e9d000 - 0x33ea6fff CoreVideo armv7 <ea847e6dba2d36b1826b255c73b39539> /System/Library/Frameworks/CoreVideo.framework/CoreVideo 0x33fb0000 - 0x33fbdfff libdispatch.dylib armv7 <9a0511ad5ebc3db898f1f49ed1a73d34> /usr/lib/system/libdispatch.dylib 0x340a5000 - 0x340d8fff AppSupport armv7 <0217468bd9f839229a47910b7816b3d5> /System/Library/PrivateFrameworks/AppSupport.framework/AppSupport 0x340dc000 - 0x35b2afff TextInput armv7 <f242acc046073c1598195dd26fd8ad6f> /System/Library/PrivateFrameworks/TextInput.framework/TextInput 0x35b2b000 - 0x35b2bfff libCVMSPluginSupport.dylib armv7 <42d8aa2a31843a6e8bfff745644a7ba5> /System/Library/Frameworks/OpenGLES.framework/libCVMSPluginSupport.dylib 0x35b2c000 - 0x35c4bfff Foundation armv7 <09ff368178c5321c9715b9c8d491d53f> /System/Library/Frameworks/Foundation.framework/Foundation 0x35c61000 - 0x35c67fff liblockdown.dylib armv7 <14c89b7346433c1f8675f454531f6ca3> /usr/lib/liblockdown.dylib 0x35d27000 - 0x35debfff libobjc.A.dylib armv7 <6b51e76fde9f381bb7b3bc5badbfee3a> /usr/lib/libobjc.A.dylib 0x35dec000 - 0x35e24fff IOKit armv7 <80ae313ad69d3363935c88e51a11862d> /System/Library/Frameworks/IOKit.framework/Versions/A/IOKit 0x35e25000 - 0x35f51fff libmecabra.dylib armv7 <113de5f9858c32b8b158bfdc68042a97> /usr/lib/libmecabra.dylib 0x35f72000 - 0x35f91fff Bom armv7 <b178e3efb4d733c694bd5a55e57a314f> /System/Library/PrivateFrameworks/Bom.framework/Bom 0x3615c000 - 0x36168fff SpringBoardServices armv7 <c68262667ac8397a949ce4e92dfec7db> /System/Library/PrivateFrameworks/SpringBoardServices.framework/SpringBoardServices 0x36184000 - 0x36190fff GraphicsServices armv7 <ff78a9636e933f0dbd222f8d26209788> /System/Library/PrivateFrameworks/GraphicsServices.framework/GraphicsServices 0x3654e000 - 0x36552fff AssetsLibraryServices armv7 <e1cbfe599c96369ca4bdb0dd99d3cd9f> /System/Library/PrivateFrameworks/AssetsLibraryServices.framework/AssetsLibraryServices 0x36561000 - 0x365abfff libstdc++.6.dylib armv7 <b2cac408951c3f3c9ba3cf563e54ce81> /usr/lib/libstdc++.6.dylib 0x3661a000 - 0x3662ffff libresolv.9.dylib armv7 <e92cfbb83f7b330db19181e797bb3f7b> /usr/lib/libresolv.9.dylib 0x367ef000 - 0x3689efff QuartzCore armv7 <ef9632c9781f3101916b65e9faae1579> /System/Library/Frameworks/QuartzCore.framework/QuartzCore 0x3689f000 - 0x36920fff libsystem_c.dylib armv7 <a7077267b6743ed3bbdd86d4380c75d9> /usr/lib/system/libsystem_c.dylib 0x3698b000 - 0x3698cfff libremovefile.dylib armv7 <e8858a499d663e6a9e3c188521273cc1> /usr/lib/system/libremovefile.dylib 0x369f7000 - 0x369f8fff TextInput_fr armv7 <df896624a716399f877087d35f6c6d86> /System/Library/TextInput/TextInput_fr.bundle/TextInput_fr 0x36bfd000 - 0x36c02fff libnotify.dylib armv7 <9d7198e91de9386a9e5ea43608a66a57> /usr/lib/system/libnotify.dylib 0x36c09000 - 0x36c4ffff CoreTelephony armv7 <af7d1e770e5a3ffd8834a57fb5d40557> /System/Library/Frameworks/CoreTelephony.framework/CoreTelephony 0x36cbb000 - 0x36cf3fff libCGFreetype.A.dylib armv7 <ccea634795153164a681f0f311f4461d> /System/Library/Frameworks/CoreGraphics.framework/Resources/libCGFreetype.A.dylib 0x36cf4000 - 0x36cf5fff CoreSurface armv7 <7b83cd757da73e6e826693c29296d3fa> /System/Library/PrivateFrameworks/CoreSurface.framework/CoreSurface 0x36d0d000 - 0x36da2fff ImageIO armv7 <d520e3241d1130e8ac1375ee0f2c1095> /System/Library/Frameworks/ImageIO.framework/ImageIO 0x36ded000 - 0x36df4fff AggregateDictionary armv7 <ab9777b39e8e3026ad64dc90323cad7e> /System/Library/PrivateFrameworks/AggregateDictionary.framework/AggregateDictionary 0x36e84000 - 0x36eadfff MobileCoreServices armv7 <57fef84bdc17301d8bf53ba0fb967fe6> /System/Library/Frameworks/MobileCoreServices.framework/MobileCoreServices 0x36efd000 - 0x37001fff JavaScriptCore armv7 <61a94142e2d23dafa2964190dd46e9e3> /System/Library/PrivateFrameworks/JavaScriptCore.framework/JavaScriptCore 0x37002000 - 0x37039fff Security armv7 <6599f42a910b3b31a0e1d98c883d61cb> /System/Library/Frameworks/Security.framework/Security 0x37058000 - 0x37071fff libRIP.A.dylib armv7 <4825c3e392983aba947eca06555e4480> /System/Library/Frameworks/CoreGraphics.framework/Resources/libRIP.A.dylib 0x3716a000 - 0x3716ffff libsystem_dnssd.dylib armv7 <c7cfe523e2d73521abc01587313ef730> /usr/lib/system/libsystem_dnssd.dylib 0x371ba000 - 0x371bcfff MobileInstallation armv7 <94b6d6c5d9883175af26764567528127> /System/Library/PrivateFrameworks/MobileInstallation.framework/MobileInstallation 0x37297000 - 0x372e8fff libsqlite3.dylib armv7 <8a41cc6a6d9332308bc415d27577fd24> /usr/lib/libsqlite3.dylib 0x3734c000 - 0x374a0fff AudioToolbox armv7 <6619c8c13f8d328e923e797fa8d0df23> /System/Library/Frameworks/AudioToolbox.framework/AudioToolbox 0x374a4000 - 0x374c4fff PrintKit armv7 <e5a01ca9083a36afacc08611a398e2ad> /System/Library/PrivateFrameworks/PrintKit.framework/PrintKit 0x374c5000 - 0x374cafff libcopyfile.dylib armv7 <e57c2b9054b831d9a37119baaa4947cb> /usr/lib/system/libcopyfile.dylib 0x37539000 - 0x37576fff CoreText armv7 <fb6a72faec2330c4b2cd33c2e9c59588> /System/Library/Frameworks/CoreText.framework/CoreText
3
7,091,356
08/17/2011 10:32:06
898,450
08/17/2011 10:32:06
1
0
Improving quicksort by implementing insertion sort
The running time of quick sort can be improved in practice by taking advantage of the fast running time of insertion sort when its input is nearly sorted. When quicksort is called on a subarray with fewer than k elements, let it simply return without sorting the subarray. After the top level call to quicksort returns, run insertion sort on the entire array to finish the sorting process. Argue that this sorting algorithm runs in O(nk + n log (n/k)) expected time. How should k be picked, both in theory and in practice?
sorting
quicksort
insertion
null
null
08/17/2011 11:44:13
not a real question
Improving quicksort by implementing insertion sort === The running time of quick sort can be improved in practice by taking advantage of the fast running time of insertion sort when its input is nearly sorted. When quicksort is called on a subarray with fewer than k elements, let it simply return without sorting the subarray. After the top level call to quicksort returns, run insertion sort on the entire array to finish the sorting process. Argue that this sorting algorithm runs in O(nk + n log (n/k)) expected time. How should k be picked, both in theory and in practice?
1
9,778,586
03/19/2012 22:00:07
331,637
05/03/2010 17:17:57
776
30
Comparing version numbers in ANSI C
I'm in need of a piece of c code that can compare two version-numbers, preferably in <a href="http://semver.org/">'semantic versioning'</a> format (0.1.7, 1.3.2), to determine which one is the later version. Yes, I could certainly write this code myself. However, I expect thousands of developers to have done this before me, so I decided to see whether I could benefit from some community work first.
c
versioning
semantic-versioning
null
null
03/19/2012 22:12:45
not a real question
Comparing version numbers in ANSI C === I'm in need of a piece of c code that can compare two version-numbers, preferably in <a href="http://semver.org/">'semantic versioning'</a> format (0.1.7, 1.3.2), to determine which one is the later version. Yes, I could certainly write this code myself. However, I expect thousands of developers to have done this before me, so I decided to see whether I could benefit from some community work first.
1
10,229,530
04/19/2012 13:50:15
29,244
10/18/2008 16:13:24
1,782
46
Link to a non mobile page from a jquery mobile page -> css not loaded
Context: asp.net MVC 3 app. Page1 is a mobile page using jquery mobile and it contains a link to Page2 which is a normal page which uses a specific stylesheet. Issue: on my phone, when I click the link on Page1, it goes to Page2 (with a horizontal sliding effect) but the stylesheet is not loaded. If I force a reload of Page2 then the stylesheet is loaded. Also, on the iphone, if I press the link to show the "open in new window" button and click it, it loads well in the new window. Debug: if I simulate this on a desktop computer (by forcing mobile views) the same happens. The back button does not even work well. When loading Page2, Firebug, in the Net tab, displays as if I was still loading Page1 (it displays Get Page1) even if this is the text of Page2 that appears (without the css), and it doesn't show a line saying that it tries to load the css.
asp.net-mvc
jquery-mobile
null
null
null
null
open
Link to a non mobile page from a jquery mobile page -> css not loaded === Context: asp.net MVC 3 app. Page1 is a mobile page using jquery mobile and it contains a link to Page2 which is a normal page which uses a specific stylesheet. Issue: on my phone, when I click the link on Page1, it goes to Page2 (with a horizontal sliding effect) but the stylesheet is not loaded. If I force a reload of Page2 then the stylesheet is loaded. Also, on the iphone, if I press the link to show the "open in new window" button and click it, it loads well in the new window. Debug: if I simulate this on a desktop computer (by forcing mobile views) the same happens. The back button does not even work well. When loading Page2, Firebug, in the Net tab, displays as if I was still loading Page1 (it displays Get Page1) even if this is the text of Page2 that appears (without the css), and it doesn't show a line saying that it tries to load the css.
0
9,047,510
01/28/2012 17:55:19
1,175,537
01/28/2012 17:45:52
1
0
Throwing an exception or returning an error - What is the better approach?
What is the better approach when handling errors - throwing it as an exception or returning a an object that contains the error and its details? I'm thinking what is the better approach to notifying errors - in terms of system resources, coding practices and overall enterprise practices ? I've seen in most cases, the sample code throws a custom exception containing the error information. But I was thinking if it was better to just return an object instantiated from a class (for example: class DatabaseError)? I believe throwing exceptions in C# can be resource intensive and this would involve having (possibly) a lot of try-catch blocks. Thanks!
c#
winforms
exception
null
null
01/29/2012 03:14:33
not constructive
Throwing an exception or returning an error - What is the better approach? === What is the better approach when handling errors - throwing it as an exception or returning a an object that contains the error and its details? I'm thinking what is the better approach to notifying errors - in terms of system resources, coding practices and overall enterprise practices ? I've seen in most cases, the sample code throws a custom exception containing the error information. But I was thinking if it was better to just return an object instantiated from a class (for example: class DatabaseError)? I believe throwing exceptions in C# can be resource intensive and this would involve having (possibly) a lot of try-catch blocks. Thanks!
4
2,770,148
05/05/2010 01:56:54
225,439
12/05/2009 15:41:37
3
0
Where UnityContainerElement in Unity 2?
I was in Unity 1.2, use the following code: UnityConfigurationSection UnitySection = (UnityConfigurationSection)ConfigurationManager.GetSection("Unity"); Dictionary<string, IUnityContainer> Containers = new Dictionary<string, IUnityContainer>(); foreach (UnityContainerElement element in UnitySection.Containers) { IUnityContainer container = new UnityContainer(); Containers.Add(element.Name, container); element.Configure(Containers[element.Name]); } but, I couldn't do so in the Unity 2.0 beta2, because The class 'UnityContainerElement' does not exist in Unity 2 beta2. How can I do this in the new version?
patterns
practices
unity
null
null
null
open
Where UnityContainerElement in Unity 2? === I was in Unity 1.2, use the following code: UnityConfigurationSection UnitySection = (UnityConfigurationSection)ConfigurationManager.GetSection("Unity"); Dictionary<string, IUnityContainer> Containers = new Dictionary<string, IUnityContainer>(); foreach (UnityContainerElement element in UnitySection.Containers) { IUnityContainer container = new UnityContainer(); Containers.Add(element.Name, container); element.Configure(Containers[element.Name]); } but, I couldn't do so in the Unity 2.0 beta2, because The class 'UnityContainerElement' does not exist in Unity 2 beta2. How can I do this in the new version?
0
4,227,953
11/19/2010 17:59:40
243,500
01/04/2010 21:54:42
394
3
nifty_generators gem appears installed but still can't use generators
I'm running Ruby 1.9.2 and Rails 3.0.0 in WinXP. I ran `gem install nifty-generators` from inside a new project directory. It said the gem, version 0.4.2, was successfully installed but there was an error installing ri and rdoc, so I ran the same command again but with the --no-ri --no-rdoc switches. Now it appears nifty_generators is installed with no errors, and it shows up in my `gem list`, but when I run `rails g nifty:layout` it says the nifty:layout generator wasn't found. `rails g nifty_layout` also doesn't work. Anyone has ideas? Thanks!
ruby-on-rails
ruby
gem
null
null
null
open
nifty_generators gem appears installed but still can't use generators === I'm running Ruby 1.9.2 and Rails 3.0.0 in WinXP. I ran `gem install nifty-generators` from inside a new project directory. It said the gem, version 0.4.2, was successfully installed but there was an error installing ri and rdoc, so I ran the same command again but with the --no-ri --no-rdoc switches. Now it appears nifty_generators is installed with no errors, and it shows up in my `gem list`, but when I run `rails g nifty:layout` it says the nifty:layout generator wasn't found. `rails g nifty_layout` also doesn't work. Anyone has ideas? Thanks!
0
4,842,331
01/30/2011 10:18:13
313,088
04/09/2010 18:55:29
938
73
Kinect pattern recognition
I bought a Kinect to play around with on my PC in C#. I'm using CLNUIDevice.dll to get the depth image from Kinect. This works fine and I'm able to read the depth through the RGB values in the image. Now I'm wondering what libraries there are to do different types of recognition. I've seen hand recognition, face recognition, skeleton, emotions, objects, etc. The libraries don't have to be for Kinect (though that would be nice) and they don't have to be for .Net (though that would be nice).
c#
.net
algorithm
image
analysis
07/15/2012 17:30:47
not constructive
Kinect pattern recognition === I bought a Kinect to play around with on my PC in C#. I'm using CLNUIDevice.dll to get the depth image from Kinect. This works fine and I'm able to read the depth through the RGB values in the image. Now I'm wondering what libraries there are to do different types of recognition. I've seen hand recognition, face recognition, skeleton, emotions, objects, etc. The libraries don't have to be for Kinect (though that would be nice) and they don't have to be for .Net (though that would be nice).
4
11,002,929
06/12/2012 18:50:41
1,279,820
03/20/2012 00:50:44
420
18
On a webpage how do you find which file is responsible for a certain feature
I'm trouble shooting a bunch of files with lots of includes and am trying to find the file where the text "Sorry, an error occurred while processing your request." is. What's the best way to go about this? I tried using Fire Fox's inspect element but it doesn't say what file it's coming from. I tried using Windows search and checking "search content" for the string, but for some reason it doesn't work (big surprise).
html
search
include
null
null
06/22/2012 17:50:32
off topic
On a webpage how do you find which file is responsible for a certain feature === I'm trouble shooting a bunch of files with lots of includes and am trying to find the file where the text "Sorry, an error occurred while processing your request." is. What's the best way to go about this? I tried using Fire Fox's inspect element but it doesn't say what file it's coming from. I tried using Windows search and checking "search content" for the string, but for some reason it doesn't work (big surprise).
2
1,753,588
11/18/2009 04:15:29
102,422
05/06/2009 19:11:55
74
2
Trigger thickbox from flash
i wonder if somebody knows how to trigger thickbox from onRelease() event in flash. is that possible?
flash
thickbox
triggers
null
null
null
open
Trigger thickbox from flash === i wonder if somebody knows how to trigger thickbox from onRelease() event in flash. is that possible?
0
3,319,063
07/23/2010 14:24:06
347,216
05/21/2010 15:27:01
26
3
Should I go to get my degree after finishing my diploma?
I've got a question regarding a 'higher education' opportunity which is available to me. I'm a 22 year old student currently in a 16 month co-op term for a Software Engineering Technologist diploma at a polytechnical college in Canada. I'm doing quite well in the program and feel that I have really found my calling. I'm just over 2 years into the 3 year program (which will turn out to be 4 years with my internship). This means that I will have my diploma in May of 2012. My college has [just announced an agreement][1] with a local university that will allow graduates of my program to obtain a [Bachelor of Science degree in Computer Science][2] in a reduced amount of time. Instead of the standard four years of university, I would be able to take a few courses towards the second year of the degree and then would have to complete the 3rd and 4th years of the degree program. This would could mean that I could have my full computer science degree by around 2015. I am asking if any of you can share some insight from your experiences. Is the degree really worth an extra 3 years of time spent on getting an enhanced education? After talking with some of the other co-op students at this company that university education is more theory-based, while the education that I am receiving in college is more applied knowledge. Is it possible that the time that I take away from working will actually make me a _less attractive hire_? I'll put together a list of the pros/cons as I get some input. [1]: http://blogs1.conestogac.on.ca/news/2010/04/laurier_and_conestoga_combine.php [2]: http://en.wikipedia.org/wiki/Bachelor_of_Science_in_Computer_Science
education
career-development
degree
null
null
07/23/2010 15:17:46
off topic
Should I go to get my degree after finishing my diploma? === I've got a question regarding a 'higher education' opportunity which is available to me. I'm a 22 year old student currently in a 16 month co-op term for a Software Engineering Technologist diploma at a polytechnical college in Canada. I'm doing quite well in the program and feel that I have really found my calling. I'm just over 2 years into the 3 year program (which will turn out to be 4 years with my internship). This means that I will have my diploma in May of 2012. My college has [just announced an agreement][1] with a local university that will allow graduates of my program to obtain a [Bachelor of Science degree in Computer Science][2] in a reduced amount of time. Instead of the standard four years of university, I would be able to take a few courses towards the second year of the degree and then would have to complete the 3rd and 4th years of the degree program. This would could mean that I could have my full computer science degree by around 2015. I am asking if any of you can share some insight from your experiences. Is the degree really worth an extra 3 years of time spent on getting an enhanced education? After talking with some of the other co-op students at this company that university education is more theory-based, while the education that I am receiving in college is more applied knowledge. Is it possible that the time that I take away from working will actually make me a _less attractive hire_? I'll put together a list of the pros/cons as I get some input. [1]: http://blogs1.conestogac.on.ca/news/2010/04/laurier_and_conestoga_combine.php [2]: http://en.wikipedia.org/wiki/Bachelor_of_Science_in_Computer_Science
2
8,716,767
01/03/2012 18:13:10
278,470
02/22/2010 05:31:46
811
38
Replacing data with another data using regular expressions
Can i replace a big text like `During the day, abc is working.` with new text `abc is happy to work.` using only regular expressions. This was asked in some text papers. And it also said that code cannot be more then 2 lines.
php5
null
null
null
null
01/08/2012 05:12:04
not a real question
Replacing data with another data using regular expressions === Can i replace a big text like `During the day, abc is working.` with new text `abc is happy to work.` using only regular expressions. This was asked in some text papers. And it also said that code cannot be more then 2 lines.
1
8,970,086
01/23/2012 10:17:18
28,149
10/15/2008 08:33:01
3,353
101
After taking 2 pictures in a MonoDroid app the camera app stops working
In a MonoDroid app, the following code is used to start the native camera application: internal void TakePicture(int pictureId) { var uri = ContentResolver.Insert(MediaStore.Images.Media.ExternalContentUri, new ContentValues()); var intent = new Intent(MediaStore.ActionImageCapture); intent.PutExtra(MediaStore.ExtraOutput, uri); StartActivityForResult(intent, ACTIVITY_RESULT_PICTURE_TAKEN); pictureId = pictureId; pictureUri = uri; } After the picture has been taken, it's handled here: protected override void OnActivityResult(int requestCode, Result resultCode, Intent data) { if (requestCode == ACTIVITY_RESULT_PICTURE_TAKEN) { if (resultCode == Result.Ok) { /* The URI is not a valid path, but something internal to Android * See * http://stackoverflow.com/questions/8448796/monodroid-setting-imageview-to-image-stored-on-sdcard * for more information. */ if (OnPictureTaken != null) OnPictureTaken(this, new PictureTakenEventArgs(pictureId, GetRealPathFromURI(pictureUri))); } } } The first 2 attempts to take a picture always succeed, but the 3rd time the Android camera application allows you to take pictures but it doesn't close and it doesn't return the picture to the application anymore... (The event handler above doesn't get called either). We're testing this on Asus Transformer 101 tablets (multiple firmware versions) PS: I found this entry, but I think it's a different problem. > http://stackoverflow.com/questions/7256362/error-after-taking-several-pictures-using-the-android-camera Any suggestions?
c#
android
monodroid
null
null
null
open
After taking 2 pictures in a MonoDroid app the camera app stops working === In a MonoDroid app, the following code is used to start the native camera application: internal void TakePicture(int pictureId) { var uri = ContentResolver.Insert(MediaStore.Images.Media.ExternalContentUri, new ContentValues()); var intent = new Intent(MediaStore.ActionImageCapture); intent.PutExtra(MediaStore.ExtraOutput, uri); StartActivityForResult(intent, ACTIVITY_RESULT_PICTURE_TAKEN); pictureId = pictureId; pictureUri = uri; } After the picture has been taken, it's handled here: protected override void OnActivityResult(int requestCode, Result resultCode, Intent data) { if (requestCode == ACTIVITY_RESULT_PICTURE_TAKEN) { if (resultCode == Result.Ok) { /* The URI is not a valid path, but something internal to Android * See * http://stackoverflow.com/questions/8448796/monodroid-setting-imageview-to-image-stored-on-sdcard * for more information. */ if (OnPictureTaken != null) OnPictureTaken(this, new PictureTakenEventArgs(pictureId, GetRealPathFromURI(pictureUri))); } } } The first 2 attempts to take a picture always succeed, but the 3rd time the Android camera application allows you to take pictures but it doesn't close and it doesn't return the picture to the application anymore... (The event handler above doesn't get called either). We're testing this on Asus Transformer 101 tablets (multiple firmware versions) PS: I found this entry, but I think it's a different problem. > http://stackoverflow.com/questions/7256362/error-after-taking-several-pictures-using-the-android-camera Any suggestions?
0
8,832,215
01/12/2012 08:47:21
276,733
02/19/2010 06:25:15
363
19
Can't open a view in Business Activity Monitoring
I use BizTalk Server 2010. Yesterday I deployed a BAM activity and could browse a corresponding view in the BAM portal. Today I've created another activity, but this time I made it non-RTA and hence I can't open a view for that. Every browser gives me an error: Views cannot be displayed for one or more of the following reasons: - Office Web Components 2003 are not installed. - Your Web Browser does not support ActiveX controls. - Support for ActiveX controls is disabled. I've installed Office Web Components 2003 previously and ActiveX controls are enabled. Where's the problem?
biztalk
bam
null
null
null
null
open
Can't open a view in Business Activity Monitoring === I use BizTalk Server 2010. Yesterday I deployed a BAM activity and could browse a corresponding view in the BAM portal. Today I've created another activity, but this time I made it non-RTA and hence I can't open a view for that. Every browser gives me an error: Views cannot be displayed for one or more of the following reasons: - Office Web Components 2003 are not installed. - Your Web Browser does not support ActiveX controls. - Support for ActiveX controls is disabled. I've installed Office Web Components 2003 previously and ActiveX controls are enabled. Where's the problem?
0
2,199,027
02/04/2010 10:54:07
202,862
11/04/2009 19:00:10
125
1
VB6: problem with activeX dll
i created an activeX-dll which returns a class object (let's call it myclass). the problem: although i got myclass added in my host-project, i'm getting a type mismatch error when trying to define the returned object as myclass like: sub dll_done(obj as myclass) it only works with type variant. seems like it's something with the reference. how can i fix it? thx
vb6
activex
null
null
null
null
open
VB6: problem with activeX dll === i created an activeX-dll which returns a class object (let's call it myclass). the problem: although i got myclass added in my host-project, i'm getting a type mismatch error when trying to define the returned object as myclass like: sub dll_done(obj as myclass) it only works with type variant. seems like it's something with the reference. how can i fix it? thx
0
9,623,573
03/08/2012 19:26:31
258,483
01/25/2010 14:19:08
639
23
How to take portlet preferences correctly in Liferay?
If a portlet is a web application, then why portlet preferences are taken from ServletRequest (at request scope)? http://docs.liferay.com/portal/6.1/javadocs/com/liferay/portal/util/PortalUtil.html#getPreferences(javax.servlet.http.HttpServletRequest) How is it possible to take preferences object at application scope?
java
liferay
preferences
portlet
liferay-6
null
open
How to take portlet preferences correctly in Liferay? === If a portlet is a web application, then why portlet preferences are taken from ServletRequest (at request scope)? http://docs.liferay.com/portal/6.1/javadocs/com/liferay/portal/util/PortalUtil.html#getPreferences(javax.servlet.http.HttpServletRequest) How is it possible to take preferences object at application scope?
0
4,429,998
12/13/2010 14:49:25
479,384
10/18/2010 14:25:29
276
24
SharedSizeGroup in menuItem template
I have to apply a specific design to my application's menus. So I took Miscrosoft's template example as a basis to build on: http://msdn.microsoft.com/en-gb/library/ms747082.aspx so what I did is I created a new ResourceDictionary containing all those templates/Brushes/Styles etc... (just copy/pasted them) in my app's resources. it works pretty well except for ONE thing: the SharedSizeGroup property seems to have no effect whatsoever. The icons/checkmarks are not at all aligned, and if I have a menuItem with an icon followed by a menuItem with no icon, the one without icon will be left-aligned, so that it starts below the first one's icon. (ugly) now I read the doc and one part has me stuck : > Grid size-sharing does not work if you > set IsSharedSizeScope to true within a > resource template and you define > SharedSizeGroup as outside that > template. what on earth does that mean? and is it (as I suspect) the source of my problem here. If yes, what is the solution? thank you for your help.
wpf
xaml
alignment
controltemplate
null
null
open
SharedSizeGroup in menuItem template === I have to apply a specific design to my application's menus. So I took Miscrosoft's template example as a basis to build on: http://msdn.microsoft.com/en-gb/library/ms747082.aspx so what I did is I created a new ResourceDictionary containing all those templates/Brushes/Styles etc... (just copy/pasted them) in my app's resources. it works pretty well except for ONE thing: the SharedSizeGroup property seems to have no effect whatsoever. The icons/checkmarks are not at all aligned, and if I have a menuItem with an icon followed by a menuItem with no icon, the one without icon will be left-aligned, so that it starts below the first one's icon. (ugly) now I read the doc and one part has me stuck : > Grid size-sharing does not work if you > set IsSharedSizeScope to true within a > resource template and you define > SharedSizeGroup as outside that > template. what on earth does that mean? and is it (as I suspect) the source of my problem here. If yes, what is the solution? thank you for your help.
0
11,187,099
06/25/2012 09:57:53
1,479,548
06/25/2012 09:37:31
1
0
connection refused in redis delay() method
I make periodic_task using celery, redis. I follow this site : http://pastebin.com/ivQahjJ0 It works well in command line. $ python ./manage.py shell<br> -from app.tasks import add<br> -r = add.delay(3, 4)<br> -r.result But, I want to see this message on browser, so I make another app and create sample.py file something like this : -from app.tasks import add<br> -r = add.delay(3, 4)<br> -return HttpResponse(r.result) And I set urls.py so that I can see the result if I connect 'http://localhost/sample'<br> However, if I do like this method, I got [Errno 61] Connection refused message.<br> May be some settings are not appropriate, but I can't find it.<br> I set on server, such as nginx, uwsgi ------------ One more.<br> If I just typed 'python' and go in to the command line, I also got connection refused meesage. Could you help me?<br>
connection
errno
null
null
null
null
open
connection refused in redis delay() method === I make periodic_task using celery, redis. I follow this site : http://pastebin.com/ivQahjJ0 It works well in command line. $ python ./manage.py shell<br> -from app.tasks import add<br> -r = add.delay(3, 4)<br> -r.result But, I want to see this message on browser, so I make another app and create sample.py file something like this : -from app.tasks import add<br> -r = add.delay(3, 4)<br> -return HttpResponse(r.result) And I set urls.py so that I can see the result if I connect 'http://localhost/sample'<br> However, if I do like this method, I got [Errno 61] Connection refused message.<br> May be some settings are not appropriate, but I can't find it.<br> I set on server, such as nginx, uwsgi ------------ One more.<br> If I just typed 'python' and go in to the command line, I also got connection refused meesage. Could you help me?<br>
0
11,409,962
07/10/2012 09:02:57
1,514,243
07/10/2012 08:50:54
1
0
How can i Code "Happy Birthday Josh" in ruby
Can someone help me with this. Im baking a cake and i want the code in ruby saying Happy Birthday Josh" On the icing. Can someone give some ideas. Josh is my brother and an avid programmers. I would really appreciate it :)
ruby
null
null
null
null
07/10/2012 11:38:11
off topic
How can i Code "Happy Birthday Josh" in ruby === Can someone help me with this. Im baking a cake and i want the code in ruby saying Happy Birthday Josh" On the icing. Can someone give some ideas. Josh is my brother and an avid programmers. I would really appreciate it :)
2
8,895,127
01/17/2012 13:08:23
971,741
09/29/2011 18:18:58
41
0
Hosting providers for .Net 4 / MVC 3 applications
I’ve developed an application over .Net 4 / MVC 3. And now I want to host, this is my first ever hosting experience so I m confused and seriously need help. It’s not so complex application basically serving as a community image sharing website. Now I am looking for a hosting service for it, I don’t know much about it but what I’ve learnt I think I need following in it. - Host provided using IIS 7 (that’s fully supports .NET4/MVC3 so I could ideally use MVC routing functionalities totally, without having the headache e of adding extensions in route and support functionalities File MIME Types, Custom Error Pages etc.) - As it’s a community website, so it should remain available 24/7 like good server performance and availability, so users don’t get bugged by server not available and alike errors. - Domain registering/hosting functionality, Security - SQL Server support, an easy control panel (I think Cpanel?) - Dedicated IP address for my website (for SSL and better SEO) - Ideally unlimited bandwidth/space packages (because it image sharing so it can be increasing in both parameters) - And of rouse as it’s not actually a commercial product so be compact in price. I know I’ve put up a lot of points up, but I’ve also searched through other threads and other forums and found out these as recommended options, any words over their performance and support: [Arvixe](http://www.arvixe.com/asp_net_web_hosting) | [Seekdotnet](http://www.seekdotnet.com/asp.net-web-hosting/)
asp.net-mvc-3
iis7
.net-4.0
hosting
null
03/18/2012 15:50:48
not constructive
Hosting providers for .Net 4 / MVC 3 applications === I’ve developed an application over .Net 4 / MVC 3. And now I want to host, this is my first ever hosting experience so I m confused and seriously need help. It’s not so complex application basically serving as a community image sharing website. Now I am looking for a hosting service for it, I don’t know much about it but what I’ve learnt I think I need following in it. - Host provided using IIS 7 (that’s fully supports .NET4/MVC3 so I could ideally use MVC routing functionalities totally, without having the headache e of adding extensions in route and support functionalities File MIME Types, Custom Error Pages etc.) - As it’s a community website, so it should remain available 24/7 like good server performance and availability, so users don’t get bugged by server not available and alike errors. - Domain registering/hosting functionality, Security - SQL Server support, an easy control panel (I think Cpanel?) - Dedicated IP address for my website (for SSL and better SEO) - Ideally unlimited bandwidth/space packages (because it image sharing so it can be increasing in both parameters) - And of rouse as it’s not actually a commercial product so be compact in price. I know I’ve put up a lot of points up, but I’ve also searched through other threads and other forums and found out these as recommended options, any words over their performance and support: [Arvixe](http://www.arvixe.com/asp_net_web_hosting) | [Seekdotnet](http://www.seekdotnet.com/asp.net-web-hosting/)
4
10,816,991
05/30/2012 13:10:35
412,923
08/06/2010 10:44:07
1,500
111
Regular expression validator for an eight digit long number starting with 1
I know I can use `[Required]`, `[StringLength]` annotations for validating empty string and length requirements but would like to use same regular expression for validating them as well. I haven't tried as I am not very good on regex. Regular Expression should validate 1.Empty string 2.Length of characters (8) 3.Integer 4.Starting number (should be 1) Here is the code: [DisplayName("Account Number:")] [RegularExpression("", ErrorMessage = "An eight digit long number starting with 1 required")] public string accountNo { get; set; } Thanks in advance !
regex
asp.net-mvc-3
dataannotations
null
null
null
open
Regular expression validator for an eight digit long number starting with 1 === I know I can use `[Required]`, `[StringLength]` annotations for validating empty string and length requirements but would like to use same regular expression for validating them as well. I haven't tried as I am not very good on regex. Regular Expression should validate 1.Empty string 2.Length of characters (8) 3.Integer 4.Starting number (should be 1) Here is the code: [DisplayName("Account Number:")] [RegularExpression("", ErrorMessage = "An eight digit long number starting with 1 required")] public string accountNo { get; set; } Thanks in advance !
0
6,644,745
07/11/2011 00:47:05
838,075
07/11/2011 00:47:05
1
0
Jquery: Select a radiobutton
Hello. I'm trying to get that when you click on a row in the table then the radio button on the same row will be selected. Have anyone some suggestions for how this can be done? <form name="form1" method="post" action=""> <table id="simplehighlight" class="REW_table" style="width: 350px; margin-left: auto; margin-right: auto;" > <thead></thead> <tr><td><input type="radio" name="RadioGroup1" value="radio" id="RadioGroup1_0"></tr> <tr><td><input type="radio" name="RadioGroup1" value="radio" id="RadioGroup1_0"></tr> <tr><td><input type="radio" name="RadioGroup1" value="radio" id="RadioGroup1_0"></tr> <tr><td><input type="radio" name="RadioGroup1" value="radio" id="RadioGroup1_0"></tr> <tr><td><input type="radio" name="RadioGroup1" value="radio" id="RadioGroup1_0"></tr> </table> </form> JQUERY $(document).ready(function(){ $('#simplehighlight tr').hover(function(){ $(this).children().addClass('datahighlight'); // Mark lightgray $(this).click(function(){ $('#simplehighlight tr').children().removeClass('datahighlight_select'); // Remove all old blue mark $(this).children().addClass('datahighlight_select'); // Mark blue }); },function(){ $(this).children().removeClass('datahighlight'); // Remove lightgray }); });
jquery
null
null
null
null
null
open
Jquery: Select a radiobutton === Hello. I'm trying to get that when you click on a row in the table then the radio button on the same row will be selected. Have anyone some suggestions for how this can be done? <form name="form1" method="post" action=""> <table id="simplehighlight" class="REW_table" style="width: 350px; margin-left: auto; margin-right: auto;" > <thead></thead> <tr><td><input type="radio" name="RadioGroup1" value="radio" id="RadioGroup1_0"></tr> <tr><td><input type="radio" name="RadioGroup1" value="radio" id="RadioGroup1_0"></tr> <tr><td><input type="radio" name="RadioGroup1" value="radio" id="RadioGroup1_0"></tr> <tr><td><input type="radio" name="RadioGroup1" value="radio" id="RadioGroup1_0"></tr> <tr><td><input type="radio" name="RadioGroup1" value="radio" id="RadioGroup1_0"></tr> </table> </form> JQUERY $(document).ready(function(){ $('#simplehighlight tr').hover(function(){ $(this).children().addClass('datahighlight'); // Mark lightgray $(this).click(function(){ $('#simplehighlight tr').children().removeClass('datahighlight_select'); // Remove all old blue mark $(this).children().addClass('datahighlight_select'); // Mark blue }); },function(){ $(this).children().removeClass('datahighlight'); // Remove lightgray }); });
0
7,128,252
08/19/2011 22:57:48
696,042
04/07/2011 04:10:13
107
2
External Constants for UIColor, UIFont, etc
I have a constants.m file that is a centralized collection of many program constants. To set a color, I do this: @implementation UIColor (UIColor_Constants) +(UIColor *) defaultResultTableBackgroundColor{ //return [[UIColor colorWithRed:0.6f green:0.004f blue:0.0f alpha:1.0f] retain]; return [[UIColor colorWithRed:0.1f green:0.004f blue:0.3f alpha:0.3f] retain]; } +(UIColor *) defaultResultHeaderBackgroundColor{ return [[UIColor clearColor] retain]; } @end and in the constants.h I have @interface UIColor (UIColor_Constants) +(UIColor *) defaultResultTableBackgroundColor; +(UIColor *) defaultResultHeaderBackgroundColor; @end and then just use **[UIColor defaultResultTableBackgroundColor]** where I want to refer to this constant. I would like to have some other UIColor and UIFont constants, and, while this works, it seems to be more complicated than it needs to be. Is there an easier way to do this?
iphone
cocoa
ipad
extern
null
null
open
External Constants for UIColor, UIFont, etc === I have a constants.m file that is a centralized collection of many program constants. To set a color, I do this: @implementation UIColor (UIColor_Constants) +(UIColor *) defaultResultTableBackgroundColor{ //return [[UIColor colorWithRed:0.6f green:0.004f blue:0.0f alpha:1.0f] retain]; return [[UIColor colorWithRed:0.1f green:0.004f blue:0.3f alpha:0.3f] retain]; } +(UIColor *) defaultResultHeaderBackgroundColor{ return [[UIColor clearColor] retain]; } @end and in the constants.h I have @interface UIColor (UIColor_Constants) +(UIColor *) defaultResultTableBackgroundColor; +(UIColor *) defaultResultHeaderBackgroundColor; @end and then just use **[UIColor defaultResultTableBackgroundColor]** where I want to refer to this constant. I would like to have some other UIColor and UIFont constants, and, while this works, it seems to be more complicated than it needs to be. Is there an easier way to do this?
0
4,101,787
11/04/2010 21:57:42
254,709
01/20/2010 08:48:37
179
23
z-index values not working the way it should - z-index 50 item shows up underneath
http://new.michaellane.com/listing-gallery.php The yellow strips of paper you see there have this set: .listing_specs { width:230px; height:140px; background-image:url('/images/featured_listing_specs.png'); background-repeat:no-repeat; color:#836637; padding-top:10px; position:absolute; top:120px; right:-120px; z-index:50; } And the div that contains it, .listing_icons, is just a generic float:left, position:relative DIV with a z-index of only 10. How is it that the yellow strips come underneath the .listing_icons on the right hand side?
html
css
position
z-index
layer
null
open
z-index values not working the way it should - z-index 50 item shows up underneath === http://new.michaellane.com/listing-gallery.php The yellow strips of paper you see there have this set: .listing_specs { width:230px; height:140px; background-image:url('/images/featured_listing_specs.png'); background-repeat:no-repeat; color:#836637; padding-top:10px; position:absolute; top:120px; right:-120px; z-index:50; } And the div that contains it, .listing_icons, is just a generic float:left, position:relative DIV with a z-index of only 10. How is it that the yellow strips come underneath the .listing_icons on the right hand side?
0
2,947,219
06/01/2010 04:07:57
183,424
10/03/2009 00:24:22
372
5
Where are Silverlight assemblies stored when a xap file is run?
We currently have a XAP file which contains Foo.dll, and another XAP file (with a completely different name) which contains an updated version Foo.dll (but the same version number). When we run the second XAP file, it looks as though the Silverlight runtime on the client, is picking up the old version of Foo.dll from the first XAP file. Anyone know where the Silverlight runtime unzips the xap file before running its content? Or if the runtime executes on a single app domain which could explain these errors?
.net
silverlight
appdomain
null
null
null
open
Where are Silverlight assemblies stored when a xap file is run? === We currently have a XAP file which contains Foo.dll, and another XAP file (with a completely different name) which contains an updated version Foo.dll (but the same version number). When we run the second XAP file, it looks as though the Silverlight runtime on the client, is picking up the old version of Foo.dll from the first XAP file. Anyone know where the Silverlight runtime unzips the xap file before running its content? Or if the runtime executes on a single app domain which could explain these errors?
0
10,687,590
05/21/2012 14:51:43
1,343,591
04/19/2012 09:36:15
10
0
From mdb Access application to windows application C#
I've to recode a small access mdb application using c#. What' the best way to re-use and store data now stored in access tables?
c#
ms-access
null
null
null
05/22/2012 15:04:03
not a real question
From mdb Access application to windows application C# === I've to recode a small access mdb application using c#. What' the best way to re-use and store data now stored in access tables?
1
7,019,744
08/11/2011 01:09:03
753,603
05/14/2011 12:33:29
598
77
How to print value of a variable by NSLog?
A really basic question, I have recently started exploring Objective C and Trying to mess with one example code. However just for debugging purpose I want print value of NSString variable on console. How do I achieve this? Basically I am a java developer, So I am looking something similar as... String hello = "world!"; System.out.println(hello); My variable in this foreign language(Obj-C) is... NSString *hello = ...calling a method to return string... Any hint will be appreciated! Thank you
objective-c
ios
xcode4
null
null
null
open
How to print value of a variable by NSLog? === A really basic question, I have recently started exploring Objective C and Trying to mess with one example code. However just for debugging purpose I want print value of NSString variable on console. How do I achieve this? Basically I am a java developer, So I am looking something similar as... String hello = "world!"; System.out.println(hello); My variable in this foreign language(Obj-C) is... NSString *hello = ...calling a method to return string... Any hint will be appreciated! Thank you
0
3,716,903
09/15/2010 10:51:20
445,646
09/12/2010 16:05:54
1
0
How can we prevent our web sites from spammers..?
I have looked some web sites in which automatically scripts run by spammers. How can we prevent our web sites from that spammers. Any help or reference to the article. Thanks in Advance
spam-prevention
null
null
null
null
09/15/2010 11:08:36
off topic
How can we prevent our web sites from spammers..? === I have looked some web sites in which automatically scripts run by spammers. How can we prevent our web sites from that spammers. Any help or reference to the article. Thanks in Advance
2
5,234,838
03/08/2011 15:52:18
625,878
02/21/2011 02:18:00
11
1
How do i detect what device the user of my app is using
Hey guys my question is i want to detect if my user is using a iPhone 4 (For its camera flash) or any other iDevice .I know how to detect what version of iOS. or how would i detect the device has camera flash capabilities .
ios
device
detect
null
null
null
open
How do i detect what device the user of my app is using === Hey guys my question is i want to detect if my user is using a iPhone 4 (For its camera flash) or any other iDevice .I know how to detect what version of iOS. or how would i detect the device has camera flash capabilities .
0
11,109,067
06/19/2012 20:41:06
1,145,827
01/12/2012 15:23:20
53
7
I need an explaination on this
I have to rewrite a web application and there is some javascript code that I was trying to understand. There is this simple function function declareVars(value) { this.value = value; } That is called this way var frequency_factor = new declareVars(1); Then, there are things like frequency_factor.value = 1; And so, I was trying to understand why someone would do that instead of simply doing something like var frequency_factor = 1; Hope anyone can enlighten me on this. Thanks
javascript
null
null
null
null
06/19/2012 20:49:01
too localized
I need an explaination on this === I have to rewrite a web application and there is some javascript code that I was trying to understand. There is this simple function function declareVars(value) { this.value = value; } That is called this way var frequency_factor = new declareVars(1); Then, there are things like frequency_factor.value = 1; And so, I was trying to understand why someone would do that instead of simply doing something like var frequency_factor = 1; Hope anyone can enlighten me on this. Thanks
3
3,700,349
09/13/2010 12:28:11
313,106
04/09/2010 19:16:28
121
8
Simple URL Rewrite
Using http://www.urlrewriting.net/ I want /File1.aspx to be /File1 Ive been trying like this: <add name="Rule1" virtualUrl="~/File1" desinationUrl="~/File1.aspx" rewriteUrlParameter="ExcludeFromClientQueryString" ignoreCase="true" /> How do i do it?
asp.net
web-config
url-rewriting
null
null
null
open
Simple URL Rewrite === Using http://www.urlrewriting.net/ I want /File1.aspx to be /File1 Ive been trying like this: <add name="Rule1" virtualUrl="~/File1" desinationUrl="~/File1.aspx" rewriteUrlParameter="ExcludeFromClientQueryString" ignoreCase="true" /> How do i do it?
0
10,928,003
06/07/2012 08:07:35
1,441,614
06/07/2012 07:52:27
1
0
Moving stored procedure from Firebird to MS SQL
There are databases on firebird and MS SQL. I have working stored procedure in firebird. Question is: How to translate it into MS SQL syntax... begin IF ((:PHONE_N is NULL) or (STRLEN(:PHONE_N)<1)) THEN BEGIN O_PHONE_N = NULL; EXIT; END IF (STRLEN(PHONE_N) > 3) THEN BEGIN O_PHONE_N = '(' || SUBSTR(:PHONE_N, 1, 3) || ') '; PHONE_N = SUBSTR(:PHONE_N, 4, STRLEN(:PHONE_N)); IF (STRLEN(:PHONE_N)> 3) THEN begin O_PHONE_N = O_PHONE_N || SUBSTR(:PHONE_N, 1, 3); PHONE_N = SUBSTR(:PHONE_N, 4, STRLEN(:PHONE_N)); IF (STRLEN(:PHONE_NUMBER)> 0) THEN O_PHONE_N = O_PHONE_N || '-' ||:PHONE_N; END ELSE O_PHONE_N = :O_PHONE_N || :PHONE_N; END ELSE O_PHONE_N = :PHONE_N; end
sql
null
null
null
null
06/07/2012 14:19:45
too localized
Moving stored procedure from Firebird to MS SQL === There are databases on firebird and MS SQL. I have working stored procedure in firebird. Question is: How to translate it into MS SQL syntax... begin IF ((:PHONE_N is NULL) or (STRLEN(:PHONE_N)<1)) THEN BEGIN O_PHONE_N = NULL; EXIT; END IF (STRLEN(PHONE_N) > 3) THEN BEGIN O_PHONE_N = '(' || SUBSTR(:PHONE_N, 1, 3) || ') '; PHONE_N = SUBSTR(:PHONE_N, 4, STRLEN(:PHONE_N)); IF (STRLEN(:PHONE_N)> 3) THEN begin O_PHONE_N = O_PHONE_N || SUBSTR(:PHONE_N, 1, 3); PHONE_N = SUBSTR(:PHONE_N, 4, STRLEN(:PHONE_N)); IF (STRLEN(:PHONE_NUMBER)> 0) THEN O_PHONE_N = O_PHONE_N || '-' ||:PHONE_N; END ELSE O_PHONE_N = :O_PHONE_N || :PHONE_N; END ELSE O_PHONE_N = :PHONE_N; end
3
7,103,369
08/18/2011 06:40:40
829,066
07/05/2011 06:03:24
76
4
What is the difference between Live IP and STATIC IP?
I came across these tyerms LIVE IP and STATIC IP and did R&D on them but couldnt find usefull info abt the main diffrnce in them. can anyone plz tell me that basic main diffrnce in simple words :)
ip
address
null
null
null
11/27/2011 22:21:20
off topic
What is the difference between Live IP and STATIC IP? === I came across these tyerms LIVE IP and STATIC IP and did R&D on them but couldnt find usefull info abt the main diffrnce in them. can anyone plz tell me that basic main diffrnce in simple words :)
2