.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Register
 
Win Surprise Gifts!!!
Congratulations!!!


Top 5 Contributors of the Month
Easy Web
Imran Ghani
Post New Web Links

convert to ASP.NET set objHttp = Server.CreateObject("Microsoft.XMLHTTP")

Posted By:      Posted Date: August 27, 2010    Points: 0   Category :ASP.Net
 

Hi all,

i don't know nothing to ASP and i need your help to convert the following code to ASP.NET

set objHttp = Server.CreateObject("Microsoft.XMLHTTP") 
objHttp.open "POST", "https://api.c4sms.com/?" & strQueryString, false 
objHttp.setRequestHeader "Content-type", "application/x-www-form-urlencoded" 
objHttp.Send 


 

I need help for this.

Thank you very much.

 

If you known the full code is:

<% 
   Option Explicit 

   '**************** 
   'Replace values with your C4 username and password 
   CONST c4USERNAME = "Your C4 Username Here" 
   CONST c4PASSWORD = "Your C4 Password Here" 
   '**************** 
   Dim strReturnValue 

   'Function to send the SMS message 
   Function sendSMS(strSendToNumber,strMessage,strFromNumber) 

      'Create new variables 
      Dim strQueryString      'Holds data to post to C4 website 
      Dim objHttp            'The XMLHTTP object to make the post request 
      Dim strResponseTxt      'The response from the C4 server 

      'Build the query string 
      strQueryString = "username=" & c4USERNAME & "&password=" & c4PASSWORD & "&send


View Complete Post


More Related Resource Links

Upsize Your Database: Convert Your Microsoft Access Application to Take Advantage of SQL Server 7.0

  

What if you need to convert an existing Microsoft Access 97 database application into a true client-server application that is based on a SQL Server back end? If you know a little about Visual Basic and SQL Server, it's easy to make your app take advantage of the power and scalability provided by SQL Server 7.0. Using some concrete code examples, this article takes you step by step through converting the native Jet queries in your Access application into stored procedures and pass-through queries that SQL Server can use. You'll also learn how to pass on parameters when your client-server app calls these SQL Server stored procedures and queries.

Michael McManus

MSDN Magazine June 2000


ORACLE QUERY CONVERT TO SQL SERVER QUERY

  
hai.......I am a biggner in SQL DB . but i started a complicated and painfull work in SQL SERVER 2008.the problem  convert Oracle hierarchical query to SQL query please help. the query SELECT DISTINCT         LEVEL LVL,         SCH.NSCHEDULE_SL,         SCH.NSCHEDULE_SL_FM,         SCH.CSHED_CNAMEFROM  FA_SCHEDULES SCH WHERE     LEVEL  = 1 AND    NSCHEDULE_SL_FM  IS NULL AND    NBRANCH_SL  = 2  CONNECT BY PRIOR SCH.NSCHEDULE_SL_FM  = SCH.NSCHEDULE_SL AND    NBRANCH_SL  = 2please help me

convert client vbscript code to server side

  
Hi There, we have some .htm pages with client side vbscript,the code is pasted below, we want to get this page run on the server side so that we can access this from a URL, can you please advice how convert this code to be able to run on the server side. Client side code: <HTML><HEAD><TITLE>Select Module</TITLE> <SCRIPT LANGUAGE="VBScript" ><!--     Option Explicit        Dim College    Dim Modules    Dim ModulesArr    Dim counter    Dim MyModules         Set College = Top.App.ActiveCollege    Set Modules = College.Modules     'Sorts the ModulesArr Array by module name.    Sub SortModules(StartPosition, EndPosition)        Dim I, J        Dim CurrName, CurrIndex        For I = StartPosition to EndPosition            J = I            CurrIndex = ModulesArr(J, 0)            CurrName = ModulesArr(J, 1)             'while Mod

Convert Remedy ARSystem Date in SQL Server to short date format

  
Hi: Does anyone know how to convert Remedy ARSystem Date in SQL Server to short date format compensating for EST and Daylight savings. Thank you in advance!

Convert Text to Numeric in reports generated by Microsoft SQL Server 2000

  
Our programming team is producing Excel reports using Microsoft SQL Server 2000 and cannot seem to find a way to produce numeric data as numeric.  It is being produced in the spread sheet as text (with the green triangle in the corner of the cell).  If the user viewing the report has an older version of Excel they cannot even convert it to numeric manually. 

Is there a way to produce numeric data as numeric in the Excel report?

SQL Server DateTime Convert pattern

  

I need the datetime to be in the following format for SQL server 2005

dd/MM/YYYY HH:MI in 24 Hour Format

note: seconds are not included

 

Thanks for any help in advance


Convert SQL CE to SQL Server

  

I have a SQL CE database that I would like to convert to SQL Server (it should've never been implemented as SQL CE). I thought I could use Database Publishing Wizard to generate t-sql that i can run on the server. Visual Studio 08 is supposed to have the wizard integrated but it does not seem it does. I downloaded the SQL Publishing Wizard 6.1 and Database Publishing Wizard 1.1 but I wasn't able to install either.

The 1.1 version requires some sql 2005 prerequisites, and the 6.1 version seems to run but nothing happens.

Any ideas??

 


Convert NVARCHAR column to DateTime - SQL Server

  

Hi there,

Have spent few hours to get this working. I like to get help now. Please note MONTH AND DATES stored in single or double digits as they occur.

Unfortunately DATE TIME is stored in NVARCHAR Data type column as 2/9/2010,  22/10/2010 etc. Following UK Date here.

It is required to pull the data to COUNT No. of Expired. Obviously below one fails.

--AS Date AND Month stored in Single digits AND double digits , below statement 
--thorws Arthmetic overflow exception
SUM(CASE WHEN CONVERT(DATETIME,ExpiryDate,103) >= (CONVERT(datetime,'2010-01-07',103)) AND    
 CONVERT(DATETIME,ExpiryDate,103) < dateadd(month,1,(convert(datetime,'2010-01-09', 103))) THEN 1 ELSE 0 END) AS Expired  


 


Convert NVARCHAR column data into DATETIME - SQL Server 2000

  

ExpiryDate column in Table Data Type is NVARCHAR , storing Dates ONLY without time as 2/10/2010 , 12/10/2010 IN DD/MM/YYYY FORMAT.

NOW IT IS REQUIERD TO RETRIEVE ALL RECORDS WHERE EXPIRYDATE BETWEEN USER PASSED START MONTH,START YEAR AND END MONTH, END YEAR.

USING SQL SERVER 2000

SUM(CASE WHEN CONVERT(datetime,a.expirydate,103) >= (CONVERT(datetime,'2010-01-07',103)) AND 
		CONVERT(DATETIME,a.ExpiryDate,103) < dateadd(month,1,(convert(datetime,'2010-01-09', 103))) THEN 1 ELSE 0 END) AS Expired

 

Your help is greatly appreciated. Spent hours to get this resolved.


A

Convert NVarchar to DateTime - SQL Server 2000

  

Hi there,

FROM USER INTERFACE END USER SELECTS START MONTH, START YEAR AND END MONTH, END YEAR. IT IS REQUIRED TO RETRIEVE DATA WHERE ONE OF THE FIELDS I.E, ExpiryDate is of type NVARCHAR, stored dates as 2/10/2010 [DD/MM/YYYY] , 10/10/2010 ETC.

Using SQL Server 2000.

ALTER PROCEDURE [dbo].[CountUsers]
		(
			@startMonth nvarchar(20) =	NULL,
			@startYear nvarchar(20) = NULL,
			@endMonth  nvarchar(20) = NULL,
			@endYear  nvarchar(20) = NULL,
			@startDate nvarchar(50) = NULL,
			@endDate  nvarchar(50) = NULL
		)
		AS BEGIN

		SET @startDate = @startYear + '-01-' + @startMonth; 
		SET @endDate  = @endYear + '-01-' + 

SharePoint Server 2010 - API to convert word docs to FILTERED HTML

  

Using word automation services, we cannot convert a doc/docx to FILTERED html, which can be done on client side using "saveas".

Is there any unexposed API through which one can achieve this using SharePointServer2010 + c# programatically.

or any alternative way to get FILTERED HTML format file from doc/docx?

I knew the way to do this as a client side application. This can be acheived simply by recording macros.

Ref: http://tudorstoian.blogspot.com/2008/02/word-automation.html

I want sharepoint 2010 server side way to do this task.

How do I convert UTC to specified time zone in T-SQL (SQL Server 2008 R2)?

  

Question: How do I convert UTC time to specified time zone using SQL in SQL Server 2008 R2?

---------------------------------------------------

Scenario: I have a database/ASP.NET application that I use to manage people from quite a few different time zones. In order to keep activities coordinated, all the times in the database are UTC time. Each user's TimeZone is also registered in the database using .NET Framework time zoneIDs e.g. Eastern Standard Time.

In my query I want to specify a date and pull all the activities for that date. However, because all time stamps are UTC times, sometimes an individual's activies fall on two consecutive days in UTC time zone even though the individual completed them on the same day in his/her time zone. As a result, I get misleading data.

When I specify a date, I want that date to be considered user's date. That means, I need to convert all the activity time stamps into user's time zone in my query. This is where I can use some help.


Thanks, Sam

how to convert simple html to asp.net control( server side useing C#,Jquery,xml,xslt)

  

input form 
<FORM METHOD=POST ACTION="mailto:someone@$nailmail.com" ENCTYPE="text/plain"> <table border=0 cellspacing=0 cellpadding=2> <tr> <td colspan=2> <font size=2 face="arial" color="#000000"> <INPUT type="text" name=URL size=17 value="http://"> :Your URL<BR> <INPUT type="text" name=user size=17> :Your Username<BR> <INPUT type="text" name=email size=17> :Your E-mail </font> </td> </tr> <tr> <td> <font size=1 face="arial" color="#000000"> <INPUT name=subscribe type=radio value="yes" CHECKED> subscribe<BR> <INPUT name=subscribe type=radio value="no"> unsubscribe<BR> </font> </td> <td> <SELECT name="choices" size=1> <OPTION selected> OPTIONS <OPTION> OPTION 1 <OPTION> OPTION 2 <OPTION> OPTION 3 <OPTION> OPTION 4 <OPTION> OPTION 5 </SELECT> </td> </tr> <tr> <td colspan=2> <font size=1 face="arial" color="#000000"> <INPUT type=checkbox name="html" value="sendme" CHECKED> i can recive email as html<BR> <INPUT type=checkbox name="receipt"

Function In SQL Server to Convert from CST to GMT

  

Hi...

Can any one tell me how to convert a date which is in this format "2000-11-27 11:24:00" ....the dates are in CST format..I need to convert them to GMT.

I hurd that in SQL we have a direct function which converts from CST to GMT ....

I need to implement this function in the derived column...while get the data from source to target

can any one help me out

Thanks in advance


Cannot convert English data base into Marathi database in SQL server

  

I am going to design an application software using VB.NET as a Front end and SQL server as Back end. When we run this application it ask for select a language i.e. Marathi or English. If user select English language then all interface and database of that application is shown in English language and if we select Marathi Language then all things are in Marathi. For this application software I want to use single database.

So how can I use the single database for English as well as for Marathi language.


Cannot convert English data base into Marathi database in SQL server

  

I am going to design an application software using VB.NET as a Front end and SQL server as Back end. When we run this application it ask for select a language i.e. Marathi or English. If user select English language then all interface and database of that application is shown in English language and if we select Marathi Language then all things are in Marathi. For this application software I want to use only one database.

So how can I use the single database for English as well as for Marathi language.


call JavaScript - jQuery code from ASP.NET Server-Side

  
jQuery got so close to me lately that I can see myself adding the scripts to my project almost unconsciously. The thing is, jQuery is very useful for me, in almost all situations and it has been a do or die enhancement for all my project since I first put my hands on it.

Of course while using it, you encounter few situations which need a bit of research to solve, mostly when you are trying to combine it with some other technologies like: UpdatePanels and ASP.NET Ajax. For instance there are many situations when I would like to run some jQuery magic based on some decision that I make on the server side.
Categories: 
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend