|
You have to convert the RTF formatted text to HTML yourself, wheather by your own code, or using a 3rd party component. There is nothing in the .NET Base Class Library (BCL) that will do this for you. Most commercial 3rd party components for this conversion aren't cheap either. But, you might want to check out the OpenSource sites, like SourceForge. I found DocFrac[^] there. I haven't used it, but it might do the job for you.
After you convert the RTF to HTML, all you have to do is assign the HTML string to the Body property...
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Have you found something that will convert this RTF code into HTML for you? I've been searching for free libraries or utilities for a while, but there all lacking something. What have you done about your issue?
|
|
|
|
|
Hello
I am OK with VB6 language, can not understand VC or much else unless is simply explained.
What i am trying to do is record the sound received from my Hauppauge WinTV USB2 device to a file. I need to start recording to the WAV file and at a set time stop recording, allowing the WAV file to be played like any other WAV or audio file.
I have tried experimenting with code like...
'MCI command to save the WAV file<br />
i = mciSendString("save capture " & CommonDialog1.FileName, 0&, 0, 0)
... but no WAV file is created
My current success is...
Private Sub Command1_Click()<br />
'Start Recording<br />
With MMControl1<br />
.DeviceType = "WaveAudio"<br />
.FileName = "F:\New.wav"<br />
.RecordMode = mciRecordOverwrite<br />
.UpdateInterval = 10<br />
.Command = "Open"<br />
.Command = "Record"<br />
End With<br />
<br />
'End Recording<br />
End Sub<br />
<br />
Private Sub Command2_Click()<br />
MMControl1.Command = "Save"<br />
MMControl1.Command = "Close"<br />
End Sub
... but this records any sound, where i only want the sound that the Hauppauge device receives.
Can any one help, hope theres enough information to understand what im trying to do?
|
|
|
|
|
Hello,
I want to know, how can i enable/disable internet access to certain systems on the network ?
Is there any class/... for this ?
Regards,
Asim
|
|
|
|
|
No there isn't. There is nothing simple to doing this either. This is exactly what Firewall/Proxy servers are for. In order to control this, you'll need a Proxy server that will sit between the clients and the Internet. On each client, you'll configure the web browser to use the proxy server. When the browser requests a page, the request will go to the proxy and the proxy will go out and get the page and return it to the client. The nice part about this is, the proxy server can ask for a username and password to allow access to the Internet.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
I just set up ADSL router to share the internet connection. I think this function work as the part of the hardware too. My ADSL router, has built in command that could set the date/time and an IP address of some system to access/block the internet.
APO-CEDC
Save Children Norway-Cambodia Office
|
|
|
|
|
I am able to fill a dataset and fill the datagrid.
The issue that I am having is that I only want certain columns in the data grid. If there is 10 columns in a database, how can I display 3 of them and only them three in a datagrid? Any suggestions or examples is greatly appreciated. Thanks.
Beginner in ASP.Net and VB.Net
|
|
|
|
|
Dim oConn As New OleDbConnection
Dim oCmd As New OleDbCommand
Some thing like this:
Dim oDS As New DataSet
Dim oDSNew As New DataSet
Dim oDA As New OleDbDataAdapter(oCmd)
Dim oCol As New DataColumn
Dim oCol2 As New DataColumn
Dim oCol3 As New DataColumn
Dim oRows As DataRow
Dim oTable As New DataTable
oConn.ConnectionString = "Provider=SQLOLEDB.1;Persist Security Info=False;User ID=sa;Initial Catalog=HealthandSafety;Data Source=."
oConn.Open()
oCmd.CommandType = CommandType.Text
oCmd.Connection = oConn
oCmd.CommandText = "SELECT * FROM HSDocumentFloorZone"
oDA.Fill(oDS)
With oDS.Tables(0)
oCol = .Columns(1)
oCol2 = .Columns(3)
oCol3 = .Columns(5)
End With
oDS.Tables(0).Columns.Clear()
oDS.Clear()
oDS.Dispose()
With oTable
.Columns.Add(oCol)
.Columns.Add(oCol2)
.Columns.Add(oCol3)
End With
oDSNew.Tables.Add(oTable)
With DataGrid1
.DataSource = oDSNew
End With
Many Thanks
Harry
|
|
|
|
|
Manually add a mapping to those specific columns by adding columnstyles to your datagrid. The columnstyles are accesible through the TableStyle property at design-time.
Note: you will also have to map the TableStyle to your table
"if you vote me down, I shall become more powerful than you can possibly imagine" - Michael P. Butler.
|
|
|
|
|
What would be the mapping name? The database is Address and the table is ADDDAT. The combo box only displays none and I tried typing in Address.ADDDAT but nothing happened. Do you know where I can find some examples of this? Thanks.
Beginner in ASP.Net and VB.Net
|
|
|
|
|
Let's say I have a table named "user" and columns "name","sex", "address" in that table, and I want to display only name and sex in the datagrid.
Therefore, the mapping name for the tablestyle would be "user", and I'll create two columnstyles with the mapping name "name" and "sex".
HTH.
"if you vote me down, I shall become more powerful than you can possibly imagine" - Michael P. Butler.
|
|
|
|
|
What I have done was mapped the table style to Address and mapped the columns to First, Last, and Work (using First, Last, and Work). This all seems to make sense to me but nothing seems to happen when I load the form. Is there something that I might be missing? Do I have to programatically fill the datagrid using the new tablestyle?
Thanks.
Beginner in ASP.Net and VB.Net
|
|
|
|
|
That's weird.
Well this is how I do it.
In Design View, I drag the datagrid onto the form. Then on the property grid, click on the ellipse for the TableStyle property. A dialog box will appear. Click Add to add a tablestyle, set the Mapping Name property to your tablename, then click on the ellipse for the gridcolumnstyle property. Another dialog box will appear. Click on Add to add a columnstyle, then set the mapping name to the column you want to show. Repeat this last bit for each column.
"if you vote me down, I shall become more powerful than you can possibly imagine" - Michael P. Butler.
|
|
|
|
|
So there is nothing to do programatically? I have done the above steps and rechecked them but nothing still happens. Would you mind me zipping up my project and emailing it too you to see if you see the problem? I'm sure there is something that I am doing wrong.
Thanks.
Beginner in ASP.Net and VB.Net
|
|
|
|
|
Sure, go ahead.
"if you vote me down, I shall become more powerful than you can possibly imagine" - Michael P. Butler.
|
|
|
|
|
nick.seng@gmail.com
Is this your email? I tried to send you a zip file called Address.zip but it came back as illegal attachment. If you want you can contact me via email directly, timothy@myactv.net.
Thanks.
Beginner in ASP.Net and VB.Net
|
|
|
|
|
Sorry for the late reply, time-zone difference and all. if the gmail doesn't work, send it to catpainter79 AT yahoo DOT com
"if you vote me down, I shall become more powerful than you can possibly imagine" - Michael P. Butler.
|
|
|
|
|
I have been searching all over, but I cannot find a way to set properties like "Size" or "Font". Can anyone help?
Mike
|
|
|
|
|
That's because the ToolTip controls in the Shell Common Controls .DLL, that the ToolTip .NET Classes wrap, don't support changing the font. In order to implement new fonts and custom graphics, you would have to write your own ToolTip control, inheriting from the existing ToolTop Class and owner draw everything yourself. If your a beginner, I don't recommend tackling this.
But, if you want to do this, you can take a look at a couple of samples of this on GotDotNet:
Extended ToolTip (IExtenderProvider Sample)[^]
ToolTipClass - ToolTip with more features[^]
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Dave,
Thanks very much for the link. As you noted, I can't change the font, but I was able to limit the width of the textbox.
Mike
|
|
|
|
|
Hello,
I am trying to initialize mssoap object in a vb macro but I get this error.Seems like the .wsdl file is not readable at all. I am using IIS 5.1 and winXP + MS Soap 3.0. I have installed all the DLL necessary and made configurations needed,
on the virual dir, read the docs on msdn but it still doesnt work. Someone please help !
my code is
<br />
WSDL_URL = http & "http://localhost/myapp/cfg.WSDL"<br />
WSML_URL = http & "http://localhost/myapp/cfg.wsml"<br />
<br />
Set soap_sql = CreateObject("MSSOAP.SoapClient30")<br />
soap_sql.mssoapinit WSDL_URL, "", "SqlSoapPort", WSML_URL <br />
<br />
error msg is:
"WSDLReader:XML Parser failed at linenumber 0, lineposition 0, reason is: Th
e download of the specified resource has failed.
HRESULT=0x1: Incorrect function.
- WSDLReader:Loading of the WSDL file failed HRESULT=0x80070057: The parame
ter is incorret"
|
|
|
|
|
I have always done this this way, hopefully it will help
Private m_strEndPointURL As String
Private m_strWSDLFile As String
'SOAP / SQLXML members
Private m_oNodeList As IXMLDOMNodeList
Private m_oSoapClient As New SoapClient30
Private Sub ConfigureSOAP()
'Location of the WSDL - XML catalog of the SPs
m_strWSDLFile = "http://localhost/SQLXML/SOAP?wsdl"
'Set the destination host - this is the URL to the server
'without the wsdl path so http://Localhost/MERCSQLXML/SOAP
m_strEndPointURL = Left(m_strWSDLFile, (Len(m_strWSDLFile) - 5))
'This method configures the various SOAP objects ready for use
Set m_oSoapClient = New SoapClient
m_oSoapClient.mssoapinit m_strWSDLFile
m_oSoapClient.ConnectorProperty("EndPointURL") = m_strEndPointURL
End Sub
'Call Soap
Set m_oNodeList = m_oSoapClient.Method(Args)
"If i was king cigarettes would be free."
|
|
|
|
|
thanks
but that doesnt seem to work for me
could it be something wrong with the IIS
I cant open the .wsdl file at all when typing
http://localhost/somedir/myfile.wsdl
|
|
|
|
|
your wsdl file url should be
http://localhost/somedir?wsdl
you need a ? not the direct path, try putting that in IE and see if it presented.
If its not it's your IIS VDs
"If i was king cigarettes would be free."
|
|
|
|
|
HI guys
I have a couple of questions on creating custom activeX controls. I have a customs activeX control with two constotutent controls An ImageBox and a label. I've exposed two properties namely Picture which corrsponds to the image boxes picture property and Caption which corresponds to teh labels caption.
At the moment I'm like setting the picture property by just passing it a string. But that's seriously not how it should be working I mean when you set the Image controls picture property you choose from a file dialog. My code is as below:
<bold>
Option Explicit
Public Event Click()
Private Sub Image1_Click()
RaiseEvent Click
End Sub
Private Sub UserControl_InitProperties()
With Image1
' .Picture = Nothing
End With
With lblRouterIP
.Caption = ""
End With
End Sub
Private Sub UserControl_ReadProperties(PropBag As PropertyBag)
BackColor = PropBag.ReadProperty("BackColor", BackColor)
With Image1
.picture = PropBag.ReadProperty("Picture", .picture)
End With
With lblRouterIP
.Caption = PropBag.ReadProperty("caption", .Caption)
End With
End Sub
Private Sub UserControl_WriteProperties(PropBag As PropertyBag)
Call PropBag.WriteProperty("Picture", Image1.picture)
Call PropBag.WriteProperty("caption", lblRouterIP.Caption, "")
End Sub
'PROBLEM AREA
Public Property Get picture() As String
picture = Trim(Image1.picture)
End Property
Public Property Let picture(ByVal img As String)
Image1.picture = LoadPicture(img)
Call UserControl.PropertyChanged("picture")
End Property
Public Property Get Caption() As String
Caption = lblRouterIP.Caption
End Property
Public Property Let Caption(ByVal str As String)
lblRouterIP.Caption = str
Call UserControl.PropertyChanged("Caption")
End Property
it doesn't make any sense to return a picture as a string.
Also lets say that I want to create my own property for this active X control like uh the name of Status that can hold 3 values. How can I do that.
I've been using vb6 for a while but this is my initial attempt at activeX programming.
I'm using vb 6 and would greatly appreciate the help.
|
|
|
|