Jump to content


  • Content Count

  • Joined

  • Last visited

Community Reputation

1 Neutral

About madsovenielsen

  • Rank
  • Birthday 05/15/1987

Previous Fields

  • Languages
    XHTML, CSS, JavaScript, XML, ASP, PHP,

Contact Methods

  • Website URL
  • ICQ

Profile Information

  • Location
  1. HelloI know this is a total newb question, but i have the following SQL: SELECT FagNavn, adgangskrav, Ugedag, holdId, fagKode, CONVERT(CHAR(10), StartDato, 105) AS startDate, CONVERT(CHAR(10), slutDato, 105) AS endDate, afdeling, link, navn, deltagerBetaling, bt, niveau, Case When Ugedag = 'Mandag' Then frakl + ' - ' + tilkl Else '' End AS startSlutMandag, Case When Ugedag = 'Tirsdag' Thenfrakl + ' - ' + tilkl Else '' End AS startSlutTirsdag, Case When Ugedag = 'Onsdag' Thenfrakl + ' - ' + tilkl Else '' End AS startSlutOnsdag, Case When Ugedag = 'Torsdag' Then frakl + ' - ' + tilkl Else '' En
  2. Hello I need to delete array items and compact the array (multidimentional). I have not been able to find any "build in" function for this in VBScript. I would like to be able to "delete" array items and compact the remaining items so there is no gaps. Array example: Dim example(4,20) example(0,0) = "54HG12-KLD"example(1,0) = "Thingamabob"example(2,0) = "Good for long hikes."example(3,0) = "599" example(0,1) = "54HG12-GHJ"example(1,1) = "Thingamabob"example(2,1) = "Good for short hikes."example(3,1) = "499"... Does anyone have a function er code snippet, or maybe some good advice on writing
  3. Hello Imports System.Web.Script.SerializationImports System.Data.SqlClientPublic Class jsonTest Dim objSQLConnection As SqlConnection Dim objSQLCommand As SqlCommand Dim objSQLDataReader As SqlDataReader Dim objJSONStringBuilder As StringBuilder Public Function returnJson() As String Dim col1 As New ArrayList Dim col2 As New ArrayList objJSONStringBuilder = New StringBuilder() Dim connString As String = System.Configuration.ConfigurationManager.ConnectionStrings("VUCConnectionString").ConnectionString objSQLConnection = New SqlConnection(System.Configuration.ConfigurationManager.AppSett
  4. Found the problem now. My test site test.htm was making the browser operate in quirks mode, and the navigator object don't contain the same information in that mode.With quirks mode enabled: { "appCodeName": "Mozilla", "appMinorVersion": "0", "appName": "Microsoft Internet Explorer", "appVersion": "5.0 (compatible; MSIE 9.0; Windows NT 6.1; Trident/5.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C; .NET4.0E)", "cookieEnabled": true, "cpuClass": "x86", "mimeTypes": {}, "msDoNotTrack": "0", "onLine": true, "opsProfile": {},
  5. I am using the developer tool in IE9 (F12), this is what i get from navigator:[object navigator]appCodeName: "Mozilla"appMinorVersion: "0"appName: "Microsoft Internet Explorer"browserLanguage: "en-us"cookieEnabled: truecpuClass: "x86"getlocation: [object Geolocation]javaEnabled:function javaEnabled() {[native code]}mimeTypes: [object MSMimeTypesCollection]msDoNotTrack: "0"onLine: trueplatform: "Win32"plugins: [object MSPluginsCollection]systemLanguage: "da"taintEnabled:function taintEnabled() {[native code]}userAgent: "Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; Trident/5.0; SLCC2; .NET
  6. I dont want JSON, i just want a representation of the the object i put into the function. The firefox output above is perfect, i just dont understand why the output is not simila in FF and IE. it is on jsconsole.com, but when i use the function i get different outputs. The output in IE should be equal to this:[object Navigator]{appCodeName: "Mozilla",appMinorVersion: "0",appName: "Microsoft Internet Explorer",appVersion: "5.0 (compatible; MSIE 9.0; Windows NT 6.0; WOW64; Trident/5.0; SLCC1; .NET CLR 2.0.50727; Media Center PC 5.0; .NET CLR 3.0.30729; .NET CLR 3.5.30729; .NET4.0C)",browserLangu
  7. Go to jsconsole.com and type navigator, both in IE and Firefox, the function produce equal output. But when i use the function Its the Firefox output that is correct. Also, try to press F12 in IE9, then under script, type "navigator" and evaluate that, then add the output to the watch list. the function should produce the same output, like in Firefox.
  8. Hello I have these JavaScript functions from http://jsconsole.com/ They are supposed to stringify a object and display it as JSON. <html><head> <title></title> <script type="text/javascript"> function sortci(a, { return a.toLowerCase() < b.toLowerCase() ? -1 : 1; } function stringify(o, simple, visited) { var json = '', i, vi, type = '', parts = [], names = [], circular = false; visited = visited || []; try { type = ({}).toString.call(o); } catch (e) { // only happens when typeof is protected (...randomly) type = '[object Object]'; }
  9. HelloI have some data in a Gridview, selection is enabled, i need to be able to select a row and get the content of the first cell from that row. Here is the code: Public Sub codeGridView_SelectedIndexChanged(ByVal sender As Object, ByVal e As EventArgs) Handles GridView1.RowCommand Dim row As GridViewRow = GridView1.SelectedRow Response.Write(row.Cells(1).Text) End Sub I have this property set in the GridView control: onselectedindexchanged="codeGridView_SelectedIndexChanged" There is no errors in the IDE but when i try to select a row the browser quits and i get this error in the IDE:
  10. I did it.This is a fully working example. <html><head><title></title></head> <body><h1>eBay RSS feed</h1> <div id="feed"> <button onclick="getFeed()">Get data</button><br /> <span id="to"></span> </div> <script type="text/javascript"> function getFeed() { if (window.XMLHttpRequest) { // code for IE7+, Firefox, Chrome, Opera, Safari xmlhttp = new XMLHttpRequest(); } else { // code for IE6, IE5 xmlhttp = new ActiveXObject("Microsoft.XMLHTTP"); } xmlhttp.onreadys
  11. Here is a little snippet of the data i get back from responseText: <?xml version="1.0" encoding="UTF-8" ?><rss version="2.0" xmlns:cf="http://www.microsoft.com/schemas/rss/core/2005" xmlns:g="http://base.google.com/ns/1.0" xmlns:rx="urn:ebay:apis:eBLBaseComponents"><!--About this feed===============This page is an RSS feed that provides the listings that satisfy the query you entered.Once you have subscribed to this feed, you will receive automatic updates any time a new listing appears in this store.To learn more about feeds, copy and paste the below link in your browserhttp:/
  12. I dont think so. I get the content of response.Text into the textarea just fine. If it was a cross domain issue i would get "Access denied"Theres only a problem when i use responseXML, although the RSS XML validates./mads
  13. HelloI am trying to generate an array of the data in xmlhttp.responseXML <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml" > <head> <title>Untitled Page</title> <script type="text/javascript"> function getFeed() { if (window.XMLHttpRequest) { // code for IE7+, Firefox, Chrome, Opera, Safari xmlhttp = new XMLHttpRequest(); } else { // code for IE6, IE5 xmlhttp = new ActiveXObject("Microsoft.XMLHTTP"); } xml
  14. HelloI have this array: Array(40) [0]=> widget [1]=> debug [2]=> on [3]=> window [4]=> title [5]=> Sample Konfabulator Widget [6]=> name [7]=> main_window [8]=> width [9]=> 500 [10]=> height [11]=> 500 [12]=> image [13]=> src [14]=> Images/Sun.png [15]=> name [16]=> sun1 [17]=> hOffset [18]=> 250 [19]=> vOffset [20]=> 250 [21]=> alignment [22]=> center [23]=> text [24]=> data [25]=> Click Here [26]=> size [27]=> 36 [28]=> style [29]=> bold [30]=> name [31]=> text1 [32]=> hOffset [33]=> 250
  15. I deleted the whole <style> section and added it again. it works now.Thansk
  • Create New...