-
May 8th, 2006, 12:46 AM
#1
Thread Starter
Addicted Member
[RESOLVED] Autoloader.............
i have developed a Form Called Outward Entry in VB 6.0 & Access as Database.
i Stores Item Details in MS Flexgrid.
User sends a Request of Items in Excel Predefined Format.as there r many no of items user will require more time to feed that data.
so am thinking of Autoloader as Request Comes Excel Format as no of items to be dispatched are more than 40,
can i use Excel format Directly into the Flexgrid
pls guide me on this issue
thanks
-
May 8th, 2006, 12:55 AM
#2
Re: Autoloader.............
Yse U Can Do It
Just Define The Field In Grid And Put It As An Editable Format
Now Editing The Iten In The Grid U Are Able To Save In The Database
-
May 8th, 2006, 12:58 AM
#3
Thread Starter
Addicted Member
Re: Autoloader.............
Actually i wants to Put data into Flexgrid from Excel Sheet
-
May 8th, 2006, 01:00 AM
#4
Re: Autoloader.............
Is Data Are Saved Any Where?
-
May 8th, 2006, 01:05 AM
#5
Thread Starter
Addicted Member
Re: Autoloader.............
Request For Items in Predefined Excel Format on Click Event All data From Selected Excel Sheet should be Transfered to MS Flexgrid
After when i Click save button saving in Access Table
-
May 8th, 2006, 01:41 AM
#6
Re: Autoloader.............
There are several ways of doing it. One of them is to copy the desired cells to the clipboard and then paste from the clipboard to MSFlexGrid
VB Code:
private Sub Command2_Click()
PasteIntoGrid MSFlexGrid1, Clipboard.GetText(1), true, 15, 15
End Sub
private Sub PasteIntoGrid(byref Flexgrid as MSFlexGrid, byval ClipboardText as string, optional ExtendGrid
as Boolean = true, optional StartCol as Integer = 1, optional StartRow as Integer = 1)
Dim intRows as Integer
Dim intCols as Integer
Dim aryRows() as string
Dim aryCols() as string
aryRows = Split(ClipboardText, vbCrLf)
intRows = UBound(aryRows) + 1
aryCols = Split(aryRows(0), vbTab)
intCols = UBound(aryCols) + 1
With Flexgrid
If .Rows - StartRow < intRows then .Rows = intRows + StartRow + 1
If .Cols - StartCol < intCols then .Cols = intCols + StartCol + 1
.Col = StartCol
.Row = StartRow
.ColSel = StartCol + intCols
.RowSel = StartRow + intRows
.Clip = Replace(ClipboardText, vbCrLf, vbCr)
End With
End Sub
The key thing really is that you need to select the appropriate size area in the flexgrid to contain
the pasted data otherwise you only get the first element in one cell.
SHAKTI
-
May 8th, 2006, 03:52 AM
#7
Re: Autoloader.............
-
May 8th, 2006, 04:30 AM
#8
Thread Starter
Addicted Member
Re: Autoloader.............
Thanks Bushmobile, Jcis & Shakti
-
May 8th, 2006, 04:45 AM
#9
Re: [RESOLVED] Autoloader.............
if u like the thread then rate it
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|