|
Hi
XML files could be a option to export files to xls format, of course, these files are not excel format, but if you only want export your tables i believe about they are util to you.
Example: you have this columns in excel
Column1 Column2
Data1 Line1
Data2 Line2
Data3 Line3
In xml you can generate file (text plain file) some this and open in excel and work
<?xml version="1.0"?>
<?mso-application progid="Excel.Sheet"?>
<Workbook xmlns="urn:schemas-microsoft-com:office:spreadsheet" xmlns ="urn:schemas-microsoft-com:office:office" xmlns:x="urn:schemas-microsoft-com:office:excel" xmlns:ss="urn:schemas-microsoft-com:office:spreadsheet" xmlns:html="http://www.w3.org/TR/REC-html40">
<Styles>
<Style ss:ID="Default" ss:Name="Normal">
<Alignment ss:Vertical="Bottom"/>
<Borders/>
<Font/>
<Interior/>
<NumberFormat/>
< Protection/>
</Style>
<Style ss:ID="s21">
<Font x:Family="Swiss" ss:Bold="1"/>
</Style>
</Styles>
<Worksheet ss:Name="Sheet1">
<Table ss:ExpandedColumnCount="2" ss:ExpandedRowCount="4" x:FullColumns="1" x:FullRows="1" ss:DefaultColumnWidth="63.36" ss:DefaultRowHeight="12.959999999999999">
<Row>
<Cell ss:StyleID="s21"> <Data ss:Type="String"> Column1</Data> </Cell>
<Cell ss:StyleID="s21"> <Data ss:Type="String"> Column2</Data> </Cell>
</Row>
<Row>
<Cell> <Data ss:Type="String"> Data1</Data> </Cell>
<Cell> <Data ss:Type="String"> Line1</Data> </Cell>
</Row>
<Row>
<Cell> <Data ss:Type="String"> Data2</Data> </Cell>
<Cell> <Data ss:Type="String"> Line2</Data> </Cell>
</Row>
<Row>
<Cell> <Data ss:Type="String"> Data3</Data> </Cell>
<Cell> <Data ss:Type="String"> Line3</Data> </Cell>
</Row>
</Table>
</Worksheet>
</Workbook>
|
|
|
|
|
where can i get this dll? someone knows?
its because i cant compile nexIRC 3.0 alpha 6 found in Planet Source Code.
cheers
|
|
|
|
|
Hello,
I would like to create a patch for my program. I have a simple window app for testing. Using VB 2005. I have created the application and then added the MSI basic project.
I then went to the project assistant and added the default settings. The project built, installed, and ran ok.
Now I have made some changes to my windows application. And I want to create a patch, not sure now to do this.
I have tried using the quick patch project and the design patch configuration. I am able to create the patch and install it, but it doesn't update the windows application to show the new changes.
Once I have my patch working, should I be able to give the patch.exe to the customer, and they should be able to install it without having to uninstall? The patch should be very small as it is just a few simple changes.
Many thanks for any help you can give me,
Steve
|
|
|
|
|
Your best source of information on using InstallShield is going to MacroVision[^].
|
|
|
|
|
I want to be able to click on an item in a ListBox, then using the AfterUpdate() Sub-routine, be able to store that value into a String variable. My loop is as follows:
***START***
Dim iterator As Long
Dim descriptionString As String
For iterator = 0 to Descriptions_lst.ListCount - 1
If Descriptions_lst.Selected(iterator) Then
descriptionName = Descriptions_lst.Column(0, iterator)
End if
Next iterator
***END***
I'm not exactly sure what the 'Column' does, but apparently this is supposed to get the string value from the selected ListBox item. However, it is not working. I just get empty values for my descriptionName variable. Any ideas?
-- modified at 10:04 Thursday 14th June, 2007
|
|
|
|
|
I only find the ListCount and Selected properties in the Office classes. Is this VBA?
---
single minded; short sighted; long gone;
|
|
|
|
|
Ya, its VBA using Access. I need to somehow verify that 'if' statement properly, then get the selected item into a String variable.
|
|
|
|
|
Hi all,
How could i change text on button in MessageBox?
Ex : If i write :
MessageBox.Show("How to change text","Question",MessageBoxButtons.OKCancel)
-> MessageBox will be shown with "OK" and "Cancel" button. But i want to change text "OK" -> "That's right" and "Cancel" -> "That's not right".
How could i do that?
|
|
|
|
|
You can't. The things you see in a MessageBox are not cusomtizable. You'll have to create your own form class that provides this functionality. It's not that hard. It's just a normal form with a couple of buttons and a label. Maybe even a picturebox if you want.
|
|
|
|
|
hellllo ctlqt,
Dave is correct "The things you see in a MessageBox are not cusomtizable"
U can use
form.showDialog() method to show ModelDialog,
just create a form looklike message box and call it as modelDialog box
regards,
koolprasad2003
Be a good listener...Because Opprtunity knoughts softly...N-Joy
|
|
|
|
|
i have a label and textbox.
right now i have 75 labels and corresponding textboxes.
i have done their connectivities with database.
after deploying it suppose i want 100 textboxes.
or rather i want to leave this on user that how much labels and textboxes he want.
for that a window wil be there and user will enter the name for label and its value..
but how label and textbox will be generated...?
and how will the database connectivity will be established.
i dont know how this can be done.
can anybody give me any idea , hw do i proceed...???
thanks.
|
|
|
|
|
To make the labels and textboxes you can use a for loop that dynamically creates them based on user input. For the db connectivity, what exactly are you looking for?
|
|
|
|
|
okkk, i think it will do.
but wat abt the conectivity with database..??
like how the connectivities with backend will be established automatically with the textboxes created dinamically.
can u tell me any article or any code for such logic...?
|
|
|
|
|
Hello CPians,
I am wanting to do a string comparison but the check is against multiple possibilities, eg: The string can be "SPT", "SAP", or "PRF" and I'm hoping to do this without something like
If MyString.Equals("SAP") Or MyString.Equals("SPT") Or MyString.Equals("PRF") Then
'process here
End If
Is this possible? I've tried some Google searches and haven't found anything as of yet (maybe I'm using the wrong keywords). Any ideas?
"Let's face it, the average computer user has the brain of a Spider Monkey."
Bill Gates
|
|
|
|
|
Select Case MyString
Case "SAP", "SPT", "PRF"
'process here
End Select
|
|
|
|
|
Well I found my solution
Dim ProgramTypes() As String = {"SAP", "SPT", "PRF"}
Dim ProgramTypeList As New ArrayList(ProgramTypes)
If Not ProgramTypeList.Contains(sProgType) Then
'Do my stuff here
End If
"Well yes, it is an Integer, but it's a metrosexual Integer. For all we know, under all that hair gel it could be a Boolean."
Tom Welch
|
|
|
|
|
Hi all.
I've been trying in vein for days to figure this out. I use extended desktop to extend my display to the left, not the right, and when I hibernate and come back, the desktop is extended to the right. So I'm writing an app that will retrieve the extended desktop settings on hibernate and set them again on resume.
I've seen a few examples of using EnumDisplaySettingsEx in C and C#, but nothing in vb.net that helps. I just need to figure out how to determine "This monitor is primary, that one is secondary and is positioned on the left." And then "Set this monitor to primary, set that one to be on the left."
I already have the rest of the app written (detecting hibernate, etc.), but I'm super new to the Windows API and all these structs and translations from C to vb.net are way out of my league.
I'm desperate . Help!
----
P.S. I've pieced together the following, and it gets devicename and resolution successfully, but I'm still stuck on the aforementioned stuff:
Imports System.Runtime.InteropServices
Public Class Form1
Inherits System.Windows.Forms.Form
Const ENUM_CURRENT_SETTINGS As Integer = -1
Const CDS_UPDATEREGISTRY As Integer = &H1
Const CDS_TEST As Long = &H2
Const CCDEVICENAME As Integer = 32
Const CCFORMNAME As Integer = 32
Const DISP_CHANGE_SUCCESSFUL As Integer = 0
Const DISP_CHANGE_RESTART As Integer = 1
Const DISP_CHANGE_FAILED As Integer = -1
Private Declare Function EnumDisplaySettingsEx Lib "user32" Alias "EnumDisplaySettingsExA" (ByVal lpszDeviceName As Integer, ByVal iModeNum As Integer, ByRef lpDevMode As DEVMODE, ByVal dwFlags As Integer) As Integer
Private Declare Function ChangeDisplaySettings Lib "user32" Alias "ChangeDisplaySettingsA" (ByRef DEVMODE As DEVMODE, ByVal flags As Long) As Integer
<structlayout(layoutkind.sequential)> Public Structure DEVMODE
<marshalasattribute(unmanagedtype.byvaltstr, sizeconst:="CCDEVICENAME)"> _
Public dmDeviceName As String
Public dmSpecVersion As Short
Public dmDriverVersion As Short
Public dmSize As Short
Public dmDriverExtra As Short
Public dmFields As Integer
Public dmOrientation As Short
Public dmPaperSize As Short
Public dmPaperLength As Short
Public dmPaperWidth As Short
Public dmScale As Short
Public dmCopies As Short
Public dmDefaultSource As Short
Public dmPrintQuality As Short
Public dmColor As Short
Public dmDuplex As Short
Public dmYResolution As Short
Public dmTTOption As Short
Public dmCollate As Short
<marshalasattribute(unmanagedtype.byvaltstr, sizeconst:="CCFORMNAME)"> _
Public dmFormName As String
Public dmUnusedPadding As Short
Public dmBitsPerPel As Short
Public dmPelsWidth As Integer
Public dmPelsHeight As Integer
Public dmDisplayFlags As Integer
Public dmDisplayFrequency As Integer
End Structure
Public Sub getScreenInfo(ByVal theWidth As Integer, ByVal theHeight As Integer)
Dim ascreen As Screen
Dim DevM As DEVMODE
DevM.dmDeviceName = New [String](New Char(32) {})
DevM.dmFormName = New [String](New Char(32) {})
DevM.dmSize = CShort(Marshal.SizeOf(GetType(DEVMODE)))
If 0 <> EnumDisplaySettingsEx(Nothing, ENUM_CURRENT_SETTINGS, DevM, 0) Then
Dim lResult As Integer
DevM.dmPelsWidth = theWidth
DevM.dmPelsHeight = theHeight
DevM.dmPelsWidth = 1280
DevM.dmPelsHeight = 1024
lResult = ChangeDisplaySettings(DevM, CDS_TEST)
If lResult = DISP_CHANGE_FAILED Then
MsgBox("Display Change Failed.", MsgBoxStyle.OKOnly + MsgBoxStyle.Critical, "Screen Resolution Change Failed")
Else
lResult = ChangeDisplaySettings(DevM, CDS_UPDATEREGISTRY)
Select Case lResult
Case DISP_CHANGE_RESTART
MsgBox("You must restart your computer to apply these changes.", MsgBoxStyle.OKOnly + MsgBoxStyle.Critical, "Screen Resolution Has Changed")
Case DISP_CHANGE_SUCCESSFUL
MsgBox("Display Change Successful.", MsgBoxStyle.OKOnly + MsgBoxStyle.Information, "Screen Resolution Successful")
Case Else
MsgBox("Display Change Failed.", MsgBoxStyle.OKOnly + MsgBoxStyle.Critical, "Screen Resolution Change Failed")
End Select
End If
End If
End Sub
Private Sub Form1_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.Load
getScreenInfo(1024, 768)
End Sub
-- modified at 13:28 Wednesday 13th June, 2007
|
|
|
|
|
vbnetnoowb wrote: I use extended desktop to extend my display to the left, not the right, and when I hibernate and come back, the desktop is extended to the left.
It sounds like you've mistated the problem. From what you've posted, there's no problem at all, so I question why you're even trying to do this.
Really, there shouldn't be a single reason why you're doing this at all if your display drivers are working correctly.
|
|
|
|
|
You are correct. I had a typo in the problem statement that I've updated. What happens is:
[2nd Monitor (extended desktop)][Laptop]
...Hibernate...
...Resume...
[Laptop][2nd Monitor(extended desktop)]
And I'm trying to read the fact that the 2nd monitor is on the left, and then set those same settings later.
Can you help??
|
|
|
|
|
The problem is that your trying to throw a band-aid over a driver problem. On my laptop, this problem doesn't show up, using a Mobility Radeon 9000. I would recommend that you see if there are updated drivers before going through all this. Both ATI (AMD now) and nVidia drivers both come with desktop manager software now that takes care of this.
|
|
|
|
|
We can't move any controls on any forms in a project we've inherited. In the properties pane, all of the forms have a blue lock icon on them, and the toolbar lock toggle is depressed and cannot be released.
Can someone please tell how to release these form locks?
-- modified at 9:07 Wednesday 13th June, 2007
I tried making all of the files not read only, and that fixed it. VB6 sucks donkey turds.
"Why don't you tie a kerosene-soaked rag around your ankles so the ants won't climb up and eat your candy ass..." - Dale Earnhardt, 1997 ----- "...the staggering layers of obscenity in your statement make it a work of art on so many levels." - Jason Jystad, 10/26/2001
|
|
|
|
|
Is this the same project with the stupid reference paths you were complaining about last week?
Try this: Open the .frm file in Notepad. If it contains "LockControls = -1", delete it.
|
|
|
|
|
I know what you mean. I stopped using VB6 when I got my hands on the .NET Framework 1.0 Beta and was writing code in Notepad!
|
|
|
|
|
Hi,
I want to use mouse left click while "Shift" on down position.
Thank you very much.
|
|
|
|
|
Not sure what your problem is here. Do you have a windows program? You want this program to press the shift key and the left mouse click? You can do this through windows messaging. Not sure if that is what you are trying to do or not.
Ben
|
|
|
|