Click here to Skip to main content
15,390,695 members

Comments by pkfox (Top 165 by date)

pkfox 3-Jan-22 3:54am View
   
Hi Bill, thanks for replying - there is no reference to it in the .csproj file, but it is shown under Dependencies\Microsoft.NETCore.App which points to a physical file in C:\Program Files\dotnet\packs\Microsoft.NETCore.App.Ref\6.0.1\ref\net6.0\System.Runtime.dll - but that file is dated 23/11/2021
pkfox 15-Nov-21 4:24am View
   
That did it thanks Richard
pkfox 15-Nov-21 4:01am View
   
Thanks for all your help Peter I do appreciate it, I don't have any custom CSS in the mix just the usual bootstrap.css. It's definitely fixed-top that stretches the navbar though.
pkfox 14-Nov-21 8:17am View
   
Hi Peter, same result the navbar goes the full screen width and the content is centred.
pkfox 12-Nov-21 4:50am View
   
Hi Richard I had to add this to the csproj file - all is good now

<PropertyGroup>    <PreserveCompilationContext>true</PreserveCompilationContext>    <MvcRazorCompileOnPublish>false</MvcRazorCompileOnPublish>    <CopyRazorGenerateFilesToPublishDirectory>true</CopyRazorGenerateFilesToPublishDirectory>  </PropertyGroup>
pkfox 11-Nov-21 12:41pm View
   
Thanks Richard I'll check - the site is published by a Jenkins pipeline script which uses the dotnet publish command, I'll see if there's a flag to set this
pkfox 11-Nov-21 11:07am View
   
I notice you are 5 points ahead of OG for the last 24hrs
pkfox 10-Sep-21 3:48am View
   
HI Richard, I tried the type=date and it does pop up a date picker but type=time only gives me two input areas no pop up picker - is this expected ?
pkfox 9-Sep-21 13:59pm View
   
Ok thanks Richard I'm only using this in a personal project - I'm sure you realise I'm not a Web dev :-)
pkfox 9-Sep-21 10:45am View
   
I have it working now Richard - there were some vars declared in the top of the script which conflicted with mine - slaps forehead - thanks for all your help - learnt a few things today - need beer.
pkfox 9-Sep-21 10:32am View
   
No fun in that Richard :-)
pkfox 9-Sep-21 10:32am View
   
What are the double minuses for ?
pkfox 9-Sep-21 9:51am View
   
As the div contains a local image Richard I don't think I can use JSFiddle
pkfox 9-Sep-21 9:43am View
   
It's not bad on my box - this works
$('#hour')[0].style[prop] = 'rotate(' + hourAngle + 'deg)';

This dosen't
var hour = document.getElementById('hour');
hour.style[prop] = 'rotate(' + hourAngle + 'deg)';
pkfox 9-Sep-21 9:18am View
   
The div has an image as shown
<div id="hour"><img src="~/paulrhayes.com-experiments-master/clock/images/hourHand.png" /></div>
pkfox 9-Sep-21 9:11am View
   
How do I do that Richard ?
pkfox 9-Sep-21 9:08am View
   
Deleted
How do I do that Richard ?
pkfox 8-Sep-21 12:46pm View
   
Thanks Richard
pkfox 27-Jan-21 5:17am View
   
I don't know what it is I'm doing wrong Richard - there seems to be some confusion between commenting and solutions - hopefully this is a comment and therefore allowed
pkfox 9-Sep-20 13:53pm View
   
Thanks Patrice
pkfox 9-Sep-20 13:52pm View
   
I've got that Paul thanks
pkfox 9-Sep-20 5:55am View
   
Thanks Richard that does the trick
pkfox 24-May-20 10:37am View
   
Hi Pete, just a heads up - on your recommendation I installed BaGet on a Linux box and it works beautifully , it was the last part of the jigsaw to my automating my deployment process - one thing I had to do to get it building with Jenkins was to create a nuget.config file and add the url of the BaGet server and I was away. Thanks very much for your advice.
pkfox 22-May-20 7:27am View
   
Deleted
Have you got a link Pete ?
pkfox 21-May-20 17:28pm View
   
Hi Pete have you setup a nuget repository on Linux ?
pkfox 19-May-20 12:01pm View
   
Success !!! albeit in a not pretty fashion - I created a new Jenkins pipeline item which pulls the two repos in ( you can't do what you sugested into the same folder as it gets overwritten by the second ) then build the common repo first followed by the second ( here comes the orrible bit ) the caveat is I had to put
/home/pjk/Jenkins/Linux-ARM64/Common/Common.dll

in the Consumer.csproj file in github as a ItemGroup Reference - I perform a dotnet build in the script which outputs Common.dll to this folder - it's a start though - thoughts ?
pkfox 19-May-20 11:53am View
   
That's food for thought Pete thanks - I've used Jenkins to build and publish nuget packages before ( that was on Windows though ) my current need is net core on Linux ARM64
pkfox 19-May-20 8:12am View
   
Hi Sander,I'm such a fool ( replying to myself ) what you suggest is roughly what I had in mind. In my current state I'm just trying to get a successful build with two projects let's call them EntityConsumer and Entities, if I read you correctly you are saying build Entities and then trigger a build of EntityConsumer which has a dependency on Entities ? ( what could possibly go wrong :-) ? ) I'll give it a go - thanks very much for your help and patience
pkfox 19-May-20 5:08am View
   
Hi Bill, thanks for the compliment - most of the jenkins link I've found are IRC rooms - not keen on them
pkfox 18-May-20 17:16pm View
   
How could I do that Sander ?
pkfox 7-Feb-18 17:19pm View
   
Thanks Jochen I'll give it a try
pkfox 17-Jan-18 17:14pm View
   
I know I know :-)
pkfox 17-Jan-18 9:26am View
   
Thanks Jochen
pkfox 17-Jan-18 9:26am View
   
Thanks Paul, the whole program will be rewritten very soon ( it was written in 2001 ) in C# , the change I've got to make is a path to the output file so should be ok , I agree ( goto ) I've never used a goto in my life
pkfox 29-Dec-17 6:52am View
   
Have a look at DllImport
pkfox 17-Oct-17 10:40am View
   
Your code please :-)
pkfox 7-Oct-17 6:34am View
   
I've got LinqPad which is great but I need to understand Linq better - I'm currently watching a series of tutorials on Youtube which is helping but it's not up to your level - where did you learn Linq ? or is it a case of RTFM :-)
pkfox 30-Sep-17 9:38am View
   
I did amend my comment Richard it's exactly what I wanted, where did you learn all this Linq stuff ? it's brilliant
pkfox 30-Sep-17 6:02am View
   
Edit
Sorry Richard it does produce the sums - thank you very much for your help


Hi Richard, thanks for you time - this produced the L values but not the sum of them , what I'm trying to achieve is

H,1000,28-09-2017,2,80
L,30,Pete
L,50,Pete
H,200,29-09-2017,3,135
L,35,Pete
L,45,Pete
L,55,Pete
pkfox 29-Sep-17 12:21pm View
   
The values in the L lines 30,35 etc...
pkfox 29-Sep-17 1:03am View
   
Hi Richard this works a treat - how can I add the sum of the L lines ?
pkfox 28-Sep-17 14:29pm View
   
Thanks Richard I'll give that a shot
pkfox 22-Jun-17 5:28am View
   
Hi Rick enabling show all characters with both of the files loaded showed me the header record on my file was somehow padded to the width of the rest of the file, the header on the old file is simply MYCOMPANYNAME20170622 but on mine it was written as "MYCOMPANYNAME20170622 128 spaces go here" thanks for your help
pkfox 21-Jun-17 13:40pm View
   
Ok I'll give it a go thanks
pkfox 21-Jun-17 13:22pm View
   
Good thought i'll give it a go
pkfox 30-Apr-17 9:20am View
   
this is what I ended up with based on your suggestion

Create FUNCTION [dbo].[GetDescription](@Period int)
RETURNS varchar(16)
AS
BEGIN
DECLARE @RetVal varchar(110);

DECLARE @tempTable table (period int identity(0,1),period_descr varchar(16))
insert into @tempTable
select u.period
from Descriptions s

unpivot
(
period for Descrip in (period_descr_0,period_descr_1,period_descr_2,
period_descr_3,period_descr_4,period_descr_5,
period_descr_6,period_descr_7,period_descr_8,
period_descr_9,period_descr_10,period_descr_11,
period_descr_12)
) u;

SELECT @RetVal = period_descr from @tempTable WHERE period = @period
return @RetVal
END

Thanks very much for your help I hadn't even heard of unpivot ! very useful information, as a side note you can't use #temp temp tables in a function
pkfox 28-Apr-17 12:44pm View
   
Hi I tried your code and receive this error

(13 row(s) affected)
Msg 245, Level 16, State 1, Line 17
Conversion failed when converting the varchar value 'Description 0' to data type int.

IF OBJECT_ID('tempdb..#temp') IS NOT NULL
DROP TABLE #temp

select u.Descrip, u.period
INTO #temp
from Descriptions
unpivot
(
period for Descrip in (period_descr_0,period_descr_1,period_descr_2,
period_descr_3,period_descr_4,period_descr_5,
period_descr_6,period_descr_7,period_descr_8,
period_descr_9,period_descr_10,period_descr_11,period_descr_12)
) u;

declare @period int = 1
declare @RetVal varchar(16)
SELECT @RetVal = Descrip from #temp WHERE period = @period
select ISNULL(@RetVal, 'Out of range')

pkfox 27-Apr-17 1:47am View
   
OK thanks for clarifying
pkfox 26-Apr-17 12:01pm View
   
Where do you declare #temp ? also the table doesn't have a period column only period_desc_0 ... etc
pkfox 26-Apr-17 9:48am View
   
Unfortunately I can't change the schema but thanks for your answer
pkfox 26-Apr-17 9:46am View
   
Hi Peter unfortunately you can't use sp_executesql in a function - thanks for your answer
pkfox 25-Oct-16 5:16am View
   
Apologies to everyone the client I'm currently contracting for has just told me he set all of the records to 31-12-4000 ( it's and end date for a loan ) so that explains it - apols once more
pkfox 25-Oct-16 4:51am View
   
Yes it's date and using default Oracle driver to connect it with CR, see my amended question
pkfox 14-Oct-16 4:59am View
   
Sorry for my tardiness - I'm viewing the inserted data in Oracle SQL Developer
pkfox 8-Oct-16 3:47am View
   
That's similar to what I've done now and it seems to be OK , why are you doing the -5 part though ?
pkfox 7-Oct-16 12:07pm View
   
This needs to be done in a SQL Server stored procedure
pkfox 7-Oct-16 12:05pm View
   
Sorry I should have been clearer, this needs to be done in a SQL Server stored procedure
pkfox 15-Sep-16 5:49am View
   
What do you mean by it doesn't work ?
pkfox 11-Sep-16 8:51am View
   
Yes I knew that Richard it was the ## I didn't know :-) thanks
pkfox 11-Sep-16 8:16am View
   
Thanks Griff - nice example
pkfox 29-Aug-16 9:54am View
   
Hi there and thanks but that doesn't really help me
pkfox 20-Jul-16 8:45am View
   
Hi Jochen, cpprest has this little gem in basic_types.h

#ifdef _UTF16_STRINGS
typedef std::wstring string_t;
#else
typedef std::string string_t;
#endif
which is what you suggested.
I changed all my wstring to string_t and all is fine - thanks for your time
pkfox 20-Jul-16 7:18am View
   
Really ( You will always run into problems when using std:wstring with Linux ) ? the cpprestsdk team boast of cross platform support - I like to develop using VS on Windows and then copy the code to Linux - I suppose I'll just have to default to using std::string which is not a big deal - thanks for your help.
pkfox 5-Jul-16 16:56pm View
   
How do you get tags to show in the message ?
pkfox 5-Jul-16 5:50am View
   
Ok cheers for that
pkfox 5-Jul-16 5:40am View
   
Wouldn't that only catch the closing tag ?
pkfox 11-Jun-16 7:27am View
   
All the *.???x files are zip files
pkfox 1-Jun-16 9:18am View
   
Sorry for not being clear enough by Web report server I mean, the web interface ( which I can't connect to either ) it errors with the same message about insufficient permissions
pkfox 1-Jun-16 8:44am View
   
The web report server or SQL Report Server ?
pkfox 1-Jun-16 8:07am View
   
Hi Ryan, I know you can't see my machine but what I don't understand is *where* do I set permissions ? is it folder security, SQL Server, Report Database ? that's what's doing my head in, You ask Did you log onto the server and run it from the server ? what server the web server or SSMS ? sorry to keep asking but it's very confusing. I had this setup on Win 7 without much trouble but I'm on Win 10 now :-(
pkfox 1-Jun-16 4:44am View
   
I've enabled the checkbox for My Reports folder but don't know how to set permissions to "fix the security" I feel I'm getting nearer though thanks
pkfox 31-May-16 16:03pm View
   
Thanks,I understand the first part of Properties enable My Reports folder , but when you say "fix the security" I glaze over, how do I fix security ?, my user name is pjk so in SSMS where do I start to "fix security" ? Thanks again
pkfox 31-May-16 14:28pm View
   
Ok, I'm in Ssms what exactly do i need to do ?
pkfox 31-May-16 12:54pm View
   
Hi and thanks - how do i turn on My Reports ?
pkfox 30-May-16 7:19am View
   
Just to update - if I run report builder as administrator I can connect to the report server and run the report without issue - but I notice if I browse to the report server using Firefox and try to create a shared data source I get the same error about permissions for pjk
pkfox 30-May-16 1:11am View
   
Hi and thanks for your reply, if it was SQL server permissions problem why does the report run OK when I'm not connected to the report server ?
pkfox 25-May-16 10:08am View
   
Making progress this is the query ( I've substituted the Calendar table with one called Months which has 12 records )

SELECT sq.Owner_Id, sq.MonthNumber, SUM(sf.o_sum_financed) As SumFinanced
FROM (
SELECT ov.Owner_Id, mth.MonthNumber,ov.Opp_Id
FROM Months mth
cross join Opp_View ov
where year(ov.close_date) = 2016
) AS sq LEFT OUTER JOIN O_Sum_Financed sf ON sq.Opp_Id = sf.Client_Id
GROUP BY sq.Owner_Id, sq.MonthNumber
ORDER BY sq.Owner_Id, sq.MonthNumber

and the output is


Owner_Id MonthNumber SumFinanced
BCARR 1 505311.35
BCARR 2 505311.35
BCARR 3 505311.35
BCARR 4 505311.35
BCARR 5 505311.35
BCARR 6 505311.35
BCARR 7 505311.35
BCARR 8 505311.35
BCARR 9 505311.35
BCARR 10 505311.35
BCARR 11 505311.35
BCARR 12 505311.35

where 505311.35.is the total for the year for BCARR - HTH
pkfox 25-May-16 9:44am View
   
This the output for REP1 there is a pattern in the summed column which might help you see the problem

Owner_Id MonthNumber SumFinanced
REP1 1 15664651.85
REP1 2 14654029.15
REP1 3 15664651.85
REP1 4 15159340.5
REP1 5 15664651.85
REP1 6 15159340.5
REP1 7 15664651.85
REP1 8 15664651.85
REP1 9 15159340.5
REP1 10 15664651.85
REP1 11 15159340.5
REP1 12 15664651.85
pkfox 25-May-16 9:22am View
   
This returns the correct amount of rows but still incorrect summed amounts ( I removed the group clause on the inner query )

SELECT sq.Owner_Id, sq.MonthNumber, SUM(sf.o_sum_financed) As SumFinanced
FROM (
SELECT ov.Owner_Id,MONTH(DateIndex) as MonthNumber,ov.Opp_Id
FROM CalendarTable ct
cross join Opp_View ov
where year(ct.dateindex) = 2016
) AS sq LEFT OUTER JOIN O_Sum_Financed sf ON sq.Opp_Id = sf.Client_Id
GROUP BY sq.Owner_Id, sq.MonthNumber
ORDER BY sq.Owner_Id, sq.MonthNumber
pkfox 25-May-16 9:07am View
   
Thanks for your time but I'm still getting the error

This is what I have

SELECT sq.Owner_Id, sq.MonthNumber, SUM(sf.o_sum_financed) As SumFinanced
FROM (
SELECT ov.Owner_Id,MONTH(DateIndex) as MonthNumber,ov.Opp_Id
FROM CalendarTable ct
cross join Opp_View ov
where year(ct.dateindex) = 2016
GROUP BY ov.Owner_Id,MONTH(DateIndex)
) AS sq LEFT OUTER JOIN O_Sum_Financed sf ON sq.Opp_Id = sf.Client_Id
GROUP BY sq.Owner_Id, sq.MonthNumber
ORDER BY sq.Owner_Id, sq.MonthNumber
pkfox 25-May-16 8:55am View
   
This is what I have and still getting syntax error

SELECT sq.*, SUM(sf.o_sum_financed) As SumFinanced
FROM (
SELECT ov.Owner_Id,MONTH(DateIndex) as MonthNumber,ov.Opp_Id
FROM CalendarTable ct
cross join Opp_View ov
where year(ct.dateindex) = 2016
GROUP BY ov.Owner_Id,MONTH(DateIndex)
) AS sq LEFT OUTER JOIN O_Sum_Financed sf ON sq.Opp_Id = sf.Client_Id
GROUP BY sq.Owner_Id, sq.MonthNumber
ORDER BY sq.Owner_Id, sq.MonthNumber

Error is: Column 'Opp_View.Opp_Id' is invalid in the select list because it is not contained in either an aggregate function or the GROUP BY clause.

but I need opp_id for the join
pkfox 25-May-16 8:47am View
   
Where do I put the group by ?
pkfox 25-May-16 8:23am View
   
I'm probably misunderstanding what you mean I tried this and get syntax errors

SELECT sq.*, SUM(sf.o_sum_financed) As SumFinanced,count(opp_id) as DealCount
FROM (SELECT ov.Owner_Id,MONTH(DateIndex) as MonthNumber,ov.Opp_Id
FROM CalendarTable ct
cross join Opp_View ov
where year(ct.dateindex) = 2016
GROUP BY ov.Owner_Id,MONTH(DateIndex)
) AS sq
LEFT OUTER JOIN O_Sum_Financed sf ON sq.opp_Id = sf.Client_Id

pkfox 11-May-16 4:50am View
   
I've discovered rapidjson has a HasMember method which I think will do the trick thanks
pkfox 5-May-16 7:49am View
   
Hi Dave, just to update you - the problem was twofold, the first was I didn't have dotnet 4.5 framework installed which is a must for Powershell 4 and the second was a copy paste problem ( I've had this before copying code from the web ) I discovered if I typed and executed the code line by line in the bottom pane of the ps editor it worked , so I then simply typed the whole thing into a script and Bingo - I'm now obsessed with Powershell - thank you for pointing me in the right direction.
pkfox 4-May-16 11:52am View
   
I was thinking that thanks
pkfox 4-May-16 10:48am View
   
PS C:\Users\pjk> $PSVersionTable.PSVersion

Major Minor Build Revision
----- ----- ----- --------
4 0 -1 -1
pkfox 4-May-16 10:20am View
   
Hi Dave, I updated to version 4 and still the same error :-(
pkfox 4-May-16 10:09am View
   
Ok thanks I'll try updating it
pkfox 29-Apr-16 1:15am View
   
Hi there please see my answer to the other chap. Thanks for your time.
pkfox 29-Apr-16 1:14am View
   
Although this is a Sql server database it's a Maximiser CRM database and i think the extra baggage of Maximiser is the culprit. Tnaks for your time.
pkfox 27-Apr-16 2:46am View
   
Hi there I realise there is a limit but no way is this database 15 gig there must be a very large log file that I don't need
pkfox 26-Apr-16 8:35am View
   
Worked with that link Griff thanks
pkfox 26-Apr-16 3:58am View
   
I'm on machine where I'm contracting but it is on SP1
pkfox 26-Apr-16 3:30am View
   
I'm on Win 7 and just installed it as I have all other versions in the past - I'll have another go
pkfox 26-Apr-16 3:29am View
   
Deleted
Griff you've submitted a solution so I can't reply - I'm on Win 7 and just installed it as I have all other versions in the past - I'll have another go
pkfox 31-Mar-16 13:51pm View
   
Thanks for your time but I'm sure this can be achieved using sockets I've managed to send UDP broadcast messages to the Lan to discover the listening servers using raw sockets so I feel it must be doable having the returned info ( port number, IP address etc...) to send a Post and get the response
pkfox 31-Mar-16 2:07am View
   
Hi there looked promising but it's a commercial product which I don't want
pkfox 30-Mar-16 12:01pm View
   
That's a java example for Android - that's why I said in my original post I want a C/C++ solution - I've done lots of googling and seen all these libraries and they are no good to me - thanks anyway
pkfox 30-Mar-16 11:06am View
   
The question is will it compile under my Android C++ compiler ? , I was thinking maybe it's possible using sockets - thanks for your help
pkfox 27-Mar-16 8:05am View
   
Thanks very much - I now have two ways of doing it ( I'm sure there are more )
pkfox 27-Mar-16 8:03am View
   
Thanks very much I always forget you can point the output to another object
pkfox 25-Mar-16 7:27am View
   
Nice one Bill thank you
pkfox 25-Mar-16 7:26am View
   
Thanks very much
pkfox 25-Mar-16 7:25am View
   
I see you fixed the ToLower - thanks that'll do :-)
pkfox 20-Mar-16 4:12am View
   
Oh ok sorry, by code I mean using Crystal Report code this is not a Visual Studio project just a stand alone report
pkfox 19-Mar-16 7:03am View
   
I stated in my post that I KNOW how to do it the way that article does it what I'm asking is how to do it in code
pkfox 14-Mar-16 8:14am View
   
Apologies Dave this is what worked from one of those links

this.client.Credentials = new NetworkCredential("myusername", "myunencryptedpassword"); // where client is WebClient
I was trying it with the encrypted password before - works a treat
pkfox 14-Mar-16 6:19am View
   
I tried those examples Dave and I still get a 401 not authorized error which is not surprising I suppose as the password stored in the .htpasswd file is encrypted - I used this site to generate it
http://www.htaccesstools.com/htpasswd-generator/

and it looks like this
pjk:$apr1$JhJmwyV4$cgtib4PXD9NxL0iGQeg2f1
pkfox 14-Mar-16 4:26am View
   
Thanks Dave
pkfox 1-Mar-16 11:52am View
   
Thats what I've done now Ryan - bit misleading in VS though
pkfox 1-Mar-16 4:31am View
   
Oh ok I'll have to look into the security side - thanks
pkfox 1-Mar-16 4:29am View
   
I haven't tried anything yet as I've only been asked if it's possible - I'm new at Web deployment so don't know what is doable - so you are saying I could create a new virtual directory and put any new stuff in there ? so if my domain was pete.com my sandbox uri would be ( if I created a virtual directory called sandbox ) pete.com/sandbox ?
pkfox 24-Feb-16 12:29pm View
   
Ok Richard thanks - I'm thinking of doing it through a WCF service now
pkfox 24-Feb-16 11:17am View
   
Bits ?
pkfox 24-Feb-16 9:27am View
   
Ok thanks that's beyond me at the moment as I've never done any Web stuff
pkfox 24-Feb-16 9:00am View
   
I see it now Richard as I said to the others I misunderstood what UploadFile() does - thanks
pkfox 24-Feb-16 8:58am View
   
Ok thanks I misunderstood what UploadFile() does - I though it physically copied a file but it just POSTS it
pkfox 24-Feb-16 8:54am View
   
Ah ! that would explain it thanks ( I've not done much Web stuff ) so what would be the way to upload a file ? ( there is no ftp server on the box )
pkfox 24-Feb-16 8:32am View
   
Thanks I'll give it a go
pkfox 24-Feb-16 8:30am View
   
As I've said there is no error
pkfox 24-Feb-16 8:29am View
   
new Uri(new Uri(@"http://10.10.1.11/Downloads/Data/"), UploadFname) don't know what you mean by that ? , you have two uri's in there

Edit - oh I see it creates a new URi - I've tried it though ( and got rid of the class complication ) and still no joy - and still no errors
pkfox 24-Feb-16 7:43am View
   
As I said Richard there are no errors the file just doesn't arrive on the server
pkfox 24-Feb-16 7:23am View
   
The question and what have you tried :-)
pkfox 17-Feb-16 6:30am View
   
Eh ? has development stopped ?
pkfox 17-Feb-16 3:33am View
   
Doesn't compile - I'm not using MFC here this is pure C++ - the following code did the trick

json::value jsonValue2 = jsonValue.at(U("result"));
pkfox 11-Feb-16 8:21am View
   
Isn't Casablanca Microsoft ? I need a bare bones C++ example just to get me started I haven't done much web stuff so I want to know the nuts and bolts of how to talk to a server - thanks
pkfox 3-Feb-16 9:40am View
   
Ok thanks
pkfox 3-Feb-16 2:41am View
   
How do you get the angle brackets to show correctly in your message ?
pkfox 2-Feb-16 5:08am View
   
Hi Sascha your solution works except for ( as you mentioned ) when there are more than one with the same maximum Weighting, if I remove the SingleOrDefault() I get an error stating that more than one element has been returned and a problem converting IEnumerable of ints to int, I then replaced SingleOrDefault() with FirstOrDefault() and all is well - so thanks very much
pkfox 2-Feb-16 3:03am View
   
Both solutions are good Richard but until I understand Linq better I would use the first
pkfox 2-Feb-16 3:01am View
   
Looks good Sascha
pkfox 1-Feb-16 14:42pm View
   
Hi Sascha I'm using a tablet to post this and don't see an option to comment on a solution
pkfox 1-Feb-16 13:55pm View
   
Hi Sascha thanks for that but I need a where clause on BandingEnd as in the real application there would be multiple bands e.g 1000-2000,3000-4000 etc... But I think I can figure it out from your example. Thanks again
pkfox 29-Jan-16 10:48am View
   
Hi Albert what should I use instead of sizeof ?
pkfox 29-Jan-16 10:45am View
   
Why is Wi-Fi not a LAN ? you tell my why it isn't and I'll tell why it is
pkfox 28-Jan-16 18:59pm View
   
Hi there , I'm not going to change it I was just being curious - thanks for your time
pkfox 28-Jan-16 18:57pm View
   
Didn't realise I'd given you a five ;-) I'm new to this game - thanks a lot
pkfox 28-Jan-16 8:38am View
   
Ok thanks - I just thought there might be a collection such as c# List to store the return value in.
pkfox 28-Jan-16 8:36am View
   
Poor man needs help :-)
pkfox 21-Jan-16 12:18pm View
   
I know where it is Griff it's the first call to listener.Receive which is where the grunt work of finding the ip address of a server is done
pkfox 21-Jan-16 12:12pm View
   
Hi Dave, the strange thing is I have very similar code written in Java which runs on my tablet and the response is almost immediate - I'm beginning to suspect my laptops wi-fi card
pkfox 19-Jan-16 4:32am View
   
With a slight modification OG's solution worked I changed

byte[] request = Encoding.UTF8.GetBytes("eIPAD\0NAME\0JSON\0");
to

byte[] request = Encoding.ASCII.GetBytes("eIPAD\0NAME\0JSON\0");


and it worked ( i.e. I received the expected data )
pkfox 18-Jan-16 12:57pm View
   
Hi Sergey that's what I've tried and I'm not getting the expected result
pkfox 16-Jan-16 6:28am View
   
Success !!! - the colours were set to black on black ( don't know how that happened ) thanks very much
pkfox 16-Jan-16 6:22am View
   
The cursor moves if I type but nothing is displayed
pkfox 16-Jan-16 6:18am View
   
What do you mean nonsense ? It doesn't work - I use cmd.exe for lots of reasons
pkfox 16-Jan-16 6:17am View
   
cmd.exe is there - don't know how to check if it's corrupt
pkfox 16-Jan-16 6:16am View
   
Nothing works
pkfox 24-Dec-15 12:35pm View
   
Do you mean Aide ?
pkfox 24-Dec-15 8:19am View
   
Hi there, no it has a static IP address and as I say it runs perfectly as a java module in Android Studio - the problem stems from the RuntimeDegate accessing a null string which must be non null in Android Studio but null on Android tablet
pkfox 12-Dec-15 7:17am View
   
Oh ok - too greedy I think
pkfox 5-Dec-15 7:12am View
   
Hi Bill, I have things working using Matts solution of removing artists that don't have a corresponding album which is not ideal but it does work
pkfox 5-Dec-15 3:42am View
   
Hi Bill I've read that article and it's very good in fact I use some of his methods to talk to the music server. The structure of the classes is very basic unfortunately I can't paste them here because of the formatting but I'll do my best to explain, the Artist class has a ArtistID member as a primary key, the Album also has ArtistID and AlbumID as the primary key, the Tracks class has AlbumID and TrackID as the primary key. Thanks for your interest.
pkfox 4-Dec-15 8:31am View
   
Sorry Bill I should be clearer - yes I get one list of each
pkfox 4-Dec-15 4:41am View
   
Hi Bill, I get a list of albums, tracks and artists - they are part of Logitech Media Server ( used to be Squeezecenter )
pkfox 4-Dec-15 3:18am View
   
Food for thought thanks Bill - you mentioned you could send me something - please do.
pkfox 4-Dec-15 3:12am View
   
I will give that a go Matt thanks
pkfox 3-Dec-15 14:29pm View
   
I know what your saying Bill but the data is coming from a source that is not under my control, it's a music database and an artist can exist if they contribute to an album but are not necessarily the *album artist* so an entry is made as a *contributor* but not a corresponding album
pkfox 3-Dec-15 13:08pm View
   
I agree totally but the data is coming from a web server as JSon and I have to map it to these existing classes - I hate web work 😑
pkfox 3-Dec-15 13:06pm View
   
Thanks Matt that's what I'll do until I can talk to the original dev
pkfox 3-Dec-15 12:40pm View
   
Hi OG unfortunately it's not my design but thanks anyway
pkfox 2-Jan-15 2:15am View
   
Hi and thanks, what do I put in the second select ?
pkfox 2-Jan-15 2:05am View
   
Very useful link thank you
pkfox 17-Dec-13 3:53am View
   
Haven't got a solution Dave but if you head over to linuxformat.com someone will help ( sorry couldn't get the link to work ) is that better ?