text stringlengths 0 30.5k | title stringclasses 1
value | embeddings listlengths 768 768 |
|---|---|---|
lblHeader.Text = _columnName;
container.Controls.Add(lblHeader);
break;
case ListItemType.Item:
Label lblItem = new Label();
lblItem.DataBinding += new EventHandler(lblItem_DataBinding); | [
-0.1591116040945053,
-0.5280186533927917,
0.4628286063671112,
-0.0522734709084034,
0.11797671020030975,
-0.07991518080234528,
0.04102117940783501,
-0.5875621438026428,
-0.5304784178733826,
-0.3857840597629547,
-0.45298728346824646,
0.3683030605316162,
-0.5506887435913086,
0.107275053858757... | |
lblItem.ID = "lbl" + _columnName;
lblItem.ClientIDMode = ClientIDMode.Predictable;
container.Controls.Add(lblItem);
DropDownList ddl = new DropDownList();
ddl.DataBinding += new EventHandler(ddl_DataBinding); | [
-0.20180773735046387,
-0.6440405249595642,
0.664188802242279,
-0.10333403944969177,
0.06404655426740646,
-0.05832519009709358,
0.023466892540454865,
-0.28626152873039246,
-0.4690593183040619,
-0.48830005526542664,
-0.32420095801353455,
0.5250391960144043,
-0.6943196058273315,
-0.1494421958... | |
ddl.ID = "ddl" + _columnName;
ddl.Visible = false;
ddl.DataSource = new string[] { "Hello", "World" };
container.Controls.Add(ddl);
break;
}
}
void ddl_DataBinding(object | [
-0.18219555914402008,
-0.29548075795173645,
0.5751895308494568,
-0.01892455294728279,
0.18443600833415985,
0.03518456965684891,
0.2321285903453827,
-0.09214864671230316,
-0.29078781604766846,
-0.6860474348068237,
-0.4377586841583252,
0.35857436060905457,
-0.3718738555908203,
0.656557559967... | |
sender, EventArgs e)
{
}
void lblItem_DataBinding(object sender, EventArgs e)
{
}
}
protected void Page_Load(object sender, EventArgs e)
{
DataTable dt = new DataTable();
dt.Columns.Add("Name");
DataRow oItem = dt.NewRow();
oItem[0] = "Deepu";
dt.Rows.Add(oItem);
oIte... | [
-0.10680866241455078,
-0.20746420323848724,
0.5679762959480286,
-0.18596479296684265,
0.167814239859581,
0.3049049973487854,
0.4446915090084076,
-0.2214028537273407,
-0.1034996509552002,
-0.7616147994995117,
-0.5679348707199097,
0.4883013069629669,
-0.35020795464515686,
0.353702574968338,
... | |
BoundField nameColumn = new BoundField();
nameColumn.DataField = "Name";
nameColumn.HeaderText = "Name";
gv.Columns.Add(nameColumn);
TemplateField TmpCol = new TemplateField();
TmpCol.HeaderText = "Template Column";
gv.Columns.Add(TmpCol);
TmpCol.ItemTemplate = new CustomGridViewColumn(List... | [
-0.09801410883665085,
-0.3560902774333954,
0.842756986618042,
-0.07504082471132278,
-0.15874867141246796,
0.2150263637304306,
0.1816686987876892,
-0.5376721024513245,
-0.32368338108062744,
-0.5397859215736389,
-0.3298187255859375,
0.5023614168167114,
-0.45854315161705017,
0.244268521666526... | |
item.FindControl("ddlTest") as DropDownList;
if (ddl != null)
{
ddl.Visible = true;
}
var lbl = item.FindControl("lbl") as Label;
if (lbl != null)
{
lbl.Text = "hello";
} | [
-0.39877912402153015,
-0.3958079218864441,
0.6028375029563904,
-0.2915695309638977,
-0.015531363897025585,
0.2635975778102875,
0.45007210969924927,
-0.15192343294620514,
-0.2765970826148987,
-0.5565050840377808,
-0.5754850506782532,
0.5586305856704712,
-0.39532577991485596,
0.3937123119831... | |
}
}
<form id="form1" runat="server">
<asp:Button ID="Button1" runat="server" onclick="Button1_Click" Text="Button" />
</form>
```
Thanks
Deepu | [
-0.09990040957927704,
0.09531691670417786,
0.13839781284332275,
0.07655422389507294,
0.11644881963729858,
-0.09371914714574814,
0.3972737789154053,
0.05091466009616852,
0.30430859327316284,
-0.5039046406745911,
-0.24863454699516296,
0.5476331114768982,
0.10830140113830566,
0.16913349926471... | |
I have a schema similar to
```
{
'user_id' : 1,
'marks' : [10, 40]
}
```
I want to find the number of users who have scored marks between 20 and 30 at least once.
I tried the following query
```
db.users.count({
'marks' : {$gte: '20', $lt: '30'}
})
```
But this also included those with marks more than 3... | [
0.2435813993215561,
0.2433377504348755,
0.23988136649131775,
-0.010131463408470154,
-0.3836138844490051,
0.23273351788520813,
0.21961697936058044,
-0.4975978434085846,
-0.19381459057331085,
-0.6584801077842712,
0.2181386947631836,
0.1823650449514389,
0.1366204172372818,
0.06374277919530869... | |
: [ 22, 33 ] }
```
Then you would expect to filter user\_ids 3 and 4, a count of 2.
The simplest way to run your query is to do:
```
db.scores.count({'marks':{$in: [20,21,22,23,24,25,26,27,28,29,30]}})
```
But not pretty... | [
-0.06598234921693802,
0.09096966683864594,
0.24517956376075745,
-0.04723186045885086,
0.0035410539712756872,
0.16832858324050903,
0.3611260652542114,
-0.4434112310409546,
0.053160615265369415,
-0.6005495190620422,
-0.11583346873521805,
0.1766006499528885,
-0.3542947471141815,
-0.0838656350... | |
Everything is in the title. I have many LaTeX files written with the rather obsolete syntax `$foo$` and `$$bar$$` that I wish to convert respectively in `\\(foo\\)` and `\\[bar\\]`. I am using vim so I guess a regular expression will do but a script would also be perfectly fine. I have been looking around but without s... | [
0.3863408863544464,
0.3489558696746826,
0.19271498918533325,
0.11697175353765488,
-0.132283553481102,
-0.22019532322883606,
0.19293150305747986,
-0.061215706169605255,
-0.031077807769179344,
-0.31756824254989624,
-0.4702852964401245,
0.6609857678413391,
-0.34981435537338257,
0.131410777568... | |
you want is a new schema field type. Tridion schemas support the following field types:
* Text fields
* Number fields
* Date fields
* Embedded Schemas
* External links
* Multimedia links
* Component links
As far as I know, adding to this list is not possible.
Why do you need a new field type? Perhaps with some more... | [
0.2805800139904022,
0.1555231660604477,
0.48574671149253845,
0.27181077003479004,
-0.4235145151615143,
0.024657009169459343,
-0.018046921119093895,
-0.32865849137306213,
-0.32887986302375793,
-0.4446112811565399,
0.09118792414665222,
0.769724428653717,
-0.48165130615234375,
-0.001181386644... | |
It can only be set and read using the API.
More details can be found [here](https://www.sdltridionworld.com/community/2011_extensions/appdata.aspx) and [here](http://tridionfanboy.wordpress.com/category/sdl-tridion/2011/core-service-2011/).
If you don't think this will help you, please provide some more information ... | [
0.3745923936367035,
-0.288194477558136,
0.4186033010482788,
-0.08627372235059738,
-0.3967698812484741,
-0.1508292257785797,
0.3141886293888092,
-0.36562126874923706,
0.016060855239629745,
-0.1552739292383194,
-0.24577537178993225,
0.5160267949104309,
-0.03173460066318512,
-0.18259727954864... | |
I want to draw a vertical line between the SectionIndex column and the cell content view. How can I do this?

Refer to this post:
[how to add vertical lines to a table view in iphone sdk?](https://stackoverflow.com/questions/3836... | [
0.24366359412670135,
-0.26824215054512024,
0.6352792978286743,
-0.08120644837617874,
-0.003456643084064126,
0.25351351499557495,
0.2698252499103546,
-0.04845994710922241,
-0.45364290475845337,
-0.6733902096748352,
0.010799963027238846,
0.3023844361305237,
-0.2643350064754486,
-0.3683753013... | |
UI is ideally suited to use on the iPhone. There are
> lots of examples on how to add multiple items to a UITableViewCell.
> However, I needed to present some data in a more traditional
> spreadsheet style grid. The results worked well and enabled me to pack
> a lot of information on the screen that was very hard t... | [
0.04234310984611511,
-0.21123917400836945,
0.7004401087760925,
0.04760150983929634,
-0.15207098424434662,
0.04766064137220383,
0.08587343245744705,
-0.09699007868766785,
-0.15760460495948792,
-0.9704433679580688,
0.20390358567237854,
0.47065144777297974,
-0.19385424256324768,
0.03054085373... | |
we
> can override drawrect and draw our lines** and to add an array to hold a
> list of positions where we’ll draw the lines.
```
@interface MyTableCell : UITableViewCell {
NSMutableArray *columns;
}
- (void)addColumn:(CGFloat)position;
@end
```
> In this simplified example we’ll leave the positioning of the a... | [
0.23167136311531067,
-0.1255170702934265,
0.9818072319030762,
0.1812671720981598,
0.0013086484977975488,
-0.05532829463481903,
0.09673826396465302,
-0.3102385997772217,
0.10647740215063095,
-1.0621941089630127,
-0.048609666526317596,
0.36115196347236633,
-0.21884770691394806,
-0.0375678613... | |
override drawRect. In it we grab the current graphics context
> and set the line color and width. Then we iterate over our columns
> array drawing a line from the top of the cell row to the bottom at
> each position stored in the array.
```
- (void)drawRect:(CGRect)rect {
CGContextRef ctx = UIGraphicsGetCurrent... | [
-0.08789444714784622,
-0.19763702154159546,
0.9622264504432678,
-0.17239496111869812,
0.0749533548951149,
0.07768699526786804,
0.002780244220048189,
-0.4839964807033539,
-0.03994503989815712,
-0.601696789264679,
-0.2064908891916275,
0.5086087584495544,
-0.5009838342666626,
0.00112523301504... | |
CGFloat f = [((NSNumber*) [columns objectAtIndex:i]) floatValue];
CGContextMoveToPoint(ctx, f, 0);
CGContextAddLineToPoint(ctx, f, self.bounds.size.height);
}
CGContextStrokePath(ctx);
[super drawRect:rect];
}
To add columns to the view just call
[cell addColumn:50];
when you’re building ... | [
-0.019545139744877815,
-0.2673264443874359,
1.0761164426803589,
-0.4195447266101837,
-0.0010674387449398637,
0.3087833523750305,
0.04441974684596062,
-0.5265235900878906,
-0.4065825343132019,
-0.5652276277542114,
0.019711574539542198,
0.56432044506073,
-0.35050326585769653,
0.0389349572360... | |
= [[[MyTableCell alloc] initWithFrame:CGRectZero reuseIdentifier:MyIdentifier] autorelease];
UILabel *label = [[[UILabel alloc] initWithFrame:CGRectMake(0.0, 0, 30.0,
tableView.rowHeight)] autorelease];
[cell addColumn:50];
label.tag = ... | [
-0.21135473251342773,
-0.05886688455939293,
0.6511450409889221,
-0.24175940454006195,
0.32675057649612427,
0.1611870527267456,
0.27746284008026123,
-0.49266377091407776,
0.0797126442193985,
-0.5489526987075806,
-0.4890937805175781,
0.34048566222190857,
-0.3672867715358734,
0.13711619377136... | |
label.font = [UIFont systemFontOfSize:12.0];
label.text = [NSString stringWithFormat:@"%d", indexPath.row];
label.textAlignment = UITextAlignmentRight;
label.textColor = [UIColor blueColor];
label.autoresizingMask = UIViewAutoresizingFlexibleRightMargin |
UIViewAutoresizingFlexib... | [
-0.27683764696121216,
-0.08795034885406494,
0.6007118225097656,
-0.02032577060163021,
-0.05160512775182724,
0.2596997320652008,
0.45376935601234436,
-0.3318771719932556,
-0.11663225293159485,
-0.7312081456184387,
-0.2799445390701294,
0.3119226396083832,
-0.2874213755130768,
0.3466769456863... | |
tableView.rowHeight)] autorelease];
[cell addColumn:120];
label.tag = VALUE_TAG;
label.font = [UIFont systemFontOfSize:12.0];
// add some silly value
label.text = | [
0.11330544948577881,
-0.14308038353919983,
0.45789673924446106,
-0.04890918731689453,
0.34483155608177185,
-0.15187659859657288,
0.3411323130130768,
-0.17153145372867584,
-0.19353921711444855,
-0.3815363049507141,
-0.32719945907592773,
0.2447195202112198,
-0.5181270241737366,
-0.1013291999... | |
[NSString stringWithFormat:@"%d", indexPath.row * 4];
label.textAlignment = UITextAlignmentRight;
label.textColor = [UIColor blueColor];
label.autoresizingMask = UIViewAutoresizingFlexibleRightMargin |
UIViewAutoresizingFlexibleHeight;
[cell.contentView addSubview:label];
}
... | [
-0.1742354780435562,
-0.008821106515824795,
0.6116282343864441,
-0.18425250053405762,
0.10638993233442307,
0.0570816807448864,
0.5790831446647644,
-0.17921580374240875,
-0.034675441682338715,
-0.81767338514328,
-0.19655513763427734,
0.4339646100997925,
-0.1519152671098709,
0.34845548868179... | |
I tried to install Ruby 1.9.3 using RVM. It seems that it installed without error, but the version of Ruby still remains 1.8.7.
Has anyone else encountered this situation?
```
AlexHo@server:~$ rvm install 1.9.3
Already installed ruby-1.9.3-p125.
To reinstall use:
rvm reinstall 1.9.3
AlexHo@server:~$ rvm reinstall... | [
0.19496950507164001,
0.30113282799720764,
0.6264021992683411,
-0.08855127543210983,
-0.22285832464694977,
-0.04494960233569145,
0.8418447375297546,
-0.32502609491348267,
-0.26182907819747925,
-0.4535052478313446,
-0.17717324197292328,
0.7324650883674622,
-0.49781689047813416,
0.19614328444... | |
/Users/AlexHo/.rvm/src/ruby-1.9.3- p125
ruby-1.9.3-p125 - #extracted to /Users/AlexHo/.rvm/src/ruby-1.9.3-p125
ruby-1.9.3-p125 - #configuring
ruby-1.9.3-p125 - #compiling
ruby-1.9.3-p125 - #installing
Removing old Rubygems files...
Installing rubygems-1.8.17 for ruby-1.9.3-p125 ...
Installation of rubygems co... | [
0.1500030905008316,
0.11595544219017029,
0.6363212466239929,
-0.20703405141830444,
-0.37905770540237427,
0.13036014139652252,
0.8849514126777649,
-0.26921066641807556,
-0.404043048620224,
-0.26517757773399353,
-0.2981811463832855,
0.6722557544708252,
-0.46150076389312744,
0.071064308285713... | |
Anyone please help me to write test case for 100% code coverage for following trigger in apex
```
trigger ETicketAirlineUrlTrigger on E_Ticket__c (before insert, before update) {
for(E_Ticket__c etNew : Trigger.New)
{
if(etNew.Airline__c =='Virgin Australia')
{
etNew.Airlines_Url__c = '<a href="ht... | [
0.018694087862968445,
-0.03857918083667755,
0.46427664160728455,
0.29465287923812866,
0.32836198806762695,
-0.1329270601272583,
0.30219244956970215,
-0.17293766140937805,
-0.36479276418685913,
-0.661139965057373,
-0.21011695265769958,
0.4836408197879791,
-0.12891097366809845,
-0.1132613420... | |
etNew.Airlines_Url__c = '<a href="http://www.virginamerica.com/view-itinerary.html">Virgin America</a>';
}
else if(etNew.Airline__c =='US AIR')
{
etNew.Airlines_Url__c = '<a href="http://reservations.usairways.com/Default.aspx">US AIR</a>';
}
else if(etNew.Airline__c =='United Airlines')
... | [
0.28703850507736206,
0.07681570202112198,
0.4443990886211395,
0.07702171802520752,
0.3076687455177307,
0.4290016293525696,
0.263139933347702,
-0.23436717689037323,
-0.13505242764949799,
-0.6178504824638367,
-0.5050285458564758,
0.3850414752960205,
-0.408524751663208,
0.15239658951759338,
... | |
{
etNew.Airlines_Url__c = '<a href="http://www.thaiair.com/AWR_PREM/view-trip.jsp">Thai Air</a>';
}
else if(etNew.Airline__c =='Swiss Airlines')
{
etNew.Airlines_Url__c = '<a href="http://www.swiss.com/web/EN/Pages/index.aspx?Country=US">Swiss Airlines</a>';
}
else if(etNew.Airline__... | [
-0.027669867500662804,
-0.102518230676651,
0.31392422318458557,
0.04635048285126686,
0.3022821247577667,
0.26788529753685,
0.28211337327957153,
-0.15314413607120514,
-0.23493589460849762,
-0.4772926867008209,
-0.5939934253692627,
0.010301275178790092,
-0.33217987418174744,
0.06122886762022... | |
}
else if(etNew.Airline__c =='Singapore Airlines')
{
etNew.Airlines_Url__c = '<a href="https://www.singaporeair.com/manageBooking-flow.form?execution=e1s1">Singapore Airlines</a>';
}
else if(etNew.Airline__c =='QATAR AIRWAYS')
{
etNew.Airlines_Url__c = '<a href="http://www.qatarairwa... | [
-0.1819026619195938,
0.006893974728882313,
0.24883589148521423,
0.015120688825845718,
0.3774966895580292,
0.388210654258728,
-0.07608354091644287,
-0.14468395709991455,
-0.2794417440891266,
-0.2366533726453781,
-0.5385091304779053,
0.2536033093929291,
-0.2394741177558899,
0.126922369003295... | |
= '<a href="https://book.malaysiaairlines.com/itd/itd/lang/en/reservations">Malaysia</a>';
}
else if(etNew.Airline__c =='Lufthansa')
{
etNew.Airlines_Url__c = '<a href="http://www.lufthansa.com/online/portal/lh/us/my_account/my_bookings">Lufthansa</a>';
}
else if(etNew.Airline__c =='KLM - Ro... | [
-0.20782598853111267,
0.23716890811920166,
0.5757511854171753,
-0.014001085422933102,
0.3021710515022278,
0.4233265221118927,
0.08869580924510956,
-0.3301781415939331,
-0.15969058871269226,
-0.24554398655891418,
-0.47960931062698364,
0.22680173814296722,
-0.09171360731124878,
0.21759940683... | |
{
etNew.Airlines_Url__c = '<a href="http://www.etihadairways.com/sites/etihad/_layouts/etihad/obe/RetrieveBooking.aspx">Etihad Airlines</a>';
}
else if(etNew.Airline__c =='Emirates')
{
etNew.Airlines_Url__c = '<a href="https://fly.emirates.com/MYB/MMBLogin.aspx">Emirates</a>';
}
else... | [
-0.04686666280031204,
0.03881020098924637,
0.5132796764373779,
0.10957100987434387,
0.2330741137266159,
0.2831340730190277,
-0.12763699889183044,
-0.31369253993034363,
-0.155870258808136,
-0.5980745553970337,
-0.3728472888469696,
0.39772239327430725,
-0.2978403866291046,
0.1750277876853943... | |
else if(etNew.Airline__c =='Continental Airlines')
{
etNew.Airlines_Url__c = '<a href="http://www.continental.com/web/en-US/apps/reservation/default.aspx">Continental Airlines</a>';
}
else if(etNew.Airline__c =='Cathay Pacific')
{
etNew.Airlines_Url__c = '<a href="http://www.cathaypacifi... | [
-0.16895927488803864,
-0.07929613441228867,
0.30005213618278503,
0.19553953409194946,
0.5675272941589355,
0.32788747549057007,
0.07718763500452042,
-0.2150682955980301,
-0.2694905400276184,
-0.294587641954422,
-0.5359304547309875,
0.07624239474534988,
-0.354731023311615,
0.3279766440391540... | |
href="https://www.aa.com/reservation/findReservationAccess.do">American Airlines</a>';
}
else if(etNew.Airline__c =='All Nippon')
{
etNew.Airlines_Url__c = '<a href="https://aswbe-i.ana.co.jp/p_per/sky_ip_per_jp/preReConfirmSearchPnr.do?CONNECTION_KIND=LAX&LA...">All Nippon</a>';
}
else if(e... | [
0.02485189028084278,
-0.031295713037252426,
0.5283637642860413,
0.08484983444213867,
-0.021935250610113144,
0.44089794158935547,
0.15952585637569427,
-0.5431686043739319,
-0.1386401206254959,
-0.6294351816177368,
-0.6416035890579224,
0.2322217971086502,
-0.23958124220371246,
0.255078107118... | |
etNew.Airlines_Url__c = '<a href="https://flightbookings.airnewzealand.com/isbook_en_US/review/initNewWebCheckIn.do?workflowAction=...">Air New Zealand</a>';
}
else if(etNew.Airline__c =='Air France')
{
etNew.Airlines_Url__c = '<a href="https://www.airfrance.us/cgi-bin/AF/US/en/local/process/standar... | [
0.1508268266916275,
0.032054923474788666,
0.37898123264312744,
0.21246397495269775,
0.4803607761859894,
0.14164257049560547,
0.3597981631755829,
-0.3577876687049866,
-0.04889150708913803,
-0.8632593154907227,
-0.6469120383262634,
0.30983439087867737,
-0.03510241582989693,
-0.02805247344076... | |
oppNew.Name = 'Test Opp';
oppNew.StageName = 'To Be Searched';
oppNew.CloseDate = System.now().date();
insert oppNew;
E_Ticket__c et = new E_Ticket__c();
et.Airline__c = 'Virgin Australia';
et.Opportunity__c = oppNew.Id;
et.Airline__c = 'Virgin Atlantic';
insert et;
E_Ticket__c e... | [
0.008600550703704357,
-0.18412615358829498,
0.4532601535320282,
0.23090849816799164,
0.3075616657733917,
0.2859017848968506,
0.45768144726753235,
-0.3452802896499634,
-0.3434314429759979,
-0.7342091798782349,
-0.36418426036834717,
0.36801788210868835,
-0.28498172760009766,
-0.0777102857828... | |
be appreciated
Thanks..
Create the image those images with an unique class name
```
<img class="imgCollapse" id="imgCollapse'+TaskDataObj[i].TaskId+'".......
```
Then bind a live click event for that img class
```
$(".imgCollapse").live("click",function(event){
event.preventDefault();
taskID = $(this).at... | [
-0.0337856262922287,
-0.06994086503982544,
0.8436163067817688,
-0.15696044266223907,
0.09049627929925919,
0.03088599070906639,
0.3505445420742035,
-0.17737698554992676,
-0.011286238208413124,
-0.7647776007652283,
-0.27592533826828003,
0.8550089597702026,
-0.23893971741199493,
-0.0639441460... | |
Using the following query I am looking for a solution to get the latest record that having some conditions.
But it gives me the first record, not the latest. I think its only considering the group by
Please advise me
```
SELECT * FROM `contacts` WHERE `id_receiver`=1 GROUP BY `id_thread` ORDER BY created DESC
id i... | [
0.33306556940078735,
0.03433603420853615,
0.6221713423728943,
0.0029221870936453342,
0.1087002232670784,
-0.13591629266738892,
0.01132769975811243,
-0.5723516345024109,
-0.3418032228946686,
-0.7063812613487244,
0.16687430441379547,
0.2695837616920471,
-0.23696301877498627,
0.51787471771240... | |
1 2012-03-24 13:44:48
2 4 4 1 5 2012-04-26 13:46:05
3 2 2 | [
0.19793613255023956,
0.09887101501226425,
0.19611290097236633,
0.14260903000831604,
-0.19979292154312134,
-0.03023630566895008,
0.5325976610183716,
-0.2894221842288971,
0.06803452968597412,
-0.8491155505180359,
0.020347028970718384,
0.0029890357982367277,
-0.15734648704528809,
0.1397246718... | |
51 1 2012-04-09 12:12:30
```
Required output
```
id id_sender id_thread sender_email id_receiver created(datetime)
3 2 2 51 1 | [
0.12056998908519745,
-0.018809247761964798,
0.535266637802124,
-0.10713580995798111,
0.030485400930047035,
-0.10275295376777649,
0.3258865475654602,
-0.5208543539047241,
0.00420188345015049,
-0.6341271996498108,
-0.5501997470855713,
-0.06626123934984207,
-0.34912025928497314,
-0.0588302165... | |
2012-04-09 12:12:30
```
I had done a test just swap the order by and group by , giving me an erros.
Anybody can just look in to this?. Thanks.
**EDIT** Edited question, forget to write id\_thread
How can you `GROUP BY id_thread` when there is no `id_thread` column in your table?
```
SELECT *
FROM contacts
WHERE ... | [
0.002848052652552724,
0.08763245493173599,
0.21368546783924103,
0.11176524311304092,
0.057855527848005295,
-0.16088075935840607,
0.48995569348335266,
-0.37896063923835754,
-0.5666850209236145,
-0.5992516875267029,
0.0732603520154953,
0.5549622774124146,
0.10252100974321365,
-0.077601060271... | |
--- removed
ORDER BY created DESC
LIMIT 1 --- only show one row
```
---
Based on your comments, what you want is the latest (ordered by `created`) row for every `id_thread`, which is a different and more complex query. There's even a tag for this kind of queries, named [`[greatest-n-per-gro... | [
-0.11165744811296463,
0.02621482126414776,
0.4208110570907593,
0.15516339242458344,
0.07900925725698471,
-0.10221243649721146,
-0.12946154177188873,
-0.21735388040542603,
-0.6310746073722839,
-0.42517828941345215,
-0.006720263976603746,
0.4411974251270294,
-0.39233148097991943,
0.117129474... | |
c.*
FROM contacts AS c
JOIN
( SELECT id_thread, MAX(created) AS created
FROM contacts
WHERE id_receiver = 1
GROUP BY id_thread
) AS g
ON (g.id_thread, g.created) = (c.id_thread, c.created)
WHERE c.id_receiver = 1
``` | [
0.26277539134025574,
-0.04368013143539429,
0.5720214247703552,
-0.09238951653242111,
0.012538401409983635,
0.030667364597320557,
-0.1278574913740158,
-0.5101174712181091,
-0.24803461134433746,
-0.3397071957588196,
-0.16971327364444733,
0.36872997879981995,
-0.5582035183906555,
0.3905041813... | |
I have android app . i should pass the data from android to web server with data security.Can any one suggest me to What are all the data security's can Provide.
How can you `GROUP BY id_thread` when there is no `id_thread` column in your table?
```
SELECT *
FROM contacts
WHERE id_receiver = 1
... | [
0.4384021759033203,
0.279903382062912,
0.36153119802474976,
0.05766281858086586,
0.03279759734869003,
0.2356848418712616,
0.11169373989105225,
-0.1900661289691925,
-0.3175532817840576,
-0.9222918748855591,
0.11491058021783829,
0.4848824143409729,
-0.2069341391324997,
-0.06298951059579849,
... | |
--- removed
ORDER BY created DESC
LIMIT 1 --- only show one row
```
---
Based on your comments, what you want is the latest (ordered by `created`) row for every `id_thread`, which is a different and more complex query. There's even a tag for this kind of queries, named [`[greatest-n-per-gro... | [
-0.01947980932891369,
0.16476404666900635,
0.44818100333213806,
0.0973847284913063,
0.17182742059230804,
-0.020212411880493164,
-0.1910814493894577,
-0.14985433220863342,
-0.6225565075874329,
-0.372615784406662,
0.0127608273178339,
0.573719322681427,
-0.35495930910110474,
0.104042068123817... | |
JOIN
( SELECT id_thread, MAX(created) AS created
FROM contacts
WHERE id_receiver = 1
GROUP BY id_thread
) AS g
ON (g.id_thread, g.created) = (c.id_thread, c.created)
WHERE c.id_receiver = 1
``` | [
0.30538588762283325,
-0.12166579812765121,
0.6848900318145752,
-0.03747913986444473,
0.15759101510047913,
-0.009614567272365093,
-0.13289958238601685,
-0.3730352222919464,
-0.24483218789100647,
-0.5117154121398926,
-0.05133717879652977,
0.23558492958545685,
-0.5880771279335022,
0.513774216... | |
In main.xml I would like to have a spinner1 with two radio buttons and a spinner2 with 3 checkboxes. I don't know how to define and create this spinners in Main.java.
Need some help.
**main.xml**
```
<Spinner
android:id="@+id/spinner1"
android:layout_width="match_parent"
android:layout_height="wrap_content"
/>
<Spinn... | [
-0.1447901576757431,
-0.13629955053329468,
0.6715208292007446,
-0.06449972093105316,
-0.08793908357620239,
0.21148113906383514,
0.007706570439040661,
-0.4551367461681366,
-0.27223458886146545,
-0.7807285189628601,
0.08076631277799606,
0.3938251733779907,
-0.4309501051902771,
0.154373660683... | |
this, R.array.spinner_array, android.R.layout.simple_spinner_item);
adapter.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
spinner.setAdapter(adapter);
```
Hope this will help you. | [
0.13386337459087372,
-0.4506090581417084,
0.5957190990447998,
0.04317675903439522,
0.04401484876871109,
-0.1308550238609314,
0.20128901302814484,
-0.22247134149074554,
-0.26030102372169495,
-0.7242827415466309,
-0.3367653787136078,
0.5843145847320557,
-0.3920130729675293,
-0.12148383259773... | |
When a new item is created using Tastypie, I want to be able to add it to a user's attribute which is a many-to-many field.
RIght now my obj\_create looks like this:
```
def obj_create(self, bundle, request=None, **kwargs):
return super(GoalResource, self).obj_create(bundle, request, user=request.user)
```
I w... | [
0.5512421727180481,
-0.22399386763572693,
0.39216744899749756,
-0.009101604111492634,
-0.1570386439561844,
0.0572235994040966,
0.1483815610408783,
-0.11758401989936829,
-0.19642001390457153,
-0.6968008875846863,
0.3399263918399811,
0.4374257028102875,
-0.5273169875144958,
0.359105616807937... | |
assuming you are using `tastypie.resources.ModelResource` as your base class, this should work:
```
def obj_create(self, bundle, request=None, **kwargs):
bundle = super(GoalResource, self).obj_create(
bundle, request, user=request.user)
user = request.user
user.goals.add( bundle.obj )
user.sav... | [
0.23246906697750092,
-0.49673110246658325,
0.4016372859477997,
0.09251057356595993,
-0.03441566601395607,
-0.128264382481575,
0.18146347999572754,
-0.2772287130355835,
-0.11035170406103134,
-0.7091260552406311,
-0.1673424392938614,
0.30656230449676514,
-0.5128566026687622,
0.21824085712432... | |
you need to make sure it does for above to work or you should add some error handling code for the case when it does not.
Hope this helps :) | [
0.19619885087013245,
0.2891790270805359,
0.11524821817874908,
0.35110896825790405,
0.3513561487197876,
-0.2924691140651703,
0.2041464000940323,
0.10589800775051117,
0.048060789704322815,
-0.5925220847129822,
0.10118816047906876,
0.8061466217041016,
0.047431766986846924,
-0.3745719790458679... | |
We are launching processes in bulk (say 100 instances) in JBPM5 at a time. And each and every tasks of the process are started and completed by external programs asynchronously. In this scenario, the JBPM engine is taking much time to generate the next task and thus the overall performance is getting affected. (eg: Its... | [
0.024385426193475723,
-0.2527501881122589,
0.49251919984817505,
-0.0010287006152793765,
-0.0053458260372281075,
0.1485603153705597,
0.43882670998573303,
-0.4730854332447052,
-0.210738405585289,
-0.7539291977882385,
0.026378465816378593,
0.360554575920105,
-0.07802177965641022,
-0.028128078... | |
Icon icon = new Icon() {
@Override public void paintIcon(Component c, Graphics g, int x, int y) {
Graphics2D g2 = (Graphics2D)g.create();
Point2D start = new Point2D.Float(0f, 0f);
Point2D end = new Point2D.Float(99f, 0f);
float[] dist = {0.0f, 0.5f, 1.0f};
Color[] c... | [
-0.36159661412239075,
-0.32691314816474915,
0.7923634052276611,
-0.11098610609769821,
-0.08832897245883942,
0.5337136387825012,
0.20155049860477448,
-0.17057980597019196,
-0.13868927955627441,
-0.670585036277771,
-0.17393182218074799,
0.6607467532157898,
-0.4095809757709503,
0.102183409035... | |
g2.setPaint(new LinearGradientPaint(start, end, dist, colors));
g2.fillRect(x, y, 100, 10);
g2.dispose();
}
@Override public int getIconWidth() { return 100; }
@Override public int getIconHeight() { return 10; }
};
JLabel label = new JLabel("GradientMatteBorder");
label.s... | [
-0.25913840532302856,
-0.439531534910202,
0.9627842307090759,
-0.12116986513137817,
-0.04758276790380478,
0.40035152435302734,
0.3677188754081726,
-0.6318542957305908,
-0.16713832318782806,
-0.564913272857666,
-0.4305512309074402,
0.3312067687511444,
-0.4737040400505066,
0.0078567117452621... | |
}
public static void main(String[] args) {
EventQueue.invokeLater(new Runnable() {
@Override public void run() {
createAndShowGUI();
}
});
}
public static void createAndShowGUI() {
JFrame f = new JFrame();
f.setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE);
f.getCont... | [
0.035041164606809616,
-0.35839343070983887,
0.6241861581802368,
-0.1742721050977707,
0.2746938467025757,
0.08610363304615021,
0.43046078085899353,
-0.16237948834896088,
-0.1963002234697342,
-0.6028034687042236,
-0.45397159457206726,
0.5274615287780762,
-0.4177485406398773,
0.31950196623802... | |
How can entire table cell be hyperlinked in html without javascript or jquery?
I tried to put href in td tag itself but its not working at least in chrome 18
```
<td href='http://www.m-w.com/dictionary/' style="cursor:pointer">
```
Try this:
HTML:
```
<table width="200" border="1" class="table">
<tr>
<... | [
0.04336605593562126,
0.10579384863376617,
0.87749844789505,
-0.22352567315101624,
-0.4624224305152893,
0.0733281821012497,
0.2844181954860687,
-0.49067965149879456,
-0.37974509596824646,
-0.9942876100540161,
-0.021333837881684303,
0.3666974902153015,
-0.2661634385585785,
-0.014616788364946... | |
In my project, I have 2 Entity objects (delegate for 2 tables in db) as below:
> * Tbl\_Person {ID, Name}
> * Tbl\_Class {ID, Name, PersonID}
In DAL, I create 2 classes for these Entities, and **write function GetList()**:
- Class Person:
```
public List<Tbl_Person> GetList()
{
using (var db = DatabaseHelper.Da... | [
0.009906405583024025,
-0.02487310767173767,
0.2252284288406372,
0.1606064736843109,
0.001992271514609456,
0.3997536599636078,
-0.019576357677578926,
-0.6130750775337219,
0.06594029068946838,
-0.6288448572158813,
0.022981218993663788,
0.19430039823055267,
-0.09257493168115616,
0.25650447607... | |
select info).ToList();
return _t.ToList<**Tbl_Person**>();
}
catch (Exception ex)
{
throw ex;
}
}
}
```
Class MyClass:
```
public List<Tbl_Class> GetList()
{
using (var db = DatabaseHelper.DataContext())
{
try | [
0.1459381878376007,
-0.36593320965766907,
0.11998914927244186,
-0.06431750953197479,
0.23787960410118103,
-0.023873966187238693,
0.37595441937446594,
-0.5538312196731567,
0.13105234503746033,
-0.5948424935340881,
-0.24724942445755005,
0.6183469295501709,
-0.7695292234420776,
0.307290583848... | |
{
var _t = (from info in db.**tbClass**
select info).ToList();
return _t.ToList<**Tbl_Class**>();
}
catch (Exception ex)
{ | [
0.31641027331352234,
-0.5567153096199036,
-0.04374793916940689,
-0.1771603375673294,
0.15129294991493225,
0.19249732792377472,
0.33928728103637695,
-0.5389856100082397,
0.0030370152089744806,
-0.3924829363822937,
-0.2670596241950989,
0.7749197483062744,
-0.6411668062210083,
0.1312540918588... | |
throw ex;
}
}
}
```
If I use 2 classes, I can use GetList() to get list object correctly.
But it seems we have duplicate function GetList() here. What I want just is **only 1 function GetList() like this**:
```
public List<T> GetList()
{
using (var db = DatabaseHelper.DataContext())
{
try... | [
0.1711365282535553,
-0.28353068232536316,
0.22216179966926575,
-0.0640607550740242,
-0.06900781393051147,
-0.050719182938337326,
0.4143525958061218,
-0.4441639184951782,
-0.06750081479549408,
-0.7300658226013184,
0.027593813836574554,
0.7527897357940674,
-0.5216128826141357,
0.095096170902... | |
select info).ToList();
return _t.ToList<**T**>();
}
catch (Exception ex)
{
throw ex;
}
}
}
```
Firstly, get rid of the *pointless* try/catch blocks. Each of those methods is twice as long as it needs | [
0.38194936513900757,
-0.5032925009727478,
0.06610018759965897,
-0.16791801154613495,
0.20998242497444153,
-0.18055810034275055,
0.23297277092933655,
-0.5704699158668518,
-0.16837160289287567,
-0.5347660779953003,
-0.05237536504864693,
0.6055870056152344,
-0.5696176886558533,
0.007061580661... | |
to be, because you're catching exceptions and just rethrowing them - but losing information at the same time! (If you must rethrow, use just `throw;` instead of `throw ex;`.)
Secondly, there's absolutely no point in using a query expression here. You're just interested in the whole table. (Are you *sure* you want to f... | [
-0.014050240628421307,
-0.2218877673149109,
0.09566634893417358,
-0.22822187840938568,
-0.15691865980625153,
-0.043624017387628555,
0.02205837331712246,
-0.329465389251709,
-0.41387754678726196,
-0.4367617964744568,
-0.15106701850891113,
0.39118248224258423,
-0.440463662147522,
-0.25341242... | |
using (var db = DatabaseHelper.DataContext())
{
return db.tbClass.ToList();
}
}
// In Person
public List<Tbl_Person> GetList()
{
using (var db = DatabaseHelper.DataContext())
{
return db.tbPerson.ToList();
}
}
```
Now you *could* remove the redundancy here using [`DataContext.GetT... | [
-0.2552008032798767,
0.008555768989026546,
0.025982702150940895,
-0.1266310214996338,
0.04976393282413483,
0.11969280242919922,
0.2963995039463043,
-0.5171682238578796,
-0.2198205590248108,
-0.7009719610214233,
-0.3625047504901886,
0.5524300336837769,
-0.37178298830986023,
0.34553384780883... | |
Person
public List<Tbl_Person> GetList()
{
return DatabaseHelper.GetList<Tbl_Person>();
}
```
It's not really clear whether you *need* the methods in the individual classes...
(In addition to all of this, I'd strongly encourage you to rename your types to remove the `Tbl_` prefix from the mapping. It looks prett... | [
-0.04634767770767212,
-0.19690410792827606,
-0.255246639251709,
0.09842522442340851,
-0.11945343017578125,
0.10904514789581299,
0.5125223994255066,
-0.05976051837205887,
-0.11041952669620514,
-0.6284116506576538,
0.04386548697948456,
0.3708097040653229,
-0.5121448040008545,
0.2206299006938... | |
Does anybody know how to convert results from the magnetic-field sensor from an android device to coordinates using the [World Magnetic Model](http://www.ngdc.noaa.gov/geomag/WMM/DoDWMM.shtml)? Is there a webservice that does that?
You cannot do this.
First of all you want co-ordinates which means 2 values. Only one wh... | [
0.3838675320148468,
-0.08733555674552917,
0.544649600982666,
0.38540807366371155,
0.09535936266183853,
-0.2195921093225479,
0.19574512541294098,
0.22971762716770172,
-0.5310600399971008,
-0.37942612171173096,
0.05836324766278267,
0.08720487356185913,
-0.2620033323764801,
0.2163908481597900... | |
will change your field dramatically. Other magnetic sources like your phone ringing or electric wiring around will tell you that you travel from Brasil to Egypt when you come form Bathroom to Living room. | [
0.6724225878715515,
-0.04314170032739639,
0.5562241673469543,
0.4598335027694702,
0.46950778365135193,
-0.3704070746898651,
0.29990312457084656,
0.17769145965576172,
-0.31476277112960815,
-0.6355301141738892,
-0.17546238005161285,
-0.18286897242069244,
0.0033125204499810934,
0.275341719388... | |
I need to compare many files (some could be large, some are small) over the network.
So I am planning to hash every file on every client and send only the hash value over the network.
**The main goal here is performance**. This implies minimal network traffic. Security is not the issue.
**There should also be "ze... | [
0.01661832444369793,
0.11649616062641144,
0.37177202105522156,
0.08005192130804062,
-0.07934746146202087,
-0.3294087052345276,
0.18785466253757477,
0.15682540833950043,
-0.45906299352645874,
-0.9439484477043152,
0.001498358673416078,
0.5987536907196045,
0.06111642345786095,
0.0552361197769... | |
hash function is best for this task?
I was thinking to use a buffered reader and `MD5CryptoServiceProvider` (since CNG may not be available on all clients).
Is there a way to get better performance than that? (perhaps using some external library?)
It depends on the number of files you have.
The chance of a collisi... | [
-0.4087907671928406,
-0.14297914505004883,
0.20458725094795227,
0.12391003221273422,
-0.13520805537700653,
0.09960471093654633,
0.07515104860067368,
0.05378096178174019,
-0.2173794060945511,
-0.6722149848937988,
0.09776239097118378,
0.6344730257987976,
-0.30402544140815735,
0.0192712005227... | |
case you will want to use [**CRC32**](http://en.wikipedia.org/wiki/Cyclic_redundancy_check). CRC32 is very common but, depending on the number of files you have, might not be enough: you're guaranteed to have a collision at ~4,3 billion messages (32 effective bits), but in practice you might encounter your first collis... | [
-0.35592836141586304,
0.24516110122203827,
0.24074536561965942,
0.010280353017151356,
-0.14324340224266052,
-0.3195651173591614,
0.324015349149704,
-0.03904308006167412,
-0.4149399697780609,
-0.7426750659942627,
-0.1582910269498825,
0.46198299527168274,
-0.35201501846313477,
-0.01607041060... | |
sacrificing speed you will want cryptographic hash functions, of which MD5 (128 bits), SHA-1 (160 bits) and SHA-2 (usually SHA-256 or SHA-512) are the most widely used and have fast implementations. Very efficient hash collision finding algorithms for MD5 are available, but if you input random messages you'll get as cl... | [
-0.1963043361902237,
-0.05640939995646477,
0.36703741550445557,
0.2714851200580597,
0.08238030225038528,
0.05480385944247246,
0.21437785029411316,
-0.14428676664829254,
-0.2770267724990845,
-0.4029982388019562,
-0.2107054889202118,
0.49269899725914,
-0.29245278239250183,
0.0808250680565834... | |
I am relatively new to programming. I need to calculate the aspect ratio(16:9 or 4:3) from a given dimension say axb. How can I achieve this using C#. Any help would be deeply appreciated.
```
public string AspectRatio(int x, int y)
{
//code am looking for
return ratio
}
```
Thanks.
You need to find Greatest Commo... | [
-0.18631869554519653,
0.06207549199461937,
0.6888514757156372,
-0.11490105837583542,
-0.17132382094860077,
0.28811341524124146,
0.02219526283442974,
-0.17770163714885712,
-0.3625727891921997,
-0.6166695952415466,
0.006014276295900345,
0.7332492470741272,
-0.19675606489181519,
0.02266263589... | |
a = b;
b = Remainder;
}
return a;
}
return string.Format("{0}:{1}",x/GCD(x,y), y/GCD(x,y));
```
**PS**
If you want it to handle something like 16:10 (which can be divided by two, 8:5 will be returned using method above) you need to have a table of predefined `((float)x)/y`-aspect ratio pairs | [
0.2913682758808136,
-0.0419168584048748,
0.42110881209373474,
-0.17276519536972046,
-0.020093794912099838,
0.38512474298477173,
-0.1886817365884781,
-0.5440177917480469,
-0.16953855752944946,
-0.3195568025112152,
-0.23766155540943146,
0.672105610370636,
-0.2061554193496704,
-0.122395433485... | |
I've an ArrayList of Line Objects called 'lines'. I made my own line class to draw lines with some constraints. It involves selecting two points in a panel and a line is drawn connecting the two points. Everytime a line is created, it is added to the 'lines'. The lines are drawn in a panel.
The paint function in my p... | [
0.15350793302059174,
-0.3533632457256317,
0.6347668766975403,
-0.2739323079586029,
-0.1776779294013977,
0.5672025084495544,
-0.1921953409910202,
-0.09219563752412796,
-0.08967036753892899,
-0.7646950483322144,
-0.014098713174462318,
0.24249102175235748,
-0.18983817100524902,
-0.02757081761... | |
r.paint((Graphics2D)g);
}
}
```
And everytime two points are clicked on the panel, a new line is created.
```
class Board extends JPanel{
public void placeLine(){
Point p1,p2;
JLabel l1,l2;
...
lines.add(new Line(p1,p2,l1,l2));
this.repaint();
}
public void deleteLine(Line l){
lines.remov... | [
-0.2191493809223175,
-0.20506173372268677,
0.6905887722969055,
-0.41480305790901184,
0.01574883982539177,
0.381041020154953,
0.17099028825759888,
-0.24205633997917175,
-0.3759598433971405,
-0.5869343876838684,
-0.43228474259376526,
0.29563575983047485,
-0.42905253171920776,
0.0385457985103... | |
for event changes in ArrayLists. Suggest an example for doing this.
And i'm really sorry for not posting it as an SSCCE.. It is a huge project and it is almost impossible to create an SSCCE.
Open the page in incognito mode in Chrome (ctrl + shift + n ) just to make sure the page is loading the updated css file. | [
0.36734357476234436,
-0.16967330873012543,
0.4600101113319397,
-0.2652435302734375,
-0.5719687342643738,
-0.4974499046802521,
0.5384026169776917,
0.5102105736732483,
-0.30288615822792053,
-1.0227185487747192,
-0.11723043769598007,
0.5167257189750671,
-0.5352945923805237,
0.1181556433439254... | |
till now i was using drawable to populate marker on my map .Now i was wondering it would be cool if i could display custom imageview as a marker in map.
till now i am doing it like
```
itemized= new Itemazide(drawable, mContext);
```
i want to achieve something like
 library to achieve some similar effect.
**EDIT:**
Now that you've shown what you're trying to achieve I think you should override `draw()` in your `OverlayItem` and in t... | [
0.36060765385627747,
-0.030690614134073257,
0.536163866519928,
-0.03487679734826088,
-0.08857884258031845,
-0.23161765933036804,
0.1506536453962326,
-0.06659217923879623,
-0.18713806569576263,
-0.6817724704742432,
0.28339844942092896,
0.7851762771606445,
-0.23168617486953735,
0.00992677453... | |
I am developing an application in cakephp. In this application I am using saveAll() function at many different places to save multiple records. What is need is to create a callback function which automatically gets called after saveAll() is executed, as I think there is no predefined callback function in cakephp which ... | [
0.23919294774532318,
-0.029757468029856682,
0.19370578229427338,
0.002809048630297184,
0.13776788115501404,
0.12417372316122055,
0.14428946375846863,
0.024236494675278664,
-0.3537665605545044,
-0.928858757019043,
0.10776099562644958,
0.4427889585494995,
-0.26778510212898254,
0.059912402182... | |
patch png image. You can achieve this by providing your 9 patch images for both `EditText` and `Button` with 0 margin between them.
[Here](http://tekeye.biz/2012/android-9patch-files) is a nice tutorial about using 9 patch png.
Another post to consider is [Buttons with (niceley) stretched background.](http://www.andd... | [
0.11019954085350037,
-0.3564491868019104,
0.40476086735725403,
0.051878880709409714,
-0.14478826522827148,
0.39045748114585876,
-0.16799592971801758,
0.29021087288856506,
-0.5851914286613464,
-0.8591515421867371,
-0.013587926514446735,
0.40004467964172363,
-0.3741929829120636,
-0.340219318... | |
I want to convert the 1st letter of each line to lower case up to the end of the file. How can I do this using shell scripting?
I tried this:
```
plat=`echo $plat |cut -c1 |tr [:upper:] [:lower:]``echo $plat |cut -c2-`
```
but this converts only the first character to lower case.
My file looks like this:
```
Appl... | [
-0.0752207487821579,
0.13894672691822052,
0.2614479660987854,
-0.43449050188064575,
0.13860073685646057,
0.4578421413898468,
0.18917126953601837,
0.03373530134558678,
-0.14821858704090118,
-0.7018285393714905,
-0.3426544964313507,
0.7344679236412048,
-0.15796330571174622,
-0.28533178567886... | |
i used a javascript code for radiobtn check inside gridview. the code works fine in firefox browser. but in internet explorer (IE) the code is not working and the error says Javascript not implemented. my javascript code is
```
<script type="text/javascript">
function CheckOtherIsCheckedByGVID(rb) {
var ... | [
0.4585917592048645,
0.28563663363456726,
0.4648005962371826,
-0.5321572422981262,
0.14318953454494476,
-0.10700009018182755,
0.6717537045478821,
-0.2446022629737854,
0.09989411383867264,
-0.7333890795707703,
0.2703479528427124,
0.5324214696884155,
-0.522286593914032,
0.17986878752708435,
... | |
row.style.color = 'black';
}
var currentRdbID = rb.id;
parent = document.getElementById("<%= grdEventDetails.ClientID %>");
var items = parent.getElementsByTagName('input');
for (i = 0; i < items.length; i++) {
if (items[i].id != currentRdbID && items[i].type == "rad... | [
-0.1177629604935646,
-0.03142646327614784,
0.6226884722709656,
-0.42707332968711853,
0.3976489007472992,
0.08737185597419739,
0.5614124536514282,
-0.5686691403388977,
-0.01387740857899189,
-0.19471468031406403,
-0.4864007234573364,
0.8367099761962891,
-0.26716348528862,
0.6931519508361816,... | |
(items[i].checked) {
items[i].checked = false;
items[i].parentNode.parentNode.style.backgroundColor = 'white';
items[i].parentNode.parentNode.style.color = '#696969';
}
} | [
0.08024092018604279,
-0.04656495153903961,
-0.23699302971363068,
-0.03782934322953224,
0.3903670907020569,
0.3926103711128235,
0.7125104069709778,
0.044620756059885025,
-0.21304021775722504,
-0.4435257017612457,
-0.42353367805480957,
0.08346761018037796,
-0.38106659054756165,
0.48939672112... | |
}
}
</script>
```
my implementation in gridview code is
```
<asp:TemplateField>
<ItemStyle HorizontalAlign="Left" />
<ItemTemplate>
<asp:RadioButton ID="grdRdo" runat="server"
onclick="javascript:CheckOtherIsCheckedByGVID(this);" />
</ItemTemplate>
</asp:TemplateField>
```
Try renaming the... | [
0.018880406394600868,
-0.12433180958032608,
0.3325132131576538,
-0.452299565076828,
0.14703276753425598,
-0.19162015616893768,
0.11449434608221054,
-0.1580847054719925,
0.12297239899635315,
-0.8485972881317139,
-0.13423103094100952,
0.7161250114440918,
-0.13576996326446533,
0.1543971747159... | |
Is there any free java or android barcode (Code128 or upc) generating library for free?
Consider usage of [Zxing library](http://code.google.com/p/zxing/). it's qiet open source so you you can find algoritms for generating or reading barcodes. | [
0.4857574701309204,
0.15540650486946106,
0.0035076430067420006,
0.31884896755218506,
-0.1997276097536087,
-0.1547892540693283,
-0.26987797021865845,
0.11716052889823914,
-0.060783501714468,
-0.40454167127609253,
-0.12893997132778168,
0.23323386907577515,
-0.4589768946170807,
0.074911549687... | |
I have an application that is being deployed via a Visual Studio Setup Project, however, I had to create some custom Windows Forms to collect some specific data from the user. These forms are shown in the Install() method of the application's Installer class, right after application files have been deployed by the Setu... | [
0.7279260158538818,
0.10109478235244751,
0.7084084749221802,
-0.10811615735292435,
0.16424797475337982,
-0.12677088379859924,
0.24830520153045654,
-0.2520443797111511,
-0.08427852392196655,
-0.860510528087616,
-0.14583566784858704,
0.46743038296699524,
0.025280723348259926,
-0.163897886872... | |
bring it up, if the user even notices it.
All I had to do was pick the Setup project’s window from the list of processes and set it as the owner of the custom forms as I was displaying them. Here’s a breakdown of the steps I used:
1. Go through the list of processes named “msiexec”, and get the handle of the one displ... | [
0.5899108648300171,
-0.043392717838287354,
0.4104822874069214,
0.007420155219733715,
-0.05412014573812485,
0.02713385783135891,
-0.21583613753318787,
-0.0167249608784914,
-0.451324999332428,
-0.6914004683494568,
-0.0045807394199073315,
0.500434935092926,
-0.1582757532596588,
0.174882486462... | |
when you’re calling ShowDialog through the parameter that takes an IWin32Window; the problem is that IWin32Window doesn’t let you set the handle of the window. This is worked around by using a wrapper class which extends IWin32Window.
3. So finally, all you have to do is set the owner of the form as you’re calling Show... | [
0.4165661036968231,
-0.05161265283823013,
0.5352529883384705,
-0.19048477709293365,
-0.33824673295021057,
-0.1809445172548294,
0.08274359256029129,
-0.39320188760757446,
-0.0645301342010498,
-0.7475038766860962,
-0.01734117791056633,
0.5443244576454163,
-0.3452368676662445,
0.1793145388364... | |
I am creating.
Also, don’t change the owners of any child forms or messageboxes of your custom forms (except maybe to “this”), as they’ll be owned by the custom forms that show them; otherwise they’ll show up over the Setup project’s window but under the custom forms, not that we desired.
```
public override void... | [
0.8639919757843018,
0.01799844577908516,
0.2581021189689636,
-0.19177620112895966,
0.36693745851516724,
-0.10201650112867355,
0.44207367300987244,
-0.22641593217849731,
0.21989089250564575,
-0.8982271552085876,
-0.2064197063446045,
0.4710627496242523,
-0.32902097702026367,
0.31345772743225... | |
}
catch (Exception ex)
{
throw ex;
}
}
private void ExecuteSqlScript()
{
IntPtr hwnd = IntPtr.Zero;
WindowWrapper wrapper = null;
Process[] procs = Process.GetProcessesByName("msiexec");
if | [
-0.05119846388697624,
-0.3800407350063324,
0.21575182676315308,
-0.21494470536708832,
0.1919296830892563,
0.20150168240070343,
0.5780016779899597,
-0.2209661453962326,
-0.1995750069618225,
-0.3982721269130707,
-0.4015648365020752,
0.35426250100135803,
-0.5231993794441223,
0.303574919700622... | |
(null != procs && procs.Length > 0)
hwnd = procs[0].MainWindowHandle;
wrapper = new WindowWrapper(hwnd);
//Set the windows forms owner to setup project so it can be focused and
//set infront
frmInstance objInstance = new frmInstance();
if (null != wrapper)
... | [
0.05294788256287575,
-0.3915362060070038,
0.5912416577339172,
-0.4137435853481293,
-0.26619821786880493,
0.11988978087902069,
0.45718932151794434,
-0.2180609405040741,
-0.1807728111743927,
-0.7346290349960327,
-0.6142030954360962,
0.3846917450428009,
-0.3868602216243744,
-0.068453155457973... | |
else
objInstance.ShowDialog();
}
public class WindowWrapper : System.Windows.Forms.IWin32Window
{
public WindowWrapper(IntPtr handle)
{
_hwnd = handle;
}
public IntPtr Handle
{ | [
-0.1320507675409317,
-0.21043309569358826,
0.44741737842559814,
-0.3330763876438141,
-0.07112180441617966,
-0.018100380897521973,
0.5255898237228394,
-0.18666118383407593,
-0.03944713622331619,
-0.7365014553070068,
-0.3043476939201355,
0.5545880794525146,
-0.37730878591537476,
0.2606487572... | |
get { return _hwnd; }
}
private IntPtr _hwnd;
}
``` | [
-0.3869178295135498,
-0.017386777326464653,
0.21783898770809174,
-0.18856151401996613,
0.14828737080097198,
-0.12038181722164154,
0.3610505759716034,
-0.0012513642432168126,
0.13312716782093048,
-0.5974774360656738,
-0.5444429516792297,
0.6646323204040527,
-0.2616206407546997,
0.0563172325... | |
I would like to install my setup content only to one specific directory, so I want to have the `Next` button on directory selection page disabled, unless the user chooses the right folder to install to.
How can I disable the `Next` button on directory selection page and enable it right after user chooses a specific di... | [
0.37094372510910034,
0.08947360515594482,
0.46760618686676025,
0.06328647583723068,
0.5898396372795105,
-0.2557498812675476,
0.15359483659267426,
-0.097261443734169,
-0.10006200522184372,
-0.907810389995575,
-0.42959916591644287,
0.8881494402885437,
-0.18227076530456543,
0.2301732897758484... | |
enter whatever he (or she) wants.
```
[Setup]
AppName=My Program
AppVersion=1.5
DefaultDirName={pf}\My Program
[Code]
const
MySecretDir = 'C:\MySecretDir';
procedure OnDirEditChange(Sender: TObject);
begin
WizardForm.NextButton.Enabled := CompareText(WizardDirValue, MySecretDir) = 0;
end;
procedure CurPageChang... | [
-0.28822341561317444,
-0.17569167912006378,
0.6846548318862915,
-0.3548084497451782,
0.22590765357017517,
0.3875734508037567,
0.3559373617172241,
-0.23355242609977722,
0.04414606839418411,
-0.906085729598999,
-0.7919082045555115,
0.5478600859642029,
-0.39523065090179443,
0.1331300139427185... | |
I need to compare between `userCurrentDate` to a list of options.
The options is a table in the database that contain time attribute (definition: TIMESTAMP(6) WITH TIME ZONE. in oracle). Each option have his time zone.
The `userCurrentDate` (definition Date. in java) is a parameter that hold the user time and date w... | [
0.16104359924793243,
-0.15100394189357758,
0.36103278398513794,
0.07503800094127655,
0.34703657031059265,
0.3452047109603882,
-0.061027638614177704,
-0.07995224744081497,
-0.12850108742713928,
-0.8019050359725952,
0.1297808289527893,
0.1475745141506195,
0.08357708156108856,
0.2293946892023... | |
in the same time zone, in **SQL**?
I tried to get them in GMT, so i can get them in the same base, like this:
```
trunc(SYS_EXTRACT_UTC(o.time)) = trunc(sysdate)
```
But its not a good solution.
So, i need to get them in the same timezone. how can i get that in an SQL command (or other solution)?
The following ... | [
-0.04365045949816704,
-0.032432593405246735,
0.40491852164268494,
0.06906367093324661,
0.42438408732414246,
-0.09162037074565887,
0.11396793276071548,
0.08163081854581833,
-0.11688444763422012,
-0.8550428152084351,
-0.3227261006832123,
0.6290839314460754,
-0.10191140323877335,
0.1230262070... | |
he (or she) wants.
```
[Setup]
AppName=My Program
AppVersion=1.5
DefaultDirName={pf}\My Program
[Code]
const
MySecretDir = 'C:\MySecretDir';
procedure OnDirEditChange(Sender: TObject);
begin
WizardForm.NextButton.Enabled := CompareText(WizardDirValue, MySecretDir) = 0;
end;
procedure CurPageChanged(CurPageID: I... | [
-0.23476828634738922,
-0.17412109673023224,
0.7765422463417053,
-0.336460679769516,
0.29115188121795654,
0.442192405462265,
0.29729098081588745,
-0.37044253945350647,
-0.030159978196024895,
-0.849515974521637,
-0.7638046741485596,
0.5726762413978577,
-0.3635936975479126,
0.1703029572963714... | |
Hi I am using hadoop and HBase.When i tried to start hadoop, It started fine but when I tried to start HBase it shows exception in log files. In log file hadoop is refusing the connection on port 54310 of localhost. Logs are given below:
```
Mon Apr 9 12:28:15 PKT 2012 Starting master on hbase
ulimit -n 1024
2012-04-... | [
-0.17764851450920105,
-0.06813912093639374,
0.9644836187362671,
-0.15739759802818298,
-0.5149545669555664,
0.012776844203472137,
0.478908509016037,
-0.6864599585533142,
-0.10166458040475845,
-0.4820767641067505,
-0.11107004433870316,
0.14180788397789001,
-0.287024587392807,
0.1262779831886... | |
60000: starting
2012-04-09 12:28:18,202 INFO org.apache.hadoop.ipc.HBaseServer: IPC Server handler 2 on 60000: starting
2012-04-09 12:28:18,206 INFO org.apache.hadoop.ipc.HBaseServer: IPC Server handler 3 on 60000: starting
2012-04-09 12:28:18,210 INFO org.apache.hadoop.ipc.HBaseServer: IPC Server handler 4 on 60000: s... | [
0.07286769151687622,
0.24989235401153564,
0.5245509743690491,
0.03627927973866463,
-0.3895275890827179,
0.24931663274765015,
0.371141642332077,
-0.3244466185569763,
-0.5728816390037537,
-0.5661045908927917,
-0.24934977293014526,
-0.20644858479499817,
-0.3442028760910034,
0.1606375277042389... | |
Client environment:java.version=1.6.0_20
2012-04-09 12:28:18,370 INFO org.apache.zookeeper.ZooKeeper: Client environment:java.vendor=Sun Microsystems Inc.
2012-04-09 12:28:18,370 INFO org.apache.zookeeper.ZooKeeper: Client environment:java.home=/usr/lib/jvm/java-6-openjdk/jre
2012-04-09 12:28:18,370 INFO org.apache.zoo... | [
-0.14584428071975708,
0.3546987473964691,
0.3200153708457947,
-0.03784092143177986,
0.013778558000922203,
0.1942691206932068,
0.20368437469005585,
-0.40636146068573,
-0.39947041869163513,
-0.6224083304405212,
-0.2644767761230469,
0.4976022243499756,
-0.5645771622657776,
0.1766541302204132,... | |
localhost/127.0.0.1:2181, sessionid = 0x1369600cac10000, negotiated timeout = 180000
2012-04-09 12:28:18,740 INFO org.apache.hadoop.metrics.jvm.JvmMetrics: Initializing JVM Metrics with processName=Master, sessionId=hbase.com.com:60000
2012-04-09 12:28:18,803 INFO org.apache.hadoop.hbase.metrics: MetricsString added: r... | [
-0.051801227033138275,
-0.11479005962610245,
0.5626764297485352,
0.06117094308137894,
-0.46963006258010864,
0.19493703544139862,
0.5536265969276428,
-0.18633714318275452,
-0.04042927920818329,
-0.8418512940406799,
-0.3342210054397583,
0.43590807914733887,
0.10419624298810959,
0.23954859375... | |
to server: hbase/192.168.15.20:54310. Already tried 0 time(s).
2012-04-09 12:28:22,343 INFO org.apache.hadoop.ipc.Client: Retrying connect to server: hbase/192.168.15.20:54310. Already tried 1 time(s).
2012-04-09 12:28:23,344 INFO org.apache.hadoop.ipc.Client: Retrying connect to server: hbase/192.168.15.20:54310. Alre... | [
-0.04516201466321945,
0.10081690549850464,
0.5315229892730713,
-0.09026724100112915,
-0.23834490776062012,
0.23137423396110535,
0.7284794449806213,
-0.4864087402820587,
-0.44387996196746826,
-0.7437899708747864,
-0.03659799322485924,
0.22198791801929474,
-0.018565509468317032,
0.2870076000... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.