- Strength to Increase Rep
- +0
- Strength to Decrease Rep
- -0
- Upvotes Received
- 3
- Posts with Upvotes
- 3
- Upvoting Members
- 3
- Downvotes Received
- 0
- Posts with Downvotes
- 0
- Downvoting Members
- 0
49 Posted Topics
Hello all, I am trying to build a client to consume a webservice, and have run into some strange issues. Here is my code: $securityCode = "A7D5B7D8-73E2-44D2-A6F8-4ACFB91843BF"; // The security code has been changed to an invalid code to prevent unwanted "visitors". $ProphecyConnect = new SoapClient("http://test.prophecyhealth.com/ProphecyConnect/ProphecyConnectXML.cfc?wsdl"); try { $params = … | |
Has anyone ever tried returning a ColdFusion structure through a web service? The WSDL type CF assigns to this is apachesoap:Map, but when I consume this in VB.NET, the data is null. I have converted the entire thing into a JSON string, and that seems to work, but it requires … | |
I need to return a class which inherits List(Of ) in a webservice. The consuming application simply views it as an array of the class, not a list. In fact, the Collection class is not even available to derive an object from. Class Definition: [CODE=VB.NET] Public Class TestResultCollection Inherits List(Of … | |
I am having issues parsing JSON data from a web service. The web service is local on my machine, and I have added it as a Web Reference. Simple data types from the service work perfectly. However, if I call a method that returns a complex structure (such as an … | |
Re: Are you outputting from a query? If so you can use the group attribute of the cfoutput tag. Here's an example: [code=ColdFusion] <cfoutput query="queryname" group="title"> #Title# <cfoutput> #SubTitle#<br /> </cfoutput> </cfoutput> [/code] This would ouput the following: [B]Title1[/B] Subtitle1 Subtitle2 Subtitle3 [B]Title2[/B] Subtitle1 Subtitle2 [B]Title3[/B] Subtitle1 Post some of your … | |
Hi all, I'm helping a friend redo his database queries and have run into something that I need some advice on. Let me first say that I am not a PHP developer, so please bear with me. I have two queries that I can merge together, but I will need … | |
I recently updated our servers to CF 8.0.1 and now none of my AJAX code works. I checked the XHR response in Firebug and instead of returning the requested data, it returns the HTML code for my site's home page. All of this was working before the update and I … | |
Re: Try using != (not equal) instead of NOT LIKE. LIKE is a little more 'fuzzy' than an explicit equal, which is why you did not get the data you were looking for. Also, one other thing that might help make your queries easier to read (and type) is using aliases … | |
Re: [QUOTE=kaushik259106;547708]Hello all, I am trying to do something like this.I have did this before with C# and asp.net but it was long back and currently am not able to recall anything similar. This time i need to make it work with [B]vb.net and ASP.net[/B] I want that only a administrative … | |
Re: Here's something to start with. To get the first four characters of the user's name, use the LEFT function. Assuming you have a text box on the form called 'txtName': [code=ColdFusion] <cfset username = LEFT(form.txtName, 4) /> [/code] If the name entered in that field was 'mkwebnovice', this would give … | |
Re: Based on query data? If so yes, but I don't have it with me at the moment. I'll get back to you. | |
Re: One thing to check is to cfdump the form structure and make sure that the data from the form is correct. [code=ColdFusion] <cfdump var="#form#"> [/code] Do you have any <cfset> statements that could be over-writing the value of those form variables? If possible, please post the entire strat_survey.cfm page so … | |
Re: You need to create the datasource in the ColdFusion administrator if you have access to it. | |
Re: Try this: [code=SQL] SELECT hourStamp, NULL AS ActualVisits, SUM(CASE WHEN datestamp < GETDATE() THEN 1 ELSE 0 END) / @numberofdays as HourAverage, SUM(CASE WHEN dateStamp BETWEEN DATEADD(d,DATEDIFF(d,0,GETDATE()),0) AND GETDATE() THEN 1 ELSE 0 END) as HourToday FROM webstats GROUP BY hourStamp UNION SELECT hourstamp, COUNT(id) AS ActualVisits, NULL AS HourAverage, … | |
Re: If you are using SQL 2005, here's another option. (originally posted in [url]http://www.daniweb.com/forums/post639423-7.html[/url]) Suppose you have a table with the following structure: [code] id - int PrimaryKey name - varchar(50) description - varchar(MAX) [/code] and the following values: [code] 1 Joe Short for Joseph 2 Dave Short for David 3 … | |
Re: Wrap your content inside a <![CDATA[ ]]> tag. XML will ignore any special characters inside. [code=XML] <instrumentation.InstrRange><![CDATA[-40° to 70°C]]></instrumentation.InstrRange> [/code] | |
Re: Couple of things here: Use CFFILE to upload the files to the server. ([url]http://livedocs.adobe.com/coldfusion/8/htmldocs/help.html?content=Tags_f_02.html#4003197[/url]) You also need to change the form's encoding type to multipart. I have updated your code below: [code=ColdFusion] <cfset CurrentPage=GetFileFromPath(GetBaseTemplatePath())> <cfif IsDefined("FORM.MM_InsertRecord") AND FORM.MM_InsertRecord EQ "form1"> <!--- Set the destination folder. Use ExpandPath to properly map … | |
Re: I'm not aware of any way to get this to work in CF. However, in your SQL query/stored procedure, you could put the data into temp tables, join them there and then return the results to CF. This would eliminate the need for QoQ joins. Let me know if you … | |
Re: What version of MSSQL are you using? If 2005, then I have a query you can modify that will remove duplicate entries. | |
Re: [QUOTE=creative72;633753]I have used the cfmail tag alot but dont get the following to work. I have a form were a system administrator can submit a email to all subscribers informing them of 'something', whatever. My problem is, the text area field is being used for the body of the mail … | |
Re: Use SCOPE_IDENTITY(). It will return the id of the record just created, provided the field is set as the identity column. [code=ColdFusion] <cffunction name="insertData" access="public"> <cfargument name="formData" type="struct" required="yes"> <cfquery name="qInsert" datasource="mydata"> INSERT INTO mytable (email, firstname, name) VALUES ('#formData.email#', '#formData.firstname#', '#formData.name#') SELECT id = SCOPE_IDENTITY() </cfquery> <cfreturn qInsert.id /> … | |
Re: Here's one way: Get your db information before you output the <head> tag on your page. Inside the <title> tag, output the info from your query. For example: [code=ColdFusion] <cfquery datasource="dsn" name="pageData"> SELECT * FROM pageContent WHERE pageID = #pageID# </cfquery> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html … | |
Re: When you use a variable in the list element of the CFLOOP tag, it must be enclosed in #'s... [code=ColdFusion] <cfset myd = ""> <cfloop list="#form.mydata#" index="i" delimiters=","> <cfoutput> <cfset myd = "#i#"> #myd#<br /> </cfoutput> </cfloop> [/code] Otherwise, it interprets it as a literal value. | |
Re: Are you saying that the insert.cfm page is missing? If so, do you have any information (table structures, etc..) so it can be recreated? I'm more than happy to help if you can give me more info. | |
Re: That's not so much a coldfusion problem as it is an SQL "feature". Floats are not exact representations of numbers, but approximates. Here's an explanation: [url]http://msdn.microsoft.com/en-us/library/ms173773.aspx[/url] In your query, you should be able to CAST the float into another datatype, such as a decimal and that should solve your problem. … | |
Re: I'm sorry. I'd love to help you with that but I've never used cfexchangemail. Do you know what the special characters are? If so, perhaps you could strip them from the UID before you pass it to the cfexchangemail tag. Other than that, I really don't have any ideas. | |
Re: Not being able to see the code, I don't have any concrete solutions, but it may be an issue with cookies. If you are able to cancel the second login screen and still get it, that leads me to believe that the authentication page may not be seeing the cookies … | |
Re: You don't technically need any version to code for it, it isn't like Visual Studio. You can code in pretty much any text editor. But to answer your question, if you are going to buy a new copy of Dreamweaver, then CS3 is the latest version available. I believe that … | |
Re: I think first of all you need to figure out why your queries are taking longer than 100 seconds. Unless your running a migration script, your queries should be much faster. Is this the query you were trying to run, or are you using that as an example? If so, … | |
Re: Honestly, there are a lot of legal and logistic issues with setting up your own newsletter app (blacklists, spam laws etc...). A quick Google search returned these results (can't vouch for how well they work) [url]http://www.cftagstore.com/index.cfm?page=viewTag&tagId=97&ss=true[/url] (pre-built, full featured system) [url]http://tutorial14.easycfm.com/[/url] (build your own tutorial) Another option is to use … | |
Re: You need to use a javascript function for this: [code=Javascript] function ChangeButtonStatus() { if (document.getElementById("Text").value.length > 0) { document.getElementById("submit").disabled = false; } else { document.getElementById("submit").disabled = true; } } [/code] Then in your form, add an OnBlur event to the textbox: [code=ColdFusion] <cfinput type="text" name="Text" id="Text" OnBlur="ChangeButtonStatus()"> [/code] | |
I have a data layer class built with the dataset designer that I have added as a reference (compiled dll) in a project. When I run the app locally from Visual Studio, it runs just fine. However when I move it to the hosted server, I get "Type 'H2C2DataLayer.h2c2DataSet.topicsDataTable' is … | |
Re: The group attribute of cfquery is one of the most unknown and under-appreciated pieces of the entire language. It's so incredibly simple to use it's a wonder more people aren't told about it. I modified your output to use grouping and it should make your life a little easier (programming … | |
Re: I'm not sure if this will work, but create an application.cfm file in the pdf folder that has user authentication code. I believe that the CF processor will read this file before it sends the pdf to the user. Unfortunately, I don't currently have a CF server to test this … | |
Re: You need to specify a value for each one. For instance: [code=ColdFusion] <cfinput type="checkbox" name="gender" value="Male" checked> </label></td> <td>Female</td> <td><label> <cfinput type="checkbox" name="gender" value="Female"> </label></td> [/code] When you process the page, the Form.Gender variable will contain either "Male" or "Female" depending on which is checked (or "Male,Female" if both are … | |
Re: First of all, please don't name your query cool.recordCount. RecordCount is a property of the query object. Name it something like qryCool. Secondly, you're missing a </cfif> tag. You have two cfif statements, but only one closing. Do you already have code that determines if this is a duplicate record? … | |
Re: I'm not sure I understand what you're getting at. You're storing thumbnail images on another server? That has nothing to do with CF. The CF server won't load the images, the client does. So perhaps the server your thumbnails are located on is slower than your web server. Please clarify … | |
Re: Are you using a cursor? If so, you could always create a counter variable and increment it each time through the loop. Is this done through an application, or the query window? If it's done in a application, you may need to create a temporary table, insert the counter, plus … | |
Re: Not sure if this is what you are looking for: [code=SQL] DECLARE tempCursor CURSOR FOR SELECT col3 FROM table1 WHERE col2 = @col2 OPEN tempCursor DECLARE @value As int --or whatever your datatype is FETCH NEXT FROM tempCursor INTO @value WHILE @@FETCH_STATUS = 0 BEGIN PRINT @value --Do whatever you … | |
Re: In the Restore Database window, on the Options screen, check the first option 'Overwrite the existing database'. BTW, are you restoring from a .bak file? Or the .mdf? If you are restoring from the .mdf, you have to attach the database rather than restore it. Let me know if you … | |
Re: I'm not sure I understand what you are looking for. Can you please post some code? | |
Re: [code=ColdFusion] <cfquery name="disp_news_arti_curr" datasource="#Request.MainDSN#" CACHEDWITHIN="#CreateTimeSpan(1,0,0,0)#"> SELECT id_news_arti, url, name_pub, date_create, author_pub, title FROM data_news_arti WHERE status = 1 AND date_create >= DateAdd(m, -6, getDate()) ORDER BY date_create DESC </cfquery> [/code] This will return any article less than 6 months old. Here's more info on the DateAdd function: [url]http://doc.ddart.net/mssql/sql70/da-db_5.htm[/url] | |
Re: When you view the page in a browser, what's the source look like? Can you post that? Also, have you checked to see if the GetProduct.ProductLink element has the data you need? You can do a cfdump on your page to see what the query holds. [code=ColdFusion] <cfdump var="#GetProduct#" /> … | |
Re: [QUOTE=some one;554768]i mean that if i want to use an external data base to get some information since our project is an online travel advisor we need to get the prices from web sites which mean that we will use their data base is it possible to do so and … | |
Re: Regular Expressions should do the trick for this. [code=c#] //Find the quotation marks in the string Regex regEx = new Regex("[\"]"); MatchCollection mc = regEx.Matches(string); //Remove them foreach (Match matches in mc) { string = string.Remove(matches.Index, 1); } [/code] It does require some looping, but it's still pretty efficient. Here's … | |
Re: You may have already figured this out, but the first thing that comes to mind is that your query has been cached for 4 hours. Because it's a stored procedure and not an inline query, CF will not recognize the the stored proc has changed. Mind you, I'm not suggesting … | |
Does anyone know how to create queryable collections in VB without using LINQ? I am working on creating a dynamic questionnaire system and need some help. Here's some background: The system needs to support parent/child questionnaires. I have the database model created, as well as a query that returns all … | |
Hello everyone. My name is Chris and I'm a C# developer switching to VB for a new job. I have about 8 years experience in Web Development with a strong background in SQL, as well as graphic design. Looking forward to being part of the community. | |
I'm having trouble with finding a checkbox control on a page. I have a repeater that creates a list of items with checkboxes (so I can activate/deactivate them). The checkboxes are named as follows in the html source: ctl00$ContentPlaceHolder1$ActivateLevelZero$rptItems$ct100$chkIsActive ctl00$ContentPlaceHolder1$ActivateLevelZero$rptItems$ct101$chkIsActive ctl00$ContentPlaceHolder1$ActivateLevelZero$rptItems$ct102$chkIsActive etc... When I try to access them in the … |
The End.