Posts

C# transparent canvas over OpenGL -

i have following layout in c# windowsformhost host opengl window. add transparent canvas on draw 2d stuff. code doesn't work. please help. mc:ignorable="d"> <grid> <dockpanel> <windowsformshost grid.column="0" x:name="scannerviewpanel"/> <canvas background="transparent"/> edit: after add canvas, opengl content not shown, opaque canvas. tried make canvas transparent, set opacity 0, it's still opaque. from msdn : in wpf user interface, can change z-order of elements control overlapping behavior. hosted windows forms control drawn in separate hwnd, drawn on top of wpf elements. you can't that.

problems with errors on SQL SERVER -

i have issue query in sql server, have wrote dynamic query: declare @cont int declare @sqlquery varchar(1000) declare @sqlquery2 varchar(500) declare @sqlquery3 varchar(2000) declare @anho varchar(4) set nocount on drop table ti set @anho = (select year(getdate())) set @cont = 1 set @sqlquery = '' while @cont <= 12 begin set @sqlquery2 = '(a.['+@anho + right('00'+cast(@cont varchar),2)+']+b.['+@anho + right('00'+cast(@cont varchar),2)+']+c.['+@anho + right('00'+cast(@cont varchar),2)+']+d.['+@anho + right('00'+cast(@cont varchar),2)+']) ['+@anho + right('00'+cast(@cont varchar),2)+'],' exec (@sqlquery2) set @sqlquery = @sqlquery + @sqlquery2 exec (@sqlquery) set @cont = @cont + 1 end exec(@sqlquery) set @sqlquery3 = 'select a.gestion,'+@sqlquery+' '+quotename('ges08','''')+' cod_ges ti llamadas_mensual_oro_final inner join llamada...

c# - Store data in LINQ to two tables; Join LINQ -

i using simplemembership mvc4 work great, required add addition user details first , last name, email, country constraints each user can have multiple profiles add id {fk} users table in userprofile table. have seprate form when user register, system call form asking addition details. using code first existing database approach i missing puzzle of how store additional information along saying hock user profile using linq. many in advance .. database: create table [dbo].[userprofile] ( [userid] int identity (1, 1) not null, [username] nvarchar (150) not null, [id] int not null, primary key clustered ([userid] asc), foreign key ([id]) references [dbo].[users] ([id]) ); create table [dbo].[users] ( [id] int identity (1, 1) not null, [email] nvarchar (150) not null, [first_name] nvarchar (150) not null, [last_name] nvarchar (150) not null, [country] nvarchar (150) not null, primary key clustered ([id] asc) ); control...

php - SimpleXMLElement' is not allowed in session_write_close() -

im not sure do. im trying make session string inside of function , parse session outside of , if makes sense.... im getting error "simplexmlelement' not allowed in session_write_close()" suggestions on can solve it? function api_info($form, &$form_state){ $server_url = 'website api url' curl_setopt($ch, curlopt_url, $server_url ); curl_setopt($ch, curlopt_post, 0 ); curl_setopt($ch, curlopt_postfields, ); curl_setopt($ch, curlopt_httpheader, array("expect:") ); curl_setopt($ch, curlopt_failonerror, 1 ); curl_setopt($ch, curlopt_followlocation, ); curl_setopt($ch, curlopt_header, false ); curl_setopt($ch, curlopt_returntransfer, 1 ...

css - are AsciiEffect.js && CSS3DRenderer.js compatible? three.js / WebGL -

i'm trying use asciieffect.js && css3drenderer.js in combination, don't know if that's possible without finagling... here's idea var w = window.innerwidth, h = window.innerheight; renderer = new three.css3drenderer(); effect = new three.asciieffect( renderer ); effect.setsize( w, h ); document.body.appendchild( effect.domelement ); but doesn't work... here's problem, it's understanding asciieffect script uses canvas renderer... i'm not entirely sure how css3drenderer works (beyond skill set)... in theory seems should possible... no? assume involves making changes either or... no, they're not. asciieffect works canvas -based renderers: canvasrenderer , softwarerenderer , webglrenderer .

node.js - How to use partials in Express.js layout? -

i have layout.ejs file contains site's basic boilerplate html markup: doctype declaration, head, body, footer, basics... how go placing navigation in separate partial file , including layout? there particular require() or include() function doing this? i using ejs view engine. yes. <% include path/to/template %> documentation here. https://github.com/visionmedia/ejs#includes

javascript - How do I get compass heading from DeviceOrientation in the Google Glass Browser? -

the web browser built google glass of firmware version xe7 provides deviceoreientation events , values don't seem come expected frame of reference. how can 1 proper compass headings out of this? glass positioned on head: deviceorientationevent beta 90 upright , level -90 inverted , level 0 looking straight or down gamma 90 right ear towards floor 180 looking straight 270/-90 left ear down 0 looking straight down alpha this property not stable when glass horizontal (what should useful orientation using compass direction, determine wearer looking). gives stable readings when glass tilted above or below horizon. above horizontal 90 north 0 east 180 west 270 south below horizontal 270 north 180 east 0 west 90 south may can idea on how control compass newly launched sample