Multiple combobox from one datasource

Hi all
i have 5 combobox that all have data from one table but different values.
sample for one combobox
Private Sub ucitajobveznikpdv()
        Dim tabsyskonta = True
        Dim dt As New DataTable
        Dim ds As New DataSet
        ds.Tables.Add(dt)
        SQL.DodajParametre("@tabsyskonta", tabsyskonta)
        SQL.ParamQuery("SELECT Parametar + ' - ' + Naziv AS Opis, Parametar  FROM TabParamSys WHERE Tab_Partneri_PDV=@tabsyskonta ORDER BY Parametar")
        If SQL.SQLDS.Tables.Count > 0 Then
            cbPDVObveznik.DataSource = SQL.SQLDS.Tables(0)
            cbPDVObveznik.ValueMember = "Parametar"
            cbPDVObveznik.DisplayMember = "Opis"
            cbPDVObveznik.SelectedIndex = -1
            SQL.SQLDA.Fill(dt)
            Dim r As DataRow
            cbPDVObveznik.AutoCompleteCustomSource.Clear()
            For Each r In dt.Rows
                cbPDVObveznik.AutoCompleteCustomSource.Add(r.Item("Opis").ToString)
            Next
        End If
    End Sub
second sample
  Private Sub ucitajinopartner()
        Dim tabsyskonta = True
        Dim dt As New DataTable
        Dim ds As New DataSet
        ds.Tables.Add(dt)
        SQL.DodajParametre("@tabsyskonta", tabsyskonta)
        SQL.ParamQuery("SELECT Parametar + ' - ' + Naziv AS Opis, Parametar  FROM TabParamSys WHERE Tab_Partneri_InoPart=@tabsyskonta ORDER BY Parametar")
        If SQL.SQLDS.Tables.Count > 0 Then
            cbInoPartner.DataSource = SQL.SQLDS.Tables(0)
            cbInoPartner.ValueMember = "Parametar"
            cbInoPartner.DisplayMember = "Opis"
            cbInoPartner.SelectedIndex = -1
            SQL.SQLDA.Fill(dt)
            Dim r As DataRow
            cbInoPartner.AutoCompleteCustomSource.Clear()
            For Each r In dt.Rows
                cbInoPartner.AutoCompleteCustomSource.Add(r.Item("Opis").ToString)
            Next
        End If
    End Sub
 and so on
is it possible to select all data in one query and read for specific column condition and fill combobox with that data
hope you can understand 
sorry for my bad english 
thanks

Just connect to database and use a reader object, then in the loop you can decide what you want to add to each combobox. This way you  have full control on what you want to do:
Dim query
As
String =
"SELECT * FROM table WHERE company=" & company &
" AND type=0"
Try
Using cn
As
New
OdbcConnection(invoiceDataSourceString)
'Connect to correct database server
cn.Open()
Using cmd
As
New
OdbcCommand(query, cn)
Dim reader
As
OdbcDataReader
reader = cmd.ExecuteReader
Do
While reader.Read
'Set vars from database
count = reader("count")
Loop
reader.Close()
End
Using
cn.Close()
cn.Dispose()
End
Using
Catch e
As
OdbcException
dbaseError(e, invoiceDataSourceString, query)
Catch ex
As
Exception
If debug
Then MsgBox(ex.Message)
End
Try

Similar Messages

  • To Move Multiple Files from one directory to another.

    Hi,
    I need to move multiple files from one directory in UNIX (application server ) to another. I need something like an FM 'STRALAN_COPY_FILES' which is also valid in ECC 6.0.
    Thanks in advance.

    Hello Sachin
    Below you see a copy of how to use EPS_FTP_PUT using transaction SE37.
    Import parameters               Value             
    RFC_DESTINATION =                 NONE              
    LOCAL_FILE             =         filename          
    LOCAL_DIRECTORY   =              /dir1/dir2        
    REMOTE_FILE             =        filename          
    REMOTE_DIRECTORY   =             /dir1             
    OVERWRITE_MODE        =          F        " force -> overwrite existing file                 
    TEXT_MODE                    =   B               " binary
    TRANSMISSION_MONITOR            X       " display transmission monitor            
    *RECORDS_PER_TRANSFER            10                
    *REQUESTED_FILE_SIZE             0                 
    *MONITOR_TITLE                                     
    *MONITOR_TEXT1                                     
    *MONITOR_TEXT2                                     
    *PROGRESS_TEXT                                     
    *OBJECT_NAME  
    Regards,
      Uwe

  • Moving multiple queries from one category to another in QM

    Hi All,
    Is there is any way of moving multiple queries from one category to another in the query manager?
    Or is the only way of doing it by saving each one individually into a different category.
    Any ideas ?
    Regards,
    Rakesh N

    Hi Rakesh,
    The query manager has limited function compare with normal file management applications. Under current design, you have to do this one by one. You just need to make sure move the smaller amount of queries to large category. Category name can be changed easily.
    Thanks,
    Gordon

  • Add to Multiple Tables from One Page

    Hello,
    I am building an application that handles hardware inventory (APEX 4.0). I have an input page that adds data to two or more tables all at once. The page has two forms on it that point to two separate tables. However when I try to run the page, it fails and returns an error:
    ORA-06550: line 1, column 437: PL/SQL: ORA-00904: "ORH_LAST_UPDATE_DATE": invalid identifier ORA-06550: line 1, column 7: PL/SQL: SQL Statement ignored
         Error      Unable to process row of table IDD_ID_DATA.
    So far as i can see within the App, that column is not at issue (I am not even doing anything to it and it is nullable). I have looked into the App itself as well as doing some online research but have found nothing helpful...
    So my question is this: Is it possible to add to multiple tables from one page? If so how do I do it?
    I am new to APEX so any help would be greatly appreciated!

    UPDATE:
    I received an email from the APEX Support Team:
    "The simple answer is that you will need to manually code the DML (and query) processes if you wish to maintain multiple tables from one page (There is a limit of one table when using the built-in processes).
    In order to do this I suggest you delete the processes generated by the wizards and create PL/SQL processes with insert, update, delete statements as necessary. Such coding is not difficult but is more time consuming than when you can use built-in processes."
    I have been playing around with PL/SQL code and the end result is this:
    begin
         INSERT INTO table1
         VALUES(
              :P2_Item_Field1,
              :P2_Item_Field2);
         INSERT INTO table2
         VALUES(
              :P2_Item_Field1,
              :P2_Item_Field2);
    end;
    I used this code in a custom PL/SQL Process in the Processing>Processes section of Page Processing and it seems to work fine now. The only downside to this method is if the name of a Page Item is changed the code will also have to be changed. Other than that i have had no problems.

  • Use case for multiple crosstabs under one datasource

    I'm trying to understand why one would have multiple crosstabs for one datasource.  When I change one crosstab, it changes the other crosstab.  I was could have a different layout for multiple crosstabs.
    Thanks.
    Regards,
    Mel Calucin

    Hi Mel,
    I am not following this question; would it be possible to rephrase it?
    You could have multiple tabs for a data source - such as a one tab showing the result set in a cross tab and the other for a chart.
    Tammy

  • Scenario of multiple Asset from one AUC/WBS

    Hello,
    I am having a requirement, where I need to create multiple Asset from one WBS. I checked in the system and able to create more then 1 Asset for WBS.Also if I maintain the distrubution rules for those Asset then settle it accordingly to different Assets.
    I just wanted to confirm, will it we the right way of handling this scenario? My main concern is this involves intervention of user for maintaing the settlement rule during final settlement.
    Is there any other way to handle this scenario?
    Thanks
    Sarang

    Hello Virendra,
    I am not using Investment Managemnt. What do you mean by IM profile?
    I understand that I need to maintain the source of cost in Source structure. But even in that scenario the user has to go and maintain settlement rules and create multiple Asset against one WBS.
    So how do I tackle it, if client requirement is such that they want to create only one AUC, but during final Asset creation they want to create multiple Assets from one AUC. They dont want to have WBS for each Asset.
    Thanks
    Sarang

  • Creating multiple links from one map image in Flash CS4

    I have been tasked with creating multiple links from one map image using flash. Each link would go to the main website page with that location. I assume I could create a button for each location on the map but not having a lot of experience any help / tutorial you know of would be super helpful.. Thanks! Not looking for someone to work me thru it but a little guidance would be great!

    If I was to answer the problem, I would be giving you what you asked not to be given... the solution.  So I'll suggest that you start by researching the getURL() function.  That is what AS2 uses for opening web pages.
    As for coding a button, I'll recommend the following article for you... it will explain the proper approach to coding a button, which will give you an advantage over others who don't follow it, but instead use the way the article says not to.
    http://www.adobe.com/devnet/flash/articles/as_bestpractices_04.html
    Google is one of the best resources available for learning how to do things with Flash--it's the first place I go when I have a wondering.  In general, if you type in the right keywords, you get fairly good search results.  In your case, combinations of "AS2", "button", "getURL", "tutorial" would probably work well.

  • Passing Multiple rows from one external webpart list to another

    Hi Folks,
                    I have almost spent 1 week looking into this without any success. I have an external list "List A"  (in a webpart) with one of the columns as "State".
    Another external list "List B"  (in a webpart ) has state and user as columns. In some case I want to pass 1 state and in another I want to pass multiple state.  Passing one state from List A to List B works fine. But Multiple state does
    not work because the webpart list has the property "Send First row to connected web parts when page loads".  If I disable this option then the web part does not pass anything. Is there a way to pass multiple rows from one Webpart
    external list to other?

    http://www.sharepointanalysthq.com/2010/07/bcs-external-list-limitations/
    No Lookups
    Unfortunatly the only thing that you can do a look up on in an external list is on the ID column, anything else and you are out of luck.
    http://social.technet.microsoft.com/Forums/en-US/615771a0-ba78-4e38-9e2d-ded0204173ba/external-list-referenced-as-sharepoint-lookup?forum=sharepointgeneralprevious
    Try below webpart. it should help
    http://www.sparqube.com/SharePoint-Lookup-Column/
    If this helped you resolve your issue, please mark it Answered

  • How to migrate report from one datasource to another?

    Hi,
    can anyone help me, I want to migrate report from one datasource to another.
    Also what are the prerequisites for this?
    any help help will be deeply appreciated.
    Thanks,
    Saurabh.

    Hello,
    To copy queries you can use TA RSZC.
    http://wiki.sdn.sap.com/wiki/display/BI/CopyingQuerysfromOneTargettoAnother
    http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/204111a9-0fca-2d10-219c-be20e686cdb5?QuickLink=index&overridelayout=true
    http://help.sap.com/saphelp_sm32/helpdata/en/9f/f57539d6d1c93be10000000a114084/content.htm
    https://cw.sdn.sap.com/cw/docs/DOC-34603
    Thanks.
    With regards,
    Anand Kumar

  • Data Load into two data targest from one DataSource

    Hi,
    I want to load data into two data targest from one DataSource. I did full load, then Initialization & delta settings for that DataSource. But I want to load data into one data target using delta InfoPackage & into 2nd data target using Full Load InfoPackage. Can I schedule execution of these 2 infopackges one delta & 2nd Full load InfoPackage for the same DataSource simaltaneously?
    Regards,
    Pradip

    Hi,
    In BI, You can achieve this. As thorugh info package, you laod data till PSA only. Then it is being loaded to other data targets.
    Create two DTPs, one with FULL load and another one with Detla Load. It will work.
    In R/3 Side, As sandeep has mentioned , there might be possibility that if you run full load after delta , your delta may get corrupt. i am not sure about that , but there is a possibility.
    - Jaimin

  • Run multiple apps from one browser windows with 9ias r2

    We are running 9ias r1 with forms 6i as our production server. Users are able to access one html page with multiple links to their applications. They can run one application, keep it running, navigate back to the html page and run a second application.
    We are testing 9ias r2 with forms 9i, but when users try to navigate back to the html page to run the second application the first application closes.
    Is there a way to have 9ias r2 work the same as r1 and allow users to run multiple application from one html page?

    Hi,
    Thank you for posting in Windows Server Forum.
    You can take rdp of server 2012 R2 from Fedora Linux desktop by running Yum command or Gnome rdp support. Please check below article for information.
    1.  How to Use Remote Desktop (rdesktop) in Redhat/Fedora/CentOS
    2.  Remote desktop from Linux to windows using rdesktop and gnome-rdp
    3.  XRDP Installation: An Easy Remote Desktop Setup for Linux
    Note:
    Microsoft is providing this information as a convenience to you.
    The sites are not controlled by Microsoft. Microsoft cannot make any representations regarding the quality, safety, or suitability of any software or information found there.
    Please make sure that you completely understand the risk before retrieving any suggestions from the above link.
    Hope it helps!
    Thanks.
    Dharmesh Solanki

  • Lightbox -- Multiple photos from one thumbnail?

    What I want to do is create a lightbox that launches a set of multiple photos from one thumbnail. Is this possible? All I have been able to do is create a lightbox that display's all of it's contents as thumbnails on my page. I am creating a portfolio page and I want each project's images to launch from one thumbnail. All of the projects would then be able to appear on one page. The work-around of course would be to make a separate page for each project, and make a lightbox within each one of these pages. Any solutions for this? Thanks!

    You can achive this by combining the Composition Lightbox Widget with the Slideshow Widget.
    01. Add Lightbox Display widget from the Composition section in the Widget Library
    02. For each small grey box (the Trigger) add your thumbnail
    03. In the larger grey box (the Target) add your Slideshow Widget (anyone you'd like from the Widget Library)
    04. Replace images with the images you want for your slideshow
    05. Preview

  • How do you select/move multiple clips from one timeline to another?

    Has to do with combining multiple edls from Avid - required due to an issue with duplicate reel names in the original Arri footage. I can move them one at a time, but it is very tedious. Is there a way to select multiple clips and move them together?

    Actually discovered the magic of the shift key.
    IRCP Beauty doesn't recognize multiple timelines in a session, so first you have to at least get the footage on multiple tracks in the same timeline. Shift + drag on the track will allow you to move it to another timeline. Also Shift + drag on the center of the first clip in a sequence will slide the entire sequence down - which is how timelines end up getthing offset all the time. Also, if there are multiple tracks in a timeline and some are locked and some aren't, Shift + drag on a clip will slide ALL UNLOCKED tracks in the timeline.
    Finally, Shift + click on either in or out marker moves both points up or down the timeline.

  • Managing multiple iPods from one computer

    The existing posts re: managing multiple iPods/iTunes accounts from one computer don't seem to address my question. I have been sharing my iPod with the family, and want to get my son his own for his birthday. Can I manage both iPods from the same computer? Does the iTunes software have the ability to "recognize" which iPod unit is attached? I'm dying to get his music out of my iPod ...

    Can I manage both iPods from the same computer?
    Yes.
    I'm dying to get his music out of my iPod ...
    Create new playlist and put the music you want in it.
    Open iTunes prefs -> iPod and select Automatically update only selected playlists and pick this new playlist.

  • How do I select multiple messages from one sender in mobile email to delete them all at once?

    I know how to select all of the new messages and mark as read. Now how would I do that if I wished to delete all from one sender or have the same subject, after I search the sender or subject?

    Hey Koyster,
    Great question. Utilizing iCloud.com, we may be able to purge these emails in a much faster way:
    iCloud: Delete email
    http://support.apple.com/kb/PH2651
    Delete messages
    - On your Mac, Shift-click to select multiple adjacent messages or Command-click to select multiple nonadjacent messages.
    - On your Windows computer, Shift-click to select multiple adjacent messages or Control-click to select multiple nonadjacent messages.
    Thanks,
    Matt M.

Maybe you are looking for

  • Error while doing PGI

    while doing PGI i am getting error : "     Item 000010 requires exactly 10 serial numbers for the asset " i tried by Extra --> serial no here i am not able to do anything, there is no automatic button in pop up screen. and in mm02 also i tried in sal

  • I can't add music to iTunes with latest software and updates.

    I just updated to Mavericks and I have version 11.1.3 (8) of iTunes.  I still had music in a folder that was not in the itunes media folder and now I can't add this music to iTunes or even play the music.  Is there anything I can do to fix this so I

  • Financial Statement (FS) report cat not be completed

    Hi, I am running a month-end FS on EBS R12 but it is running very long time and can not be completed. How do I resolve or tune this program? I issue a TOP command in my Linux OS and I see this process which eats all the CPU (100%), How do I know if t

  • Is photoshop cc 14.0 X64 compatible with the new mavericks software

    is photoshop cc 14.0 X64 compatible with the new mavericks software??

  • Lotus Portlet error

    when i deploy Lotus Portlet into AS 10g Portal, it can work ok, and display some mails in portlet, but when i choose custimized icon and change nothing and submit ok, it has following error, when i click refresh icon, it can ok. who has idea for this